Simple Digital Ocean CLI by python.

Overview

digital-ocean-manager

Usage

python3 -m pip install -r requirements.txt
python3 do-cli.py -h
usage: do-cli.py [-h] [-c] [-q] [-k] [-f FILE] [-d] [-t TOKEN] [-n NAME] [-r REGION] [-i IMAGE] [-s SIZE_SLUG] [-b]

Manage your Digital Ocean droplets by simple CLI.

optional arguments:
  -h, --help            show this help message and exit
  -c, --create          create a droplet.
  -q, --quiet           run without inquiry.
  -k, --no_upload_keys  do not upload all your ssh keys.
  -f FILE, --file FILE  load args from json file.
  -d, --destroy         destroy a droplet. (destroy all droplets if not name provided.)
  -t TOKEN, --token TOKEN
                        use token. (both $DIGITALOCEAN_ACCESS_TOKEN and secret.DIGITALOCEAN_ACCESS_TOKEN are ok.)
  -n NAME, --name NAME  droplet name.
  -r REGION, --region REGION
                        droplet region.
  -i IMAGE, --image IMAGE
                        droplet image.
  -s SIZE_SLUG, --size_slug SIZE_SLUG
                        droplet size.
  -b, --backups         enable droplet backups.

Example

# Create a droplet from do-cli.json, wait key, and then destroy it.
python3 do-cli.py -f do-cli.json -c -d

Loaded args from do-cli.json: {'name': 'temp-droplet', 'region': 'sgp1', 'image': 'ubuntu-20-04-x64', 'size_slug': 's-1vcpu-1gb', 'backups': False}
Warning: will create the droplet and wait until key down.
args: {'backups': False, 'name': 'temp-droplet', 'region': 'sgp1', 'image': 'ubuntu-20-04-x64', 'size_slug': 's-1vcpu-1gb'}
Creating droplet: temp-droplet
will upload your ssh keys.
create droplet status: in-progress
create droplet status: in-progress
create droplet status: in-progress
create droplet status: in-progress
create droplet status: in-progress
create droplet status: in-progress
create droplet status: in-progress
create droplet status: in-progress
create droplet status: completed
Continue to destory this droplet (temp-droplet)? [Y/n]y
Destroying droplet: temp-droplet...
destroy droplet status: in-progress
destroy droplet status: completed

Args

DIGITALOCEAN_ACCESS_TOKEN: You can generate it from here. Set it as $DIGITALOCEAN_ACCESS_TOKEN or create python file named as secrets.py is ok.

do-cli.json:

{
  "name": "temp-droplet",
  "region": "sgp1",
  "image": "ubuntu-20-04-x64",
  "size_slug": "s-1vcpu-1gb",
  "backups": false
}
Owner
Chiro
HITszer, CS Sophomore.
Chiro
pwy - A simple weather tool.

A simple weather tool. I made this as a way for me to learn Python, API, and PyPi packaging. Name changed from wwy to pwy.

Clint 105 Dec 31, 2022
Chat with Rem in Terminal!

Chat with Rem in Terminal!

bariscodefx 1 Dec 19, 2021
open a remote repo locally quickly

A command line tool to peek a remote repo hosted on github or gitlab locally and view it in your favorite editor. The tool handles cleanup of the repo once you exit your editor.

Rahul Nair 44 Dec 16, 2022
Generate folder trees directly from the terminal.

Dir Tree Artist 🎨 🌲 Intro Easily view folder structure, with parameters to sieve out what you want. Choose to exclude files from being viewed (.git,

Glenda T 0 May 17, 2022
📦 A command line utility to put text in a box.

boxie A command line utility to put text in a box. Installation pip install boxie If you are on Linux you may need to use sudo to access this globally

Eliaz Bobadilla 10 Jun 30, 2022
A small system that allow you to manage hosts stored in your .ssh/config file

A small system that allow you to manage hosts stored in your .ssh/config using simple commands.

Simone Ostini 1 Jan 24, 2022
f90nml - A Fortran namelist parser, generator, and editor

f90nml - A Fortran namelist parser, generator, and editor A Python module and command line tool for parsing Fortran namelist files Documentation The c

Marshall Ward 110 Dec 14, 2022
Analysis of a daily word game "Wordle"

Wordle Analysis of a daily word game "Wordle" https://www.powerlanguage.co.uk/wordle/ Description Worlde is a daily word game in which a player attemp

Bartek 1 Feb 07, 2022
googler is a power tool to Google (web, news, videos and site search) from the command-line.

googler is a power tool to Google (web, news, videos and site search) from the command-line.

Terminator X 5.9k Jan 04, 2023
CLI utility to search and download torrents from major torrent sites

CLI Torrent Downloader About CLI Torrent Downloader provides convenient and quick way to search torrent magnet links (and to run associated torrent cl

x0r0x 86 Dec 19, 2022
lfb (light file browser) is a terminal file browser

lfb (light file browser) is a terminal file browser. The whole program is a mess as of now. In the feature I will remove the need for external dependencies, tidy up the code, make an actual readme, a

2 Apr 09, 2022
A simple reverse shell in python

RevShell A simple reverse shell in python Getting started First, start the server python server.py Finally, start the client (victim) python client.py

Lojacopsen 4 Apr 06, 2022
GDBIGtools: A command line tools for GDBIG varaints browser

GDBIGtools: A command line tools for GDBIG varaints browser Introduction Born in Guangzhou Cohort Study Genome Research Database is based on thousands

广州市出生队列基因组学研究(The genomics study of BIGCS) 7 Sep 14, 2022
Ralph is a command-line tool to fetch, extract, convert and push your tracking logs from various storage backends to your LRS or any other compatible storage or database backend.

Ralph is a command-line tool to fetch, extract, convert and push your tracking logs (aka learning events) from various storage backends to your

France Université Numérique 18 Jan 05, 2023
🦎 A NeoVim plugin for highlighting visual selections like in a normal document editor!

🦎 HighStr.nvim A NeoVim plugin for highlighting visual selections like in a normal document editor! Demo TL;DR HighStr.nvim is a NeoVim plugin writte

Pocco81 222 Jan 03, 2023
Calculator for CLI. Made with Python

Calculator for CLI. Made with Python

Brandon Arreguin 2 Jan 07, 2022
Stephen's Obsessive Note-Storage Engine.

Latest Release · PyPi Package · Issues · Changelog · License # Get Sonse and tell it where your notes are... $ pip install sonse $ export SONSE="$HOME

Stephen Malone 23 Jun 10, 2022
The WalletsNet CLI helps you connect to WalletsNet

WalletsNet CLI The WalletsNet CLI helps you connect to WalletsNet. With the CLI, you can: Trigger webhook events or resend events for easy testing Tai

WalletsClub 8 Dec 22, 2021
Unconventional ways to save an Image

Unexpected Image Saves Unconventional ways to save an image 😄 Have you ever been bored by the same old .png, .jpg, .jpeg, .gif and all other image ex

Eric Mendes 15 Nov 06, 2022
🗃️ Fileio-cli wrapper for fileioapi.py with fire.py, inspiration DOS

🗃️ File.io File.io simply upload a file, share the link, and after it is downloaded, the file is completely deleted. An API wrapper for the file.io w

nkot56297 2 May 12, 2022