All Projects → joeyism → py-spotme

joeyism / py-spotme

Licence: other
A CLI tool that creates AWS spot instances on the fly

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to py-spotme

Autospotting
Saves up to 90% of AWS EC2 costs by automating the use of spot instances on existing AutoScaling groups. Installs in minutes using CloudFormation or Terraform. Convenient to deploy at scale using StackSets. Uses tagging to avoid launch configuration changes. Automated spot termination handling. Reliable fallback to on-demand instances.
Stars: ✭ 2,014 (+12487.5%)
Mutual labels:  ec2, spot-instances, ec2-instance, ec2-spot
AutoSpotting
Saves up to 90% of AWS EC2 costs by automating the use of spot instances on existing AutoScaling groups. Installs in minutes using CloudFormation or Terraform. Convenient to deploy at scale using StackSets. Uses tagging to avoid launch configuration changes. Automated spot termination handling. Reliable fallback to on-demand instances.
Stars: ✭ 2,058 (+12762.5%)
Mutual labels:  ec2, spot-instances, ec2-instance, ec2-spot
mining-camp
Easy automated configuration and deployment of Minecraft servers on AWS spot instances, featuring automatic backups and restoration using S3.
Stars: ✭ 43 (+168.75%)
Mutual labels:  ec2, spot-instances, ec2-spot
spotinfo
CLI for exploring AWS EC2 Spot inventory. Inspect AWS Spot instance types, saving, price, and interruption frequency.
Stars: ✭ 76 (+375%)
Mutual labels:  spot-instances, ec2-spot, aws-spot-cli
hammertime
AWS EC2, ASG, RDS Power cycling
Stars: ✭ 12 (-25%)
Mutual labels:  ec2, ec2-instance
stork
Retrieve tokens from Vault for your EC2 instances.
Stars: ✭ 12 (-25%)
Mutual labels:  ec2, ec2-instance
spot price machine learning
Machine Learning for Spot Prices
Stars: ✭ 25 (+56.25%)
Mutual labels:  spot-instances, spot
infinity
AWS Spot instances for ML
Stars: ✭ 38 (+137.5%)
Mutual labels:  ec2, spot-instances
aws-solutions-architect-associate-certificate
Note to pass the AWS Solutions Architect Associate Exam
Stars: ✭ 58 (+262.5%)
Mutual labels:  ec2
git-admin
A package to help manage git repositories through the commandline
Stars: ✭ 27 (+68.75%)
Mutual labels:  commandline
cloud-init-example
Example of setting user-data for AWS EC2 with multipart data, tests the order in which various user data formats are run
Stars: ✭ 39 (+143.75%)
Mutual labels:  ec2
simplecli
The simplest way to parse cli arguments in golang
Stars: ✭ 15 (-6.25%)
Mutual labels:  commandline
nice
Highly customizable and idiomatic Go CLI app framework 👌
Stars: ✭ 198 (+1137.5%)
Mutual labels:  commandline
Utility.CommandLine.Arguments
A C# .NET class library containing tools for parsing the command line arguments of console applications.
Stars: ✭ 105 (+556.25%)
Mutual labels:  commandline
ecs-drain-lambda
Automation of Draining ECS instances with Lambda, based on Autoscaling Group Lifecycle hooks or Spot Instance Interruption Notices
Stars: ✭ 56 (+250%)
Mutual labels:  ec2-spot
cotp
Trustworthy, encrypted, command-line TOTP/HOTP authenticator app with import functionality.
Stars: ✭ 45 (+181.25%)
Mutual labels:  commandline
rabbitmq-peer-discovery-aws
AWS-based peer discovery backend for RabbitMQ 3.7.0+
Stars: ✭ 23 (+43.75%)
Mutual labels:  ec2
pingdom-probes-aws-whitelist
A script for syncing Pingdom probe IPv4 addresses to AWS security groups.
Stars: ✭ 27 (+68.75%)
Mutual labels:  ec2
Data-Scientist-In-Python
This repository contains notes and projects of Data scientist track from dataquest course work.
Stars: ✭ 23 (+43.75%)
Mutual labels:  commandline
md server
Standalone EC2 metadata server to simplify the user of vendor cloud images with standalone kvm/libvirt
Stars: ✭ 36 (+125%)
Mutual labels:  ec2

SpotMe

A command line tool that allows you to spin up AWS EC2 Spot Instances instantly

Background

I do a lot of computation, but my computer is pretty crappy, so often I have to spin up ec2 spot instances to do some computation. Spot Instances are a good resource to use AWS EC2 instances for fairly cheap, and I am very frugal. I created this tool because I didn't want to have to develop something on my commandline, go to my browser and create a spot instance, then go back to my commandline to rsync/scp everything up. This tool allows me to stay in my commandline the whole way.

If you want to know how much spot prices are for specific regions historically, you should try spotcheck

Installation

To install, simply run

pip3 install --user spotme

Setup

Since spotcheck uses boto3, you'll have to setup the same way. You can view the docs here

A sample config file that is to be placed in ~/.aws/config is also in this repository.

Usage

To use, run

spotme

and a series of questions will be prompted. The questions will be of the form

Instance Type [t2.micro]:
Spot Price: 0.006    
Instance Count [1]:
Availability Zone [ca-central-1a]:                                          
Launch Image Id [ami-d29e25b6]:  
Security Group, pick from:                                           
        sg-xxxxxxxx(Some Security Group)
        sg-yyyyyyyy(default)                                              
Default is [sg-xxxxxxxx]:                              
Key-Pair Name, pick from:        
        the-one-keypair
Default is [the-one-keypair]:

The result is of the form

Launching spot states sir-123abcde

+---------------------+---------------+---------------+
| Instance Id         | Public IP     | Private IP    |
+---------------------+---------------+---------------+
| i-05f10faefc833c643 | x.x.x.x       | x.x.x.x       |
+---------------------+---------------+---------------+

Repeatable Usage

If you don't want to enter the CLI prompt every time, you can run the CLI with the options

spotme --InstanceType=t2.micro --SpotPrice=0.006 --InstanceCount=1 --AvailabilityZone=ca-central-1a --LaunchImageId=ami-d29e25b6 --SecurityGroup=sg-123abcd --KeyName=yourkeypair

Version

  • 1.2.0

    • Added Key-pair name
  • 1.1.0

    • Added customization security group
  • 1.0.x

    • Fix Bugs
  • 1.0.0

    • First publish
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].