If I missed the answer to this in the documentation, I apologize. I find that Doctl can be tedious to use at times.
Can we alias apps by their name instead of their ID, so we can do
doctl apps create-deployment <app name>
Is there a more practical way to get the most recent deployment than
doctl apps list-deployments, then scroll to the top of that response (because it returns every deployment ever), then copy the id, and then run
doctl apps get-deployment <app id> <deployment id>?
Here’s what I’d like:
doctl apps get-deployment <app name> [latest | active | failed] [int for number of results]
doctl apps get-deployment MyApp failed 5 would return the 5 most recent failed deploys
doctl apps get-deployment MyApp would return the latest deployment in any state
doctl apps get-deployment MyApp active would return either a build in progress, or nothing
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!
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.
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.
Click below to sign up and get $100 of credit to try our products over 60 days!