name: deploy-docker
run-name: deploy-docker ${{ github.actor }} 
on:
  workflow_dispatch:
jobs:
  # https://github.com/appleboy/ssh-action
  # act -W .github/workflows/deploy.yaml -j remote-deploy -s SSH_PASSWORD
  remote-deploy:
    runs-on: ubuntu-latest
    steps:
      - name: Remote Deployment
        uses: appleboy/ssh-action@v0.1.8
        with:
          host: frappet.com
          username: frappet
          password: ${{ secrets.SSH_PASSWORD }}
          port: 22
          script: |
            cd /home/frappet/docker/bma-ehr-recruit-qualifying-exam
            docker-compose pull
            docker-compose up -d
            touch success

