Is it possible to install doctl on a droplet?

Hi, I’m quite new to back-end development, coming straight from front-end. I was wondering if it’s at all possible to install doctl on a droplet to automate the creation of more droplets/apps.

My idea was to offer a dashboard to clients where they can 1 click create apps. The system would then run doctl app create commands with a dynamically generated yaml file to deploy a site to a droplet/app. Of course I’d have the logic to assign more than 1 app per droplet as they are fairly lightweight mostly-static gatsby apps.

Would this be the ideal way of doing things or am I missing something crucial? If so, should I be deploying this idea through the new App platform, spaces, or droplets?


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

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.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

@0000 👋

This sounds like a fun idea! It’s definitely possible to install doctl on a Droplet, or even directly in an App Platform container via the Dockerfile build strategy. In both cases, you’d probably want to follow instructions for installing it on Linux systems.

An alternative to using doctl, would be to interact with the DigitalOcean API directly or using a client package like godo. The doctl command-line tool does exactly this!

You could deploy the static Gatsby apps onto the App Platform as static sites, one per app. The controller code that is responsible for orchestrating this can also live in a dynamic service component on an App Platform app. You could run this directly in a Droplet, but the App Platform abstracts away much of the plumbing and best practices that you’d need to do yourself with a Droplet.

Happy coding!