Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .docker/alphaville.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ ENV DEBIAN_FRONTEND=noninteractive

RUN apt-get update && \
apt-get dist-upgrade -y -o Dpkg::Options::="--force-confold" && \
apt-get install -y cmake pkg-config libssl-dev git clang
apt-get install -y cmake pkg-config libssl-dev git clang protobuf-compiler

RUN curl https://sh.rustup.rs -sSf | sh -s -- -y && \
export PATH="$PATH:$HOME/.cargo/bin" && \
rustup toolchain install nightly-2022-06-24 && \
rustup target add wasm32-unknown-unknown --toolchain nightly-2022-06-24 && \
rustup default nightly-2022-06-24 &&\
rustup toolchain install nightly-2022-11-15 && \
rustup target add wasm32-unknown-unknown --toolchain nightly-2022-11-15 && \
rustup default nightly-2022-11-15 &&\
rustup show

WORKDIR /alphaville
Expand Down
8 changes: 4 additions & 4 deletions .docker/subzero-dev.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,16 @@ ENV DEBIAN_FRONTEND=noninteractive

RUN apt-get update && \
apt-get dist-upgrade -y -o Dpkg::Options::="--force-confold" && \
apt-get install -y cmake pkg-config libssl-dev git clang
apt-get install -y cmake pkg-config libssl-dev git clang protobuf-compiler

WORKDIR /subzero
COPY . /subzero

RUN curl https://sh.rustup.rs -sSf | sh -s -- -y && \
export PATH="$PATH:$HOME/.cargo/bin" && \
rustup toolchain install nightly-2022-06-24 && \
rustup target add wasm32-unknown-unknown --toolchain nightly-2022-06-24 && \
rustup default nightly-2022-06-24 &&\
rustup toolchain install nightly-2022-11-15 && \
rustup target add wasm32-unknown-unknown --toolchain nightly-2022-11-15 && \
rustup default nightly-2022-11-15 &&\
rustup show

# ===== STAGE 2 ======
Expand Down
10 changes: 5 additions & 5 deletions .docker/subzero.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,16 @@ ENV DEBIAN_FRONTEND=noninteractive

RUN apt-get update && \
apt-get dist-upgrade -y -o Dpkg::Options::="--force-confold" && \
apt-get install -y cmake pkg-config libssl-dev git clang
apt-get install -y cmake pkg-config libssl-dev git clang protobuf-compiler

WORKDIR /subzero
COPY . /subzero

RUN curl https://sh.rustup.rs -sSf | sh -s -- -y && \
export PATH="$PATH:$HOME/.cargo/bin" && \
rustup toolchain install nightly-2022-06-24 && \
rustup target add wasm32-unknown-unknown --toolchain nightly-2022-06-24 && \
rustup default nightly-2022-06-24 &&\
rustup toolchain install nightly-2022-11-15 && \
rustup target add wasm32-unknown-unknown --toolchain nightly-2022-11-15 && \
rustup default nightly-2022-11-15 &&\
rustup show

# ===== STAGE 2 ======
Expand All @@ -43,7 +43,7 @@ RUN mv /usr/share/ca* /tmp && \
ln -s /subzero/.local/share/subzero /data

COPY --from=builder /subzero/target/$PROFILE/subzero /usr/local/bin
COPY --from=builder /subzero/.docker/chainspec /chainspec
COPY --from=builder /subzero/bin/res /chainspec

# checks
RUN ldd /usr/local/bin/subzero && \
Expand Down
121 changes: 121 additions & 0 deletions bin/res/subzero-kusama-raw.json

Large diffs are not rendered by default.

5 changes: 5 additions & 0 deletions bin/subzero/node/src/chain_spec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,11 @@ pub fn local_testnet_config() -> ChainSpec {
)
}

pub fn subzero_config() -> Result<ChainSpec, String> {
ChainSpec::from_json_bytes(&include_bytes!("../../../res/subzero-kusama-raw.json")[..])
}


fn testnet_genesis(
invulnerables: Vec<(AccountId, AuraId)>,
endowed_accounts: Vec<AccountId>,
Expand Down
5 changes: 3 additions & 2 deletions bin/subzero/node/src/command.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ fn load_spec(id: &str) -> std::result::Result<Box<dyn ChainSpec>, String> {
Ok(match id {
"dev" => Box::new(chain_spec::development_config()),
"template-rococo" => Box::new(chain_spec::local_testnet_config()),
"" | "local" => Box::new(chain_spec::local_testnet_config()),
"local" => Box::new(chain_spec::local_testnet_config()),
"" | "subzero" => Box::new(chain_spec::subzero_config()?),
path => Box::new(chain_spec::ChainSpec::from_json_file(std::path::PathBuf::from(path))?),
})
}
Expand Down Expand Up @@ -448,4 +449,4 @@ impl CliConfiguration<Self> for RelayChainCli {
fn node_name(&self) -> Result<String> {
self.base.base.node_name()
}
}
}