Add deployment pipeline and clean up repo

- Add Dockerfile, docker-compose.yml, .dockerignore, .env (port 3842)
- Add Caddyfile.snippet for analytics gateway import pattern
- Add .gitea/workflows/deploy.yaml for act_runner SSH deploy
- Untrack sensitive/data files (SCPA xlsx, owners.rds)
- Add renv lockfile and infrastructure files
- Reorganize data-raw scripts and add SarasotaCounty boundary data
- Move www assets to www/images/, add docs PDFs
This commit is contained in:
2026-03-09 10:38:21 -04:00
parent 9dd0c7708d
commit 05e2aba34c
38 changed files with 6749 additions and 96 deletions

View File

@@ -0,0 +1,33 @@
name: Deploy stAndrews
on:
push:
branches:
- master
jobs:
deploy:
runs-on: ubuntu-latest
container:
image: debian:bookworm-slim
steps:
- name: Install SSH client
run: apt-get update -y && apt-get install -y --no-install-recommends openssh-client
- name: Deploy via SSH
env:
SSH_PRIVATE_KEY: ${{ secrets.DEPLOY_SSH_KEY }}
SERVER_IP: ${{ secrets.DEPLOY_SERVER_IP }}
SERVER_USER: ${{ secrets.DEPLOY_SERVER_USER }}
run: |
mkdir -p ~/.ssh
echo "$SSH_PRIVATE_KEY" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
ssh-keyscan -H $SERVER_IP >> ~/.ssh/known_hosts
ssh ${SERVER_USER}@${SERVER_IP} << 'EOF'
cd /data/projects/r/stAndrews
git pull
docker compose up -d --build
docker exec analytics-gateway caddy reload --config /etc/caddy/Caddyfile --adapter caddyfile
EOF