Skip to content

Commit

Permalink
Merge pull request #20 from planimation/deployment
Browse files Browse the repository at this point in the history
added workflow to deploy docker image when new release tag is created
  • Loading branch information
nirlipo authored Aug 27, 2024
2 parents b2b2720 + c94145e commit 01027ab
Showing 1 changed file with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Publish Docker image

on:
release:
types: [published]
# push:
# branches:
# - 'develop'
jobs:
push_to_registry:
name: Push Docker image to Docker Hub
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v4

- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: build the docker image
id: build-docker-image
run: |
ls -la
cd server
docker build . -f docker/release/Dockerfile -t nirlipo/planimation_frontend_js:latest
- name: push the docker image
id: push-docker-image
run: docker push ${{secrets.DOCKERHUB_USERNAME}}/planimation_frontend_js:latest

0 comments on commit 01027ab

Please sign in to comment.