-
Notifications
You must be signed in to change notification settings - Fork 22
38 lines (34 loc) · 1.61 KB
/
dry-run-deploy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: Dry run - Devhub
on:
pull_request:
jobs:
deploy-widgets:
runs-on: ubuntu-latest
name: Dry run - Devhub
# environment: devhub.near
defaults:
run:
working-directory: ./instances/devhub.near
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set replacements
id: set_replacements
run: |
echo "replacements=$(jq -r '[to_entries[] | .["find"] = "${" + .key + "}" | .["replace"] = .value | del(.key, .value), {"find": "${REPL_POSTHOG_API_KEY}", "replace": "'${{ secrets.POSTHOG_API_KEY }}'"}]' aliases.mainnet.json | tr -d "\n\r")" >> $GITHUB_OUTPUT
- name: Replace placeholders
uses: flcdrg/replace-multiple-action@v1
with:
files: "**/*.jsx"
find: "${{ steps.set_replacements.outputs.replacements }}"
prefix: "(^|.*)"
suffix: "($|.*)"
- name: Install dependencies
run: |
# npm ci
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/near/near-cli-rs/releases/latest/download/near-cli-rs-installer.sh | sh
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/bos-cli-rs/bos-cli-rs/releases/latest/download/bos-cli-installer.sh | sh
- name: Dry run deploy widgets
run: |
# npm run dry-run:devhub
bos components deploy devhub.near sign-as devhub.near network-config mainnet sign-with-plaintext-private-key --signer-public-key 'ed25519:2i3bnqZND3rhnYr9GNgtcLminRr5dGnwy9dAYavZFtvd' --signer-private-key 'AxLg2kyjYLD2TtWon4QgyZn7ECJy5HFQd3BE2AC4tNZDYXHZj54vCRvAHpWKGc1t991y4JQsPHtAEDgpjaLvwfP' send