Use the Cli
CLI commands
Run tugboat help
to see a list of commands you can execute. You can view the help of any command by passing the -h
or --help
option. Most of the commands support returning JSON by passing the -j
or --json
option.
A few common commands include:
View info
- List Tugboat Repositories
- List Tugboat Previews
- View the Services in a Preview
- View Preview logs
- View Service logs
Administer Previews
Shell into Services
View info
List Tugboat repositories
tugboat ls repos
List Tugboat Previews
tugboat ls previews
View the Services of a Preview
To view the services of a preview with an ID of 5b04c7d14c3dad00016a2e80
:
tugboat ls services preview=5b04c7d14c3dad00016a2e80
View Preview logs
To view the logs for a Preview with an ID of 5b04c7d14c3dad00016a2e80
:
tugboat log 5b04c7d14c3dad00016a2e80
View Services logs
To view the logs for a Service with an ID of 5d092b16bd44cb22a498be90
that’s running in a Preview:
tugboat log 5d092b16bd44cb22a498be90
Administer Previews
Build a new Preview
To build a new Preview from the main
branch of a Tugboat Repository with an ID of 5b02ed093558930001c04cfa
:
tugboat create preview main repo=5b02ed093558930001c04cfa
Delete a Preview
To force the deletion of a Preview with an ID of 5b04c7d14c3dad00016a2e80
:
tugboat delete 5b02ed093558930001c04cfa -f
Start a shell into Services on a Preview
Start a shell on the default Service of a Preview
To start a shell on the default Service of a
Preview with an ID of 5b04c7d14c3dad00016a2e80
:
tugboat shell 5b04c7d14c3dad00016a2e80
Start a shell on a Service
To start a shell on Service that isn’t the default:
- Start by viewing the Services of the Preview.
- Find the Service where you want to start a shell.
- Start the shell using the ID of the specific Service.