Никита Круглицкий 062d48a3d7
All checks were successful
Deploy / build (push) Successful in 33s
ci/cd
2025-09-26 01:05:53 +06:00

41 lines
1.0 KiB
YAML

name: Deploy
on:
push:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Keyscan
run: |
ssh-keyscan git.koptilnya.xyz >> ~/.ssh/known_hosts
- name: Checkout
uses: actions/checkout@v4
with:
ssh-key: ${{ secrets.SSH_PRIVATE_KEY }}
ssh-strict: false
persist-credentials: false
- name: Build
run: docker build -t paxton:latest .
- name: Stop old container
run: docker rm -f paxton || true
- name: Run
run: |
docker run -d \
--name paxton \
--network traefik \
--label "traefik.enable=true" \
--label "traefik.http.routers.paxton.rule=Host(\`paxton.koptilnya.xyz\`)" \
--label "traefik.http.routers.paxton.entrypoints=websecure" \
--label "traefik.http.routers.paxton.tls.certresolver=myresolver" \
--label "traefik.http.services.paxton.loadbalancer.server.port=80" \
paxton:latest