version: '3.0'

services:
  lib: &default
    build:
      context: .
      dockerfile: Dockerfile
    volumes:
      - .:/usr/src/app
    env_file: .secrets


version: '3.0'

services:
  lib: &default
    build:
      context: .
      dockerfile: Dockerfile
    volumes:
      - .:/usr/src/app
      - registry:/root/.cargo/registry
    env_file: .secrets

volumes:
  registry:
    driver: local

Add registry volume to compose
Add registry volume to compose

Because the `Cargo.toml` changes frequently in development and
invalidates the image cache, this adds a volume to persist the
installed crates between builds.
