version: "3.2"

services:
  dev:
    container_name: node-template
    image: paritytech/ci-linux:production
    working_dir: /var/www/node-template
    ports:
      - "9944:9944"
    environment:
      - CARGO_HOME=/var/www/node-template/.cargo
      - WASM_BUILD_TOOLCHAIN=nightly-2020-10-05
    volumes:
      - .:/var/www/node-template
      - type: bind
        source: ./.local
        target: /root/.local
    command: bash -c "cargo build --release && ./target/release/node-template --dev --ws-external"
