From d8114dd3c01442580a719364dd54207c0c6ca8d0 Mon Sep 17 00:00:00 2001 From: Cameron Hyde Date: Fri, 4 Oct 2024 09:23:14 +1000 Subject: [PATCH] Deploy workflows use sudo --- .github/workflows/deploy-dev.yml | 2 +- .github/workflows/deploy.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/deploy-dev.yml b/.github/workflows/deploy-dev.yml index 0861a78b..2747f985 100644 --- a/.github/workflows/deploy-dev.yml +++ b/.github/workflows/deploy-dev.yml @@ -23,6 +23,6 @@ jobs: echo "${{ secrets.SSH_PRIVATE_KEY_DEV }}" > ~/.ssh/id_rsa ssh-keyscan -H ${{ secrets.SSH_HOST_DEV }} > ~/.ssh/known_hosts - name: connect and pull - run: ssh ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST_DEV }} "./update.sh && exit" + run: ssh ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST_DEV }} "sudo ./update.sh && exit" - name: cleanup run: rm -rf ~/.ssh diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 69283dad..4177f992 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -23,6 +23,6 @@ jobs: echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa ssh-keyscan -H ${{ secrets.SSH_HOST }} > ~/.ssh/known_hosts - name: connect and pull - run: ssh ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} "./update.sh && exit" + run: ssh ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} "sudo ./update.sh && exit" - name: cleanup run: rm -rf ~/.ssh