Skip to content

Commit ecb1dcd

Browse files
committed
See if github sha is in deployment
1 parent eac8f01 commit ecb1dcd

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

.github/scripts/deploy_deepgit.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ git pull origin deploy --quiet
99
npm --silent install
1010
rm -rf dist
1111
npm run --silent build
12+
touch dist/$(git log -1 --pretty=format:%H)
1213
sudo rm -rf /var/www/deepgit-app/*
1314
sudo cp -rf ~/projects/deepgit/dist/* /var/www/deepgit-app/.
1415

.github/workflows/deploy_gcp.yml

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,11 @@ jobs:
3232
script: ${{ github.workspace }}/.github/scripts/deploy_deepgit.sh
3333

3434
- id: 'check-deployment-status'
35-
run: |-
36-
echo '${{ steps.compute-ssh.outputs.stdout }}'
37-
echo '${{ steps.compute-ssh.outputs.stderr }}'
35+
uses: 'google-github-actions/ssh-compute@v1'
36+
with:
37+
instance_name: 'instance-1'
38+
project_id: 'deepgit'
39+
user: "user"
40+
zone: 'us-central1-f'
41+
ssh_private_key: '${{ secrets.GCP_SSH_PRIVATE_KEY }}'
42+
command: 'ls /var/www/deepgit-app/${{ github.sha }}'

0 commit comments

Comments
 (0)