Skip to content

Commit

Permalink
Test actions commit
Browse files Browse the repository at this point in the history
  • Loading branch information
SalkCoding committed Dec 8, 2024
1 parent 2fcb55b commit 4314734
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions .github/workflows/CD.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ jobs:
uses: docker/build-push-action@v2
with:
context: .
file: ./Dockerfile
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/backend:latest
build-args: |
Expand All @@ -34,9 +35,8 @@ jobs:
- name: Set environment variables
run: |
echo "MYSQL_DATABASE=${{ secrets.DB_NAME }}" > .env
echo "MYSQL_ROOT_PASSWORD=${{ secrets.DB_PASSWORD }}" >> .env
echo "MYSQL_ROOT_PASSWORD=${{ secrets.MYSQL_ROOT_PASSWORD }}" >> .env
- name: Deploy Application
uses: appleboy/[email protected]
Expand All @@ -45,14 +45,11 @@ jobs:
username: ${{ secrets.REMOTE_USERNAME }}
key: ${{ secrets.REMOTE_KEY }}
script: |
echo "### Change directory to Sasimee-Back ###"
cd /home/ubuntu/Backend
echo "### Change directory to Backend ###"
cd /home/***/Backend
echo "### Pull origin main from github ###"
git pull origin main
echo "### Pull new image from dockerhub###"
sudo docker compose build backend
git pull origin actions
echo "### Shutdown existing container ###"
sudo docker compose down
Expand Down

0 comments on commit 4314734

Please sign in to comment.