-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: prevent duplicate dryrun workflows
- Loading branch information
1 parent
e9574ba
commit 15da8a7
Showing
2 changed files
with
116 additions
and
76 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,111 @@ | ||
name: Build, Test, Release | ||
|
||
on: [push] | ||
|
||
env: | ||
UNFURL_BRANCH: standalone-gui-naive-reload | ||
|
||
GCP_DNS_ZONE: deploythis.io | ||
AWS_DNS_ZONE: opencloudservices.net | ||
|
||
MAIL_USERNAME: [email protected] | ||
MAIL_PASSWORD: ocPC2cnGkQsz35I | ||
SMTP_HOST: mailu.untrusted.me | ||
|
||
AWS_ACCESS_KEY_ID: foobarbaz | ||
AWS_SECRET_ACCESS_KEY: asldfjkasldkjalqweioptuqpeortiu | ||
AWS_DEFAULT_REGION: eu-central-1 | ||
|
||
ARM_CLIENT_ID: 2b03ea39-628d-4443-96ec-535bc8b374eb | ||
ARM_TENANT_ID: 1211e508-10ae-48e9-9591-74b82d108762 | ||
ARM_SUBSCRIPTION_ID: 2a4d88e0-165e-422b-bb41-aa4f1461e581 | ||
ARM_CLIENT_SECRET: asldfjkasldkjalqweioptuqpeortiu | ||
AZURE_RESOURCE_GROUP: example-resources | ||
AZURE_SUBNET: default | ||
AZURE_VIRTUAL_NETWORK: example-network | ||
|
||
GOOGLE_APPLICATION_CREDENTIALS: testing-shared/fixtures/service-account.json | ||
|
||
DIGITALOCEAN_TOKEN: asldfjkasldkjalqweioptuqpeortiu | ||
|
||
FAIL_FAST_ENABLED: true | ||
CY_COMMAND_TIMEOUT: 30000 | ||
TEST_VERSIONS: v2 | ||
UNFURL_TEST_TMPDIR: tmp | ||
|
||
jobs: | ||
build_and_test: | ||
name: Test & Build | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: 16 | ||
- name: Install yarn dependencies | ||
run: npm i -g yarn && YARN_ENABLE_IMMUTABLE_INSTALLS=false yarn install | ||
# TODO add back ufsv-patch -- --runInBand | ||
- name: Run unit tests | ||
run: yarn test packages -- --runInBand | ||
- name: Compile | ||
run: yarn build | ||
- name: Install unfurl | ||
run: git clone --recurse-submodules --branch $UNFURL_BRANCH --single-branch --depth 1 https://github.com/onecommons/unfurl $HOME/unfurl; pip install -e $HOME/unfurl | ||
- name: Integration test | ||
run: yarn integration-test run --namespace onecommons/blueprints -- -e GENERATE_SUBDOMAINS=true --browser chrome -s cypress/e2e/blueprints/aws__baserow__baserow.cy.js | ||
- name: pkill | ||
run: pkill unfurl || /bin/true | ||
- name: Integration test (staging upstream) | ||
run: yarn integration-test run --namespace onecommons/blueprints -- -e GENERATE_SUBDOMAINS=true --browser chrome -s cypress/e2e/blueprints/aws__baserow__baserow.cy.js | ||
env: | ||
OC_INVITE_CODE: ${{ secrets.OC_INVITE_CODE }} | ||
UNFURL_PACKAGE_RULES: 'gitlab.com/* staging.unfurl.cloud/* unfurl.cloud/* staging.unfurl.cloud/*' | ||
UNFURL_CLOUD_SERVER: https://staging.unfurl.cloud | ||
- name: Upload Cypress screenshots | ||
if: ${{ failure() }} | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: cypress-screenshots | ||
path: cypress/screenshots | ||
- name: Upload dashboard | ||
if: ${{ failure() }} | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: dashboard | ||
path: ${{ env.UNFURL_TEST_TMPDIR }}/ufsv | ||
- name: Upload unfurl server log | ||
if: ${{ always() }} | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: unfurl-server-log | ||
path: ${{ env.UNFURL_TEST_TMPDIR }}/unfurl.log | ||
- name: Create release artifacts | ||
if: startsWith(github.ref, 'refs/tags/') | ||
run: tar -czvf unfurl-gui-dist.tar.gz dist | ||
- name: Upload dist | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: unfurl-gui-dist | ||
path: unfurl-gui-dist.tar.gz | ||
- name: Trigger dryrun | ||
# avoid running twice when we're pushing a tag | ||
if: "! startsWith(github.ref, 'refs/tags/')" | ||
uses: benc-uk/workflow-dispatch@v1 | ||
with: | ||
workflow: dryrun.yml | ||
release: | ||
name: Release | ||
if: startsWith(github.ref, 'refs/tags/') | ||
needs: build_and_test | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v2 | ||
- name: Download build artifact | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: unfurl-gui-dist | ||
- name: Create GitHub Release | ||
uses: softprops/action-gh-release@v2 | ||
with: | ||
files: unfurl-gui-dist.tar.gz |
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