diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml new file mode 100644 index 0000000..6c8ae13 --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,30 @@ +--- +name: Deploy Latest + +on: + push: + branches: + - 'master' + +jobs: + + deploy: + runs-on: ubuntu-latest + timeout-minutes: 5 + steps: + + - name: install + uses: appleboy/ssh-action@v1.1.0 + with: + host: ${{ secrets.HOST }} + username: ${{ secrets.USERNAME }} + key: ${{ secrets.KEY }} + port: ${{ secrets.PORT }} + passphrase: ${{ secrets.PASSPHRASE }} + script: | + set -euo pipefail + cd /opt/compose + git checkout master + git pull + docker compose pull + docker compose up -d diff --git a/.gitignore b/.gitignore index 5705c1c..95acfcd 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,3 @@ -.* +.env* /sync-data /wordpress