Skip to content

vatsalaggarwal/cloud-instance-management

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cloud-instance-management

Start/stop one GCP instance easily via the command line. At start time, it updates the ssh config so the instance can be logged into easily.

Usage

To start an instance, run:

cim start

To stop an instance, run:

cim stop

To start a VSCode window connected to the instance, run:

cim code

Note: if the instance is stopped, running cim code will implicitly start the instance.

Setup

  1. Create a cloud_instance_management/constants.py with the following contents:

    PROJECT_ID = "" # Google Cloud Project ID
    INSTANCE_NAME = "" # Instance ID given to the relevant instance
    LOCAL_INSTANCE_NAME = "" # Host ID of the relevant instance in the ~/.ssh/config file

    Note: assumes that ~/.ssh/config has been setup for this instance before.

  2. Run poetry install

About

CLI to manage cloud instance workflows via one-liners.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages