A few rough usage notes, continuing from my first post a while back.
Delete all containers:
Run a container from an image and delete it when it exits: use –rm:
docker run -it --rm containerid
Pass an argument into a build:
- use ‘ARG argname’ to declare the argument in your Dockerfile
- pass value for argname with –build-arg argname=value
Test during build if an arg was passed:
RUN test -n "$argname"