-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'devx/add-MoveBook-to-docs' of https://github.com/iotale…
…dger/iota into devx/add-MoveBook-to-docs
- Loading branch information
Showing
383 changed files
with
4,912 additions
and
6,666 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,62 @@ | ||
name: Preview Deploy for Apps Backend | ||
|
||
env: | ||
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }} | ||
VERCEL_PROJECT_ID: ${{ secrets.APPS_BACKEND_VERCEL_PROJECT_ID }} | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- "apps/apps-backend/**" | ||
- ".github/workflows/apps-backend-preview.deploy.yml" | ||
|
||
jobs: | ||
deploy-preview: | ||
permissions: | ||
contents: read | ||
pull-requests: write | ||
runs-on: [self-hosted] | ||
steps: | ||
- uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # pin@v4 | ||
- uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2 # pin@v4 | ||
- name: Install Nodejs | ||
uses: actions/setup-node@0a44ba7841725637a19e28fa30b79a866c81b0a6 # pin@v4 | ||
with: | ||
node-version: "20" | ||
cache: "pnpm" | ||
- name: Install dependencies | ||
run: pnpm install --frozen-lockfile | ||
- name: Turbo Cache | ||
id: turbo-cache | ||
uses: actions/cache@3624ceb22c1c5a301c8db4169662070a689d9ea8 # pin@v4 | ||
with: | ||
path: node_modules/.cache/turbo | ||
key: turbo-${{ runner.os }}-${{ github.sha }} | ||
restore-keys: | | ||
turbo-${{ runner.os }}- | ||
- name: Install Vercel CLI | ||
run: pnpm add --global vercel@canary | ||
- name: Build the Apps Backend | ||
run: pnpm apps-backend build | ||
- name: Pull Vercel Environment | ||
run: vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }} | ||
- name: Build Project Artifacts | ||
run: vercel build --token=${{ secrets.VERCEL_TOKEN }} | ||
- name: Deploy Project Artifacts to Vercel | ||
run: vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }} > vercel_output.txt | ||
- name: Extract Deploy URL | ||
id: deploy_url | ||
run: echo "DEPLOY_URL=$(cat vercel_output.txt | awk 'END{print}')" >> $GITHUB_OUTPUT | ||
- name: Comment on pull request | ||
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # pin@v7 | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
script: | | ||
const DEPLOY_URL = '${{ steps.deploy_url.outputs.DEPLOY_URL }}' | ||
const COMMIT_SHA = '${{ github.event.pull_request.head.sha }}' | ||
github.rest.issues.createComment({ | ||
issue_number: context.issue.number, | ||
owner: context.repo.owner, | ||
repo: context.repo.repo, | ||
body: `This pull request has been deployed to Vercel.\n\n\nLatest commit: ${COMMIT_SHA}\n\n:white_check_mark: Preview: ${DEPLOY_URL}` | ||
}) |
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 |
---|---|---|
|
@@ -6,6 +6,7 @@ on: | |
workflow_dispatch: | ||
|
||
env: | ||
BINARY_LIST_FILE: "./binary-build-list.json" | ||
CARGO_TERM_COLOR: always | ||
# Disable incremental compilation. | ||
# | ||
|
@@ -30,11 +31,39 @@ env: | |
jobs: | ||
release: | ||
name: build release binaries | ||
runs-on: [self-hosted] | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ | ||
self-hosted, # ubuntu-x86_64 | ||
macos-latest, # macos-arm64 | ||
] | ||
steps: | ||
# TODO: Remove when iota-sim is public https://github.com/iotaledger/iota/issues/2149 | ||
- name: Set up SSH (MacOs only) | ||
if: ${{ matrix.os == 'macos-latest' }} | ||
uses: MrSquaare/ssh-setup-action@2d028b70b5e397cf8314c6eaea229a6c3e34977a # pin@v3 | ||
with: | ||
host: github.com | ||
private-key: ${{ secrets.SSH_PRIVATE_KEY_IOTA_CI }} | ||
private-key-name: github-ppk | ||
|
||
- name: Install postgres (MacOS arm64) | ||
if: ${{ matrix.os == 'macos-latest' }} | ||
shell: bash | ||
env: | ||
PQ_LIB_DIR: "$(brew --prefix libpq)/lib" | ||
LIBRARY_PATH: "/opt/homebrew/lib:$LIBRARY_PATH" | ||
PKG_CONFIG_PATH: "/opt/homebrew/lib/pkgconfig:$PKG_CONFIG_PATH" | ||
PATH: "/opt/homebrew/bin:$PATH" | ||
run: | | ||
brew install postgresql | ||
- uses: actions/checkout@eef61447b9ff4aafe5dcd4e0bbf5d482be7e7871 # pin@v4 | ||
|
||
- name: cargo build | ||
uses: actions-rs/cargo@ae10961054e4aa8b4aa7dffede299aaf087aa33b # [email protected] | ||
with: | ||
command: build | ||
args: --all-targets --all-features --release --profile=release | ||
args: --all-targets --all-features --release |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.