Skip to content

Commit

Permalink
Merge pull request #23 from CivicTechTO/feature/docker-ghcr-release
Browse files Browse the repository at this point in the history
GitHub Action push Docker image to GitHub Container Registry
Now Docker images builded automatically pushed to https://github.com/orgs/CivicTechTO/packages
  • Loading branch information
NewJerseyStyle authored Oct 10, 2024
2 parents b5f5054 + c40254a commit f59e20d
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions .github/workflows/release-docker-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,15 @@ jobs:
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_TOKEN }}
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.CR_PAT }}

- name: Build full project via docker-compose
run: |
mv example.env .env
sed -i 's/compdem/${{ secrets.DOCKER_USERNAME }}/g' docker-compose.yml
sed -i 's/docker.io/ghcr.io/g' docker-compose.yml
sed -i 's/compdem/civictechto/g' docker-compose.yml
docker compose build --parallel --build-arg GIT_HASH=${GITHUB_SHA:0:6}
- name: Push images to Docker Hub
Expand Down

0 comments on commit f59e20d

Please sign in to comment.