--- a/Dockerfile-production +++ /dev/null @@ -1,47 +0,0 @@ -# ===== BUILD ====== - -FROM phusion/baseimage:0.10.2 as builder -LABEL maintainer="gz@usetech.com" - -ENV WASM_TOOLCHAIN=nightly-2020-05-01 - -ARG PROFILE=release - -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 - -# Get project and run it -#RUN git clone https://github.com/usetech-llc/nft_parachain /nft_parachain -RUN mkdir nft_parachain -WORKDIR /nft_parachain -COPY . . - -RUN curl https://sh.rustup.rs -sSf | sh -s -- -y && \ - export PATH="$PATH:$HOME/.cargo/bin" && \ - rustup toolchain uninstall $(rustup toolchain list) && \ - rustup default 1.44.0 && \ - rustup toolchain install $WASM_TOOLCHAIN && \ - rustup target add wasm32-unknown-unknown --toolchain $WASM_TOOLCHAIN && \ - rustup target list --installed && \ - rustup show && \ - cargo build "--$PROFILE" - # && \ - # cargo test - -RUN cd target/release && ls -la - -# ===== RUN ====== - -FROM phusion/baseimage:0.10.2 -ARG PROFILE=release - -COPY --from=builder /nft_parachain/target/$PROFILE/nft /usr/local/bin - -EXPOSE 9944 -VOLUME ["/chain-data"] - -# Copy and run start script -COPY ["./run.sh", "./run.sh"] -RUN chmod +x ./run.sh -CMD ["bash", "-c", "./run.sh"] --- /dev/null +++ b/Dockerfile-testnet @@ -0,0 +1,47 @@ +# ===== BUILD ====== + +FROM phusion/baseimage:0.10.2 as builder +LABEL maintainer="gz@usetech.com" + +ENV WASM_TOOLCHAIN=nightly-2020-05-01 + +ARG PROFILE=release + +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 + +# Get project and run it +#RUN git clone https://github.com/usetech-llc/nft_parachain /nft_parachain +RUN mkdir nft_parachain +WORKDIR /nft_parachain +COPY . . + +RUN curl https://sh.rustup.rs -sSf | sh -s -- -y && \ + export PATH="$PATH:$HOME/.cargo/bin" && \ + rustup toolchain uninstall $(rustup toolchain list) && \ + rustup default 1.44.0 && \ + rustup toolchain install $WASM_TOOLCHAIN && \ + rustup target add wasm32-unknown-unknown --toolchain $WASM_TOOLCHAIN && \ + rustup target list --installed && \ + rustup show && \ + cargo build "--$PROFILE" + # && \ + # cargo test + +RUN cd target/release && ls -la + +# ===== RUN ====== + +FROM phusion/baseimage:0.10.2 +ARG PROFILE=release + +COPY --from=builder /nft_parachain/target/$PROFILE/nft /usr/local/bin + +EXPOSE 9944 +VOLUME ["/chain-data"] + +# Copy and run start script +COPY ["./run.sh", "./run.sh"] +RUN chmod +x ./run.sh +CMD ["bash", "-c", "./run.sh"] --- a/docker-compose-production.yml +++ /dev/null @@ -1,35 +0,0 @@ -version: "3.5" - -services: - node_einstein: - image: nft-parachain - ports: - - 9944:9944 - build: - context: ./ - dockerfile: Dockerfile-production - volumes: - - ./chain-data-einstein:/chain-data - networks: - - substrate_network - environment: - - NODE=einstein - - node_newton: - image: nft-parachain - ports: - - 9945:9944 - build: - context: ./ - dockerfile: Dockerfile-production - volumes: - - ./chain-data-newton:/chain-data - networks: - - substrate_network - environment: - - NODE=newton - -networks: - substrate_network: - driver: bridge - name: substrate_network --- /dev/null +++ b/docker-compose-testnet.yml @@ -0,0 +1,35 @@ +version: "3.5" + +services: + node_einstein: + image: nft-parachain + ports: + - 9944:9944 + build: + context: ./ + dockerfile: Dockerfile-production + volumes: + - ./chain-data-einstein:/chain-data + networks: + - substrate_network + environment: + - NODE=einstein + + node_newton: + image: nft-parachain + ports: + - 9945:9944 + build: + context: ./ + dockerfile: Dockerfile-production + volumes: + - ./chain-data-newton:/chain-data + networks: + - substrate_network + environment: + - NODE=newton + +networks: + substrate_network: + driver: bridge + name: substrate_network --- a/smart_contract/ink-types-node-runtime/Cargo.toml +++ b/smart_contract/ink-types-node-runtime/Cargo.toml @@ -7,8 +7,7 @@ license = "GPL-3.0" readme = "README.md" -repository = "https://github.com/paritytech/ink" -documentation = "https://github.com/paritytech/ink/wiki" +repository = "https://github.com/usetech-llc/ink" homepage = "https://www.parity.io/" description = "[ink!] Rust based eDSL for writing smart contracts for Substrate" @@ -18,12 +17,12 @@ include = ["/Cargo.toml", "src/**/*.rs", "/README.md", "/LICENSE"] [dependencies] -ink_core = { version = "2", git = "https://github.com/paritytech/ink", tag = "latest-v2", package = "ink_core", default-features = false } -frame-system = { git = "https://github.com/paritytech/substrate/", tag = "v2.0.0-rc3", package = "frame-system", default-features = false } -pallet-indices = { git = "https://github.com/paritytech/substrate/", tag = "v2.0.0-rc3", package = "pallet-indices", default-features = false } -sp-core = { git = "https://github.com/paritytech/substrate/", tag = "v2.0.0-rc3", package = "sp-core", default-features = false } -sp-io = { git = "https://github.com/paritytech/substrate/", tag = "v2.0.0-rc3", package = "sp-io", default-features = false, features = ["disable_panic_handler", "disable_oom", "disable_allocator"] } -sp-runtime = { git = "https://github.com/paritytech/substrate/", tag = "v2.0.0-rc3", package = "sp-runtime", default-features = false } +ink_core = { version = "2", git = "https://github.com/usetech-llc/ink", tag = "latest-v2", package = "ink_core", default-features = false } +frame-system = { git = "https://github.com/usetech-llc/substrate/", branch = "nft_rc3", package = "frame-system", default-features = false } +pallet-indices = { git = "https://github.com/usetech-llc/substrate/", branch = "nft_rc3", package = "pallet-indices", default-features = false } +sp-core = { git = "https://github.com/usetech-llc/substrate/", branch = "nft_rc3", package = "sp-core", default-features = false } +sp-io = { git = "https://github.com/usetech-llc/substrate/", branch = "nft_rc3", package = "sp-io", default-features = false, features = ["disable_panic_handler", "disable_oom", "disable_allocator"] } +sp-runtime = { git = "https://github.com/usetech-llc/substrate/", branch = "nft_rc3", package = "sp-runtime", default-features = false } scale = { package = "parity-scale-codec", version = "1.3", default-features = false, features = ["derive"] } [dependencies.type-metadata] --- a/smart_contract/ink-types-node-runtime/examples/calls/Cargo.toml +++ b/smart_contract/ink-types-node-runtime/examples/calls/Cargo.toml @@ -5,15 +5,14 @@ edition = "2018" [dependencies] -ink_abi = { version = "2", git = "https://github.com/paritytech/ink", tag = "latest-v2", package = "ink_abi", default-features = false, features = ["derive"], optional = true } -ink_primitives = { version = "2", git = "https://github.com/paritytech/ink", tag = "latest-v2", package = "ink_primitives", default-features = false } -ink_core = { version = "2", git = "https://github.com/paritytech/ink", tag = "latest-v2", package = "ink_core", default-features = false } -ink_lang = { version = "2", git = "https://github.com/paritytech/ink", tag = "latest-v2", package = "ink_lang", default-features = false } -ink_prelude = { version = "2", git = "https://github.com/paritytech/ink", tag = "latest-v2", package = "ink_prelude", default-features = false } +ink_abi = { version = "2", git = "https://github.com/usetech-llc/ink", tag = "latest-v2", package = "ink_abi", default-features = false, features = ["derive"], optional = true } +ink_primitives = { version = "2", git = "https://github.com/usetech-llc/ink", tag = "latest-v2", package = "ink_primitives", default-features = false } +ink_core = { version = "2", git = "https://github.com/usetech-llc/ink", tag = "latest-v2", package = "ink_core", default-features = false } +ink_lang = { version = "2", git = "https://github.com/usetech-llc/ink", tag = "latest-v2", package = "ink_lang", default-features = false } +ink_prelude = { version = "2", git = "https://github.com/usetech-llc/ink", tag = "latest-v2", package = "ink_prelude", default-features = false } -sp-runtime = { git = "https://github.com/paritytech/substrate/", tag = "v2.0.0-rc3", package = "sp-runtime", default-features = false } scale = { package = "parity-scale-codec", version = "1.3", default-features = false, features = ["derive"] } -sp-keyring = { git = "https://github.com/paritytech/substrate/", tag = "v2.0.0-rc3", package = "sp-keyring", optional = true } +sp-keyring = { git = "https://github.com/usetech-llc/substrate/", branch = "nft_rc3", package = "sp-keyring", optional = true } ink_types_node_runtime = { path = "../../", default-features = false } [dependencies.type-metadata]