diff --git a/.gitea/workflows/gitea-actions.yml b/.gitea/workflows/gitea-actions.yml index d8d962d..d349733 100644 --- a/.gitea/workflows/gitea-actions.yml +++ b/.gitea/workflows/gitea-actions.yml @@ -11,10 +11,18 @@ jobs: run: | cat ${{ secrets.ENV_PROD }} > .env cat ./.env - # - name: Stop site service - # run: systemctl stop resume + - name: Stop site service on remote server + uses: D3rHase/ssh-command-action@v0.2.2 + with: + host: ${{secrets.SSH_HOST}} + user: ${{secrets.SSH_USER}} + private_key: ${{secrets.SSH_PRIVATE_KEY}} + command: | + systemctl stop resume - name: Checkout code uses: actions/checkout@v3 + - name: Install PHP + run: apt update && apt install -y php-cli php-intl php-mbstring php-xml php-zip - name: Install Composer run: | php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" @@ -42,5 +50,11 @@ jobs: REMOTE_HOST: ${{ secrets.SSH_HOST }} REMOTE_USER: ${{ secrets.SSH_USER }} TARGET: ${{ secrets.SSH_DIR }} - #- name: Start site service - # run: systemctl start resume \ No newline at end of file + - name: Start site service on remote server + uses: D3rHase/ssh-command-action@v0.2.2 + with: + host: ${{secrets.SSH_HOST}} + user: ${{secrets.SSH_USER}} + private_key: ${{secrets.SSH_PRIVATE_KEY}} + command: | + systemctl start resume \ No newline at end of file