Skip to content

Commit

Permalink
iniciar sesion en docker
Browse files Browse the repository at this point in the history
  • Loading branch information
paulasuarezp committed Jun 28, 2024
1 parent 0fae687 commit 989c5e8
Showing 1 changed file with 12 additions and 4 deletions.
16 changes: 12 additions & 4 deletions .github/workflows/TFG.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,22 @@ jobs:
- name: Create docker-compose.yml
run: echo "${{ secrets.DOCKER_COMPOSE_DEPLOY }}" > docker-compose.yml

- name: Docker Login on Remote
uses: fifsky/ssh-action@master
with:
host: ${{ secrets.DEPLOY_HOST }}
user: ${{ secrets.DEPLOY_USER }}
key: ${{ secrets.DEPLOY_KEY }}
command: echo ${{ secrets.GITHUB_TOKEN }} | docker login ghcr.io -u ${{ github.actor }} --password-stdin

- name: Deploy over SSH
uses: fifsky/ssh-action@master
with:
host: ${{ secrets.DEPLOY_HOST }}
user: ${{ secrets.DEPLOY_USER }}
key: ${{ secrets.DEPLOY_KEY }}
command: |
docker-compose stop
docker-compose rm -f
docker-compose pull
docker-compose up -d
sudo docker-compose stop
sudo docker-compose rm -f
sudo docker-compose pull
sudo docker-compose up -d

0 comments on commit 989c5e8

Please sign in to comment.