-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsolana-rust-builder.yaml
44 lines (44 loc) · 1.43 KB
/
solana-rust-builder.yaml
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
39
40
41
42
43
44
#cloud-config
package_update: true
package_upgrade: true
package_reboot_if_required: true
packages:
# The following packages should be installed if you want to build yourself. that takes 45 min on a Ryzen 5 5600X at 4.2 GHz. do not recommend.
- libssl-dev
- libudev-dev
- pkg-config
- zlib1g-dev
- llvm
- clang
- cmake
- make
- libprotobuf-dev
- protobuf-compiler
- sshfs # for multipass mount
system_info:
distro: ubuntu
default_user:
name: ubuntu
shell: /bin/bash
network:
version: 2
renderer: NetworkManager
write_files:
- content: |
export PATH=/home/ubuntu/.local/share/solana/install/manual_build/bin:$PATH
path: /home/ubuntu/.profile
owner: ubuntu:ubuntu
append: true
defer: true
runcmd:
# Rust is only need if you want to build yourself.
- 'echo INSTALL RUST'
- 'su ubuntu -c "curl --tlsv1.2 https://sh.rustup.rs -Sf | sh -s -- -y"'
- 'su ubuntu -c "echo source ~/.cargo/env >> ~/.profile"'
- 'echo UPDATE RUST'
- 'su ubuntu -c "source ~/.cargo/env && rustup update"'
- 'su ubuntu -c "source ~/.cargo/env && rustup component add rustfmt"'
- 'echo INSTALL SOLANA'
- 'su ubuntu -c "cd ~ && git clone /~https://github.com/solana-labs/solana.git"'
- 'su ubuntu -c "cd ~/solana && git checkout $(git describe --tags $(git rev-list --tags --max-count=1))"'
- 'su ubuntu -c "source ~/.cargo/env && cd ~/solana && ./scripts/cargo-install-all.sh ~/.local/share/solana/install/manual_build"'