Skip to content

Commit

Permalink
ci(taiko-client,repo): add proverserverapi workflows (#17057)
Browse files Browse the repository at this point in the history
  • Loading branch information
RogerLamTd authored May 10, 2024
1 parent 06c92ad commit b90b932
Show file tree
Hide file tree
Showing 5 changed files with 91 additions and 67 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/blobstorage-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ on:
- "packages/blobstorage/**"

jobs:
deploy-bolbstorage-preview:
deploy-blobstorage-preview:
runs-on: [taiko-runner]
steps:
- name: Checkout repository
Expand Down
46 changes: 46 additions & 0 deletions .github/workflows/taiko-client-proverapi-preview.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Prover Server API Preview

env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID_PROVER_SERVER }}

on:
workflow_dispatch:
push:
branches-ignore:
- main
- release-please-*
paths:
- "packages/taiko-client/**"

jobs:
deploy-proverserver-api-preview:
runs-on: [taiko-runner]
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install pnpm dependencies
uses: ./.github/actions/install-pnpm-dependencies

- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.22.0

- name: Install swag cli
run: go install github.com/swaggo/swag/cmd/swag@latest

- name: Install Vercel CLI
run: pnpm add --global vercel@latest

- name: Swag autogen
working-directory: packages/taiko-client
run: ./scripts/gen_swagger_json.sh

- name: Pull Vercel Environment Information
run: vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }}

- name: Deploy Project Artifacts to Vercel
working-directory: packages/taiko-client
run: vercel --token=${{ secrets.VERCEL_TOKEN }}
43 changes: 43 additions & 0 deletions .github/workflows/taiko-client-proverapi-production.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Prover Server API Production

env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID_PROVER_SERVER }}

on:
workflow_dispatch:
push:
tags:
- "taiko-client-*"

jobs:
deploy-proverserver-api-production:
runs-on: [taiko-runner]
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Install pnpm dependencies
uses: ./.github/actions/install-pnpm-dependencies

- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.22.0

- name: Install swag cli
run: go install github.com/swaggo/swag/cmd/swag@latest

- name: Install Vercel CLI
run: pnpm add --global vercel@latest

- name: Swag autogen
working-directory: packages/taiko-client
run: ./scripts/gen_swagger_json.sh

- name: Pull Vercel Environment Information
run: vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }}

- name: Deploy Project Artifacts to Vercel
working-directory: packages/taiko-client
run: vercel --token=${{ secrets.VERCEL_TOKEN }}
65 changes: 0 additions & 65 deletions .github/workflows/taiko-client-swagger.yml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
window.onload = function () {
// Begin Swagger UI call region
const ui = SwaggerUIBundle({
url: "./docs/swagger.json", //Location of Open API spec in the repo
url: "/swagger.json", // Location of Open API spec in the repo
dom_id: '#swagger-ui',
deepLinking: true,
presets: [
Expand Down

0 comments on commit b90b932

Please sign in to comment.