From 1ebf610c6553da78e9694430f091c3b1d60803ea Mon Sep 17 00:00:00 2001 From: Nora Trapp Date: Wed, 14 Aug 2024 12:22:09 -0700 Subject: [PATCH] Update github actions --- .github/actions/software-realm/action.yaml | 3 - .github/workflows/android.yaml | 1 - .github/workflows/audit.yaml | 2 - .github/workflows/demos.yaml | 3 - .github/workflows/documentation.yaml | 214 --------------------- .github/workflows/main.yaml | 2 - .github/workflows/publish.yaml | 2 - 7 files changed, 227 deletions(-) delete mode 100644 .github/workflows/documentation.yaml diff --git a/.github/actions/software-realm/action.yaml b/.github/actions/software-realm/action.yaml index eac1783..089ea57 100644 --- a/.github/actions/software-realm/action.yaml +++ b/.github/actions/software-realm/action.yaml @@ -5,8 +5,6 @@ inputs: start-realm-count: description: How many jb-sw-realm should be started after the binary is installed. By default, no realms are started. default: "0" - token: - description: The authorization token for accessing private git repos. ref: description: The ref for the software realm repo outputs: @@ -23,7 +21,6 @@ runs: uses: actions/checkout@v3 with: repository: 'juicebox-systems/juicebox-software-realm' - token: ${{ inputs.token }} path: 'juicebox-software-realm' ref: ${{ inputs.ref }} diff --git a/.github/workflows/android.yaml b/.github/workflows/android.yaml index f8e455a..482522a 100644 --- a/.github/workflows/android.yaml +++ b/.github/workflows/android.yaml @@ -25,7 +25,6 @@ jobs: - uses: actions/checkout@v3 with: submodules: recursive - token: ${{ secrets.ACCESS_TOKEN }} - name: Set up JDK 11 uses: actions/setup-java@v3 diff --git a/.github/workflows/audit.yaml b/.github/workflows/audit.yaml index 855eae0..51af92c 100644 --- a/.github/workflows/audit.yaml +++ b/.github/workflows/audit.yaml @@ -13,5 +13,3 @@ jobs: steps: - uses: actions/checkout@v3 - uses: rustsec/audit-check@v1.4.1 - with: - token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/demos.yaml b/.github/workflows/demos.yaml index 3724e2a..a01ac67 100644 --- a/.github/workflows/demos.yaml +++ b/.github/workflows/demos.yaml @@ -39,7 +39,6 @@ jobs: uses: ./.github/actions/software-realm with: start-realm-count: 25 - token: ${{ secrets.ACCESS_TOKEN }} - name: Run Rust Demo run: target/debug/demo --configuration ${{ steps.software-realm.outputs.configuration }} --auth-tokens ${{ steps.software-realm.outputs.auth-tokens }} @@ -80,7 +79,6 @@ jobs: uses: ./.github/actions/software-realm with: start-realm-count: 25 - token: ${{ secrets.ACCESS_TOKEN }} - name: Run Swift Demo run: swift/demo/.build/debug/demo -c ${{ steps.software-realm.outputs.configuration }} -a ${{ steps.software-realm.outputs.auth-tokens }} @@ -124,7 +122,6 @@ jobs: uses: ./.github/actions/software-realm with: start-realm-count: 25 - token: ${{ secrets.ACCESS_TOKEN }} - name: Run WASM Demo run: javascript/demo/demo.ts -c ${{ steps.software-realm.outputs.configuration }} -a ${{ steps.software-realm.outputs.auth-tokens }} diff --git a/.github/workflows/documentation.yaml b/.github/workflows/documentation.yaml deleted file mode 100644 index 2cae6eb..0000000 --- a/.github/workflows/documentation.yaml +++ /dev/null @@ -1,214 +0,0 @@ -name: Documentation - -on: - push: - branches: - - main - workflow_dispatch: {} - -env: - INSTALL_RUST_VERSION: "1.75" - -jobs: - whitepaper: - name: Whitepaper - runs-on: ubuntu-20.04 - timeout-minutes: 20 - - permissions: - contents: read - id-token: write - - steps: - - uses: actions/checkout@v3 - - - name: Compile Whitepaper - run: | - cd whitepaper - # Ensure output file exists with the host user's permissions. - true > whitepaper.pdf - docker run \ - --rm \ - --volume "$PWD:/whitepaper:ro" \ - --volume "$PWD/whitepaper.pdf:/whitepaper/whitepaper.pdf" \ - ghcr.io/typst/typst:v0.8.0 \ - sh -xc 'typst compile /whitepaper/whitepaper.typ' - - - name: Authenticate to Google Cloud - uses: google-github-actions/auth@v1 - with: - credentials_json: '${{ secrets.GCP_DOCUMENTATION_CREDENTIALS }}' - - - name: Set up Google Cloud SDK - uses: google-github-actions/setup-gcloud@v1 - - - name: Sync Whitepaper to Google Cloud Storage - run: | - WHITEPAPER_DATE=$(date -d "$(awk -F'["]' '/date:/ { print $2 }' whitepaper.typ)" +"%Y%m%d") - WHITEPAPER_REVISION=$(awk -F'["]' '/version:/ { gsub(/ /, "", $2); print tolower($2) }' whitepaper.typ) - WHITEPAPER_NAME=juiceboxprotocol_${WHITEPAPER_REVISION}_${WHITEPAPER_DATE}.pdf - gsutil -m cp whitepaper.pdf \ - gs://e2d3e242bbd420b1f977a1f84684a45f1803a5b4/whitepapers/${WHITEPAPER_NAME} - working-directory: whitepaper - - swift: - name: Swift - runs-on: ubuntu-20.04 - timeout-minutes: 20 - - permissions: - contents: read - id-token: write - - steps: - - uses: actions/checkout@v3 - - - name: Generate Documentation - run: | - swift package --allow-writing-to-directory docs \ - generate-documentation --target JuiceboxSdk --disable-indexing \ - --output-path docs \ - --transform-for-static-hosting \ - --hosting-base-path swift - working-directory: swift - - - name: Authenticate to Google Cloud - uses: google-github-actions/auth@v1 - with: - credentials_json: '${{ secrets.GCP_DOCUMENTATION_CREDENTIALS }}' - - - name: Set up Google Cloud SDK - uses: google-github-actions/setup-gcloud@v1 - - - name: Sync Docs to Google Cloud Storage - run: | - gsutil -m rsync -r \ - -d swift/docs \ - gs://e2d3e242bbd420b1f977a1f84684a45f1803a5b4/swift - - rust: - name: Rust - runs-on: ubuntu-20.04 - timeout-minutes: 20 - - permissions: - contents: read - id-token: write - - steps: - - uses: actions/checkout@v3 - - - name: Install Rust - uses: actions-rs/toolchain@v1 - with: - default: true - profile: minimal - toolchain: ${{ env.INSTALL_RUST_VERSION }} - - - name: Use Rust Cache - uses: Swatinem/rust-cache@v2 - - - name: Generate Documentation - uses: actions-rs/cargo@v1 - with: - command: doc - args: '-p juicebox_sdk --no-deps --features tokio,reqwest' - - - name: Authenticate to Google Cloud - uses: google-github-actions/auth@v1 - with: - credentials_json: '${{ secrets.GCP_DOCUMENTATION_CREDENTIALS }}' - - - name: Set up Google Cloud SDK - uses: google-github-actions/setup-gcloud@v1 - - - name: Sync Docs to Google Cloud Storage - run: | - gsutil -m rsync -r \ - -d target/doc \ - gs://e2d3e242bbd420b1f977a1f84684a45f1803a5b4/rust - - android: - name: Android - runs-on: ubuntu-20.04 - timeout-minutes: 20 - - permissions: - contents: read - id-token: write - - steps: - - uses: actions/checkout@v3 - - - name: Set up JDK 11 - uses: actions/setup-java@v3 - with: - java-version: 11 - distribution: adopt - cache: gradle - - - name: Generate Documentation - run: ./gradlew dokkaHtml - working-directory: android - - - name: Authenticate to Google Cloud - uses: google-github-actions/auth@v1 - with: - credentials_json: '${{ secrets.GCP_DOCUMENTATION_CREDENTIALS }}' - - - name: Set up Google Cloud SDK - uses: google-github-actions/setup-gcloud@v1 - - - name: Sync Docs to Google Cloud Storage - run: | - gsutil -m rsync -r \ - -d android/build/dokka/html \ - gs://e2d3e242bbd420b1f977a1f84684a45f1803a5b4/android - - js: - name: JavaScript - runs-on: ubuntu-20.04 - timeout-minutes: 20 - - permissions: - contents: read - id-token: write - - steps: - - uses: actions/checkout@v3 - - - name: Install Rust - uses: actions-rs/toolchain@v1 - with: - default: true - profile: minimal - toolchain: ${{ env.INSTALL_RUST_VERSION }} - - - name: Use Rust Cache - uses: Swatinem/rust-cache@v2 - - - uses: jetli/wasm-pack-action@v0.4.0 - - - name: Create JavaScript package - run: wasm-pack build rust/sdk/bridge/wasm --out-dir ../../../../javascript/juicebox-sdk --out-name juicebox-sdk --target nodejs - - - name: Install TypeDoc - run: npm install --global typedoc - - - name: Generate Documentation - run: typedoc - working-directory: javascript/juicebox-sdk - - - name: Authenticate to Google Cloud - uses: google-github-actions/auth@v1 - with: - credentials_json: '${{ secrets.GCP_DOCUMENTATION_CREDENTIALS }}' - - - name: Set up Google Cloud SDK - uses: google-github-actions/setup-gcloud@v1 - - - name: Sync Docs to Google Cloud Storage - run: | - gsutil -m rsync -r \ - -d javascript/juicebox-sdk/docs \ - gs://e2d3e242bbd420b1f977a1f84684a45f1803a5b4/javascript diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index f3d070f..7ffd9d0 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -134,8 +134,6 @@ jobs: - name: Software Realm uses: ./.github/actions/software-realm - with: - token: ${{ secrets.ACCESS_TOKEN }} - name: Run software realm integration tests uses: actions-rs/cargo@v1 diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index eb81dd4..922f4c2 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -17,7 +17,6 @@ jobs: - uses: actions/checkout@v3 with: submodules: recursive - token: ${{ secrets.ACCESS_TOKEN }} - name: Build juicebox_sdk_jni run: | @@ -96,7 +95,6 @@ jobs: - uses: actions/checkout@v3 with: submodules: recursive - token: ${{ secrets.ACCESS_TOKEN }} - name: Build juicebox_sdk_ffi run: |