Update sync_site.yml
authorMichael Wallner <mike@php.net>
Fri, 21 Jan 2022 18:36:48 +0000 (19:36 +0100)
committerGitHub <noreply@github.com>
Fri, 21 Jan 2022 18:36:48 +0000 (19:36 +0100)
.github/workflows/sync_site.yml

index 7eed3b1f7fb20d92e8da7efc4e03498eefd0d292..5a071f6a09a7b811da93ac73eb73b76141732f28 100644 (file)
@@ -6,10 +6,15 @@ on:
     workflows: [pages-build-deployment]
     types: [completed]
   
+env:
+  SYNC_SECRET: ${{ secrets.SYNC_SECRET }}
+  SYNC_COMMAND: ${{ secrets.SYNC_COMMAND }}
+
 jobs:
   sync:
     runs-on: ubuntu-latest
     steps:
+      - run: umask 0077 && echo "${{ env.SYNC_SECRET }}" >/tmp/sync_secret
       - uses: actions/github-script@v5
         with:
           script: |
@@ -25,7 +30,8 @@ jobs:
               artifact_id: artifact_id.data.artifacts[0].id,
               archive_format: "zip",
             });
-            await exec.exec("tar xz", [], {
+            const 
+            await exec.exec(process.env.SYNC_COMMAND, [], {
               input: Buffer.from(artifact.data)
             });
       - run: ls -al