Droplets, Tugboat, Default User & Password

Posted February 1, 2015 2.2k views

I just started messing around with tugboat. A couple quick questions:

  • It appears to only use the v1 API. Is there an alternative command-line client that uses the v2 API? I looked into poseidon, but it doesn’t appear to have a command-line client. Is tugboat the recommended tool?

  • In my tugboat config I specified an alternative ssh_user and ssh_port, however when I use ‘tugboat create test’ and use the global Ubuntu 14.04 x64 image, the droplet seems to still be created with the root account and the default port. I don’t see anything in the API about creating droplets with an alternative root user or port, so I’m guessing these settings don’t actually apply when creating the droplet.

  • There also doesn’t seem to be a way for tugboat to specify or retrieve the root password, so it looks like when working this way, I need to build it, then grab the password from my email before I can run any root commands on the box. Is this correct?

I haven’t used snapshots before, but it looks like for what I want, I need to create a droplet, configure some basic settings (setting up new admin user, adding ssh key, disabling root account, changing ssh port, etc), then take a snapshot. Then I can spin up new instances from that snapshot.

Am I correct on this? If so, then the original droplet isn’t really something I’d leave running - I’d build it, take a snapshot, turn it off and leave it there to clone from. Is there a charge for keeping this non-running droplet with a 'base snapshot’ laying around, unused?

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Submit an Answer
1 answer

Tugboat is by far the most feature-full command line client at the moment despite still using version 1 of the API. Though there are already v2 libraries in quite a few languages if you are just looking to script a few of you common uses cases. Regarding the ssh_user and ssh_port settings for Tugboat, those are only used with the tugboat ssh droplet-name command. It doesn’t have a way to set the initial password, though the tugboat create command does accept a --keys argument that will add a SSH key to a newly created droplet.

Even when a droplet is “off” you are still charged as the resource are reserved for you. Using a snapshot is a good way to do this. You might also look into using a cloud-config script for your initial droplet configuration.

by Justin Ellingwood
A cloud-config file is a special script that is used to define configuration details for your server as it is being brought online for the first time. These are often used for completing common tasks that a user would normally have to log into the server to accomplish. In this guide, we will run through how to do some initial configuration of an Ubuntu 14.04 server using a cloud-config file with our metadata service.