spin at the project level is a great way to deploy
spin without much configuration from the user's end. View
spin on NPM →
We can use Docker to run install
spin on your project. Run this command from the parent folder of your project.
Install `spin` with Yarn + Docker
docker run --rm -v $(pwd):/usr/app/src -w /usr/app/src/ node yarn add @serversideup/spin --dev
Install `spin` with NPM + Docker
docker run --rm -v $(pwd):/usr/app/src -w /usr/app/src/ node npm install @serversideup/spin --dev
You should now be able to access
spin by running the command below.
Run `spin` from your project
Rather than typing
./node_modules/.bin/spin every time, you can add a "smart alias", which will check to see if it exists in your
node_modules, if not, it loads it from the
You can add the following below to your
~/.bash_profile or your
Add to your shell profile (recommended)
alias spin='[ -f node_modules/.bin/spin ] && bash node_modules/.bin/spin || bash vendor/bin/spin'
You'll now be able to access
spin from your project root directory.
Once Spin is installed, you can follow the initialization wizard for your project by running
Initialize Spin with your project