Skip to content

Commit

Permalink
Update CI actions in release workflow (#218)
Browse files Browse the repository at this point in the history
* update ci actions in release workflow

* chore: update env vars

Co-authored-by: Raúl Barroso <[email protected]>
  • Loading branch information
lovromazgon and raulb authored Nov 10, 2021
1 parent 1b75360 commit 80d8ac9
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 17 deletions.
29 changes: 15 additions & 14 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,34 +32,35 @@ jobs:
- name: Build and Run
working-directory: ./acceptance
env:
AUTH0_CLIENT_ID: ${{ secrets.AUTH0_ACCEPTANCE_STAGING_CLIENT_ID }}
AUTH0_DOMAIN: ${{ secrets.AUTH0_STAGING_DOMAIN }}
AUTH0_AUDIENCE: ${{ secrets.AUTH0_STAGING_AUDIENCE }}
AUTH0_CLIENT_SECRET: ${{ secrets.AUTH0_ACCEPTANCE_STAGING_CLIENT_SECRET }}
AUTH0_PASSWORD: ${{ secrets.AUTH0_PASSWORD }}
AUTH0_USERNAME: ${{ secrets.AUTH0_USERNAME }}
MEROXA_AUTH_CLIENT_ID: ${{ secrets.AUTH0_ACCEPTANCE_STAGING_CLIENT_ID }}
MEROXA_AUTH_DOMAIN: ${{ secrets.AUTH0_STAGING_DOMAIN }}
MEROXA_AUTH_AUDIENCE: ${{ secrets.AUTH0_STAGING_AUDIENCE }}
MEROXA_AUTH_CLIENT_SECRET: ${{ secrets.AUTH0_ACCEPTANCE_STAGING_CLIENT_SECRET }}
MEROXA_AUTH_PASSWORD: ${{ secrets.AUTH0_PASSWORD }}
MEROXA_AUTH_USERNAME: ${{ secrets.AUTH0_USERNAME }}
PG_URL: ${{ secrets.TEST_DB_URL }}
PRIVATE_PG_URL: ${{ secrets.TEST_PRIVATE_PG_URL }}
MYSQL_URL: ${{ secrets.TEST_MYSQL_URL }}
SQLSERVER_URL: ${{ secrets.TEST_SQLSERVER_URL }}
API_URL: "https://api.staging.meroxa.io"
MEROXA_API_URL: "https://api.staging.meroxa.io"
BASTION_PRIVATE_KEY: ${{ secrets.TEST_BASTION_PRIVATE_KEY }}
BASTION_USER: "ec2-user"
BASTION_URL: ${{ secrets.TEST_BASTION_URL }}
run: |
docker build -t meroxa/acceptance --build-arg=CLI_PATH=./cli .
docker run \
-e AUTH0_DOMAIN=${AUTH0_DOMAIN} \
-e AUTH0_CLIENT_ID=${AUTH0_CLIENT_ID} \
-e AUTH0_CLIENT_SECRET=${AUTH0_CLIENT_SECRET} \
-e AUTH0_PASSWORD=${AUTH0_PASSWORD} \
-e AUTH0_USERNAME=${AUTH0_USERNAME} \
-e AUTH0_AUDIENCE=${AUTH0_AUDIENCE} \
-e MEROXA_AUTH_DOMAIN=${MEROXA_AUTH_DOMAIN} \
-e MEROXA_AUTH_CLIENT_ID=${MEROXA_AUTH_CLIENT_ID} \
-e MEROXA_AUTH_CLIENT_SECRET=${MEROXA_AUTH_CLIENT_SECRET} \
-e MEROXA_AUTH_PASSWORD=${MEROXA_AUTH_PASSWORD} \
-e MEROXA_AUTH_USERNAME=${MEROXA_AUTH_USERNAME} \
-e MEROXA_AUTH_AUDIENCE=${MEROXA_AUTH_AUDIENCE} \
-e ACCEPTANCE_TEST_POSTGRES_URL=${PG_URL} \
-e ACCEPTANCE_TEST_PRIVATE_POSTGRES_URL=${PRIVATE_PG_URL} \
-e ACCEPTANCE_TEST_MYSQL_URL=${MYSQL_URL} \
-e ACCEPTANCE_TEST_SQLSERVER_URL=${SQLSERVER_URL} \
-e ACCEPTANCE_TEST_BASTION_PRIVATE_KEY="${BASTION_PRIVATE_KEY}" \
-e ACCEPTANCE_TEST_BASTION_USER=${BASTION_USER} \
-e ACCEPTANCE_TEST_BASTION_URL=${BASTION_URL} \
meroxa/acceptance -test.v -api-host $API_URL
-e ACCEPTANCE_TEST_API_HOST=${MEROXA_API_URL} \
meroxa/acceptance -test.v
6 changes: 3 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,16 @@ jobs:
-
name: Import GPG key
id: import_gpg
uses: crazy-max/ghaction-import-gpg@v3.1.0
uses: crazy-max/ghaction-import-gpg@v4
with:
gpg-private-key: ${{ secrets.MEROXA_MACHINE_GPG_KEY }}
passphrase: ${{ secrets.MEROXA_MACHINE_GPG_PASSPHRASE }}
-
name: Run GoReleaser
uses: goreleaser/goreleaser-action@v1
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: release --rm-dist
env:
GPG_FINGERPRINT: ${{ steps.import_gpg.outputs.fingerprint }}
GITHUB_TOKEN: ${{ secrets.MEROXA_MACHINE }}
GITHUB_TOKEN: ${{ secrets.MEROXA_MACHINE }}

0 comments on commit 80d8ac9

Please sign in to comment.