Deploy skeleton-app
Build and Deploy / build-and-push (push) Successful in 56s Details

This commit is contained in:
ImNotTheGuy 2026-04-21 14:57:53 +02:00
parent 083982814f
commit e7e0b93c17
3 changed files with 22 additions and 2 deletions

View File

@ -18,7 +18,7 @@ jobs:
username: ${{ gitea.actor }}
password: ${{ secrets.CI_TOKEN }}
- name: Build and Pushz
- name: Build and Push
uses: docker/build-push-action@v4
with:
context: .
@ -28,5 +28,6 @@ jobs:
- name: Deploy to Server
run: |
# Here we tell the server to pull the new image and restart
echo "${{ secrets.CI_TOKEN }}" | docker login git.ludops.com -u ${{ gitea.actor }} --password-stdin
docker compose -f docker-compose.prod.yml pull
docker compose -f docker-compose.prod.yml up -d

View File

@ -33,4 +33,4 @@ COPY --from=build /app/packages/shared ./packages/shared
EXPOSE 3000
# Update this path to wherever your compiled Fastify entry point is
CMD ["node", "api/src/index.ts"]
CMD ["node", "api/index.js"]

19
docker-compose.prod.yml Normal file
View File

@ -0,0 +1,19 @@
services:
skeleton-app:
image: git.ludops.com/ludops/ludops-skeleton:latest
container_name: ludops-skeleton-app
restart: always
environment:
- NODE_ENV=production
- PORT=3000
# We point to the shared DB we set up earlier
- DATABASE_URL=postgres://gitea:gitea@ludops-postgres:5432/skeleton_db
networks:
- proxy-tier # For NPM to find us
- infrastructure_infra-network # For us to find the Postgres DB
networks:
proxy-tier:
external: true
infrastructure_infra-network:
external: true