From 764ffcebe9cce0e9aa2bbd9c52791e3e1376ff06 Mon Sep 17 00:00:00 2001 From: Dhaverd Date: Wed, 13 Mar 2024 10:47:22 +0300 Subject: [PATCH] =?UTF-8?q?=D0=9E=D0=B1=D0=BD=D0=BE=D0=B2=D0=B8=D1=82?= =?UTF-8?q?=D1=8C=20.gitea/workflows/gitea-actions.yml?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitea/workflows/gitea-actions.yml | 22 ++++++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) 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