test run #3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: test | |
run-name: test run | |
on: | |
workflow_dispatch: | |
jobs: | |
default-job: | |
permissions: | |
contents: 'read' | |
id-token: 'write' | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Check out `empower-config` to get env-config | |
uses: actions/checkout@v3 | |
with: | |
repository: sentry-demos/empower-config | |
path: empower-config | |
token: ${{ secrets.KOSTY_PERSONAL_ACCESS_TOKEN_FOR_SYNC_DEPLOY_FORK }} | |
- name: Get GCP_ env variables from empower-config/.gcloudrc | |
run: | | |
source empower-config/.gcloudrc | |
echo "GCP_WORKLOAD_IDENTITY_PROVIDER=$GCP_WORKLOAD_IDENTITY_PROVIDER" >> $GITHUB_OUTPUT | |
echo "GCP_SERVICE_ACCOUNT=$GCP_SERVICE_ACCOUNT" >> $GITHUB_OUTPUT | |
id: gcloudrc | |
- id: 'auth' | |
name: 'Authenticate Google Cloud' | |
uses: 'google-github-actions/auth@v0' | |
with: | |
workload_identity_provider: ${{ steps.gcloudrc.outputs.GCP_WORKLOAD_IDENTITY_PROVIDER }} | |
service_account: ${{ steps.gcloudrc.outputs.GCP_SERVICE_ACCOUNT }} | |
- name: 'Set up Google Cloud SDK' | |
uses: 'google-github-actions/setup-gcloud@v0' | |
- name: 'Try ssh-ing into GCP host' | |
run: gcloud compute ssh empower-tda-and-crons --zone us-central1-a -- ls | |
- run: echo "Job status is ${{ job.status }}." |