spin up [OPTIONS]
build: directives, you might want to get in the habit of using spin up --build to ensure you're always running the latest version of your containers.spin up --build
You can add options at the end of the command (like the --build shown above. The above command will bring up your containers, but then also force a new build (if you have builds configured in your "docker-compose.dev.yml" file).
The spin up command defaults to running:
COMPOSE_FILE=docker-compose.yml:docker-compose.dev.yml docker compose up
--skip-pull: Do not automatically pull docker images.--force-pull: Pull Docker Compose images, regardless of cache settings.This command is a shortcut for docker compose up and can accept additional options that you pass to it. It also does a number of other special things.
docker-compose.yml and by default a docker-compose.dev.yml in your project before running$SPIN_ENVLet's say you have a few different files in your repository:
.
├── docker-compose.ci.yml
├── docker-compose.production.yml
├── docker-compose.staging.yml
├── docker-compose.testing.yml
└── docker-compose.yml
By default, Spin uses docker-compose.yml and docker-compose.dev.yml.
If you want to change that, you just need to set $SPIN_ENV:
SPIN_ENV=testing spin up
This will essentially run:
COMPOSE_FILE=docker-compose.yml:docker-compose.testing.yml docker compose up