Skip to content

Commit

Permalink
ci: compose for workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
kurunbelemir committed Feb 19, 2025
1 parent e5eae6e commit 178a948
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/deploy-prod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Deploy to Development

on:
workflow_dispatch: # For manual triggers via the GitHub Actions UI
inputs:
image-tag:
type: string
description: "Image tag to deploy (default: pr-<number> if PR exists, latest for default branch)"

jobs:
deploy:
uses: ls1intum/.github/.github/workflows/deploy-docker-compose.yml@main
with:
environment: Development # Replace with your environment
docker-compose-file: "./docker-compose.prod.yml" # Path to your docker-compose file
main-image-name: ls1intum/apollon2# For checking if images with image tag exist
image-tag: ${{ inputs.image-tag }}
env-file-name: .env.test1 # (Optional) Path to the .env file, defaults to .env
remove-volumes: false # (Optional) Remove volumes after stopping the services
secrets: inherit
9 changes: 9 additions & 0 deletions docker-compose.prod.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
version: '3.8'

services:
webapp:
image: "ghcr.io/ls1intum/apollon2/<apollon2:${IMAGE_TAG}"
ports:
- "8080:80"

restart: unless-stopped

0 comments on commit 178a948

Please sign in to comment.