fix: setup Rust+cc на раннере перед Anchor, PATH в GITHUB_PATH
This commit is contained in:
@@ -12,18 +12,25 @@ jobs:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup Rust toolchain + C compiler
|
||||
run: |
|
||||
apt-get update
|
||||
apt-get install -y --no-install-recommends build-essential pkg-config libssl-dev clang
|
||||
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | \
|
||||
sh -s -- -y --profile minimal --default-toolchain 1.89.0
|
||||
|
||||
- name: Setup Solana CLI
|
||||
run: |
|
||||
sh -c "$(curl -sSfL https://release.solana.com/v1.18.26/install)"
|
||||
echo "$HOME/.local/share/solana/install/active_release/bin" >> "$GITHUB_PATH"
|
||||
echo "$HOME/.cargo/bin" >> "$GITHUB_PATH"
|
||||
|
||||
- name: Setup Anchor CLI (anchor-next)
|
||||
run: |
|
||||
export RUSTUP_HOME=/root/.rustup CARGO_HOME=/root/.cargo
|
||||
. "$HOME/.cargo/env" 2>/dev/null || true
|
||||
command -v cargo || curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal --default-toolchain 1.89.0
|
||||
. "$HOME/.cargo/env"
|
||||
cargo install --force --git https://github.com/anchor-lang/anchor.git \
|
||||
--branch anchor-next anchor-cli --locked
|
||||
echo "$HOME/.cargo/bin" >> "$GITHUB_PATH"
|
||||
|
||||
- name: Airdrop devnet SOL (to keypair address)
|
||||
run: |
|
||||
@@ -42,7 +49,5 @@ jobs:
|
||||
|
||||
- name: Deploy to devnet
|
||||
working-directory: program
|
||||
run: |
|
||||
export PATH="$HOME/.local/share/solana/install/active_release/bin:$PATH"
|
||||
anchor deploy --provider.cluster devnet \
|
||||
run: anchor deploy --provider.cluster devnet \
|
||||
--provider.wallet ../deploy/dev_smart_updown-keypair.json
|
||||
Reference in New Issue
Block a user