AWS Provisioning Tool
This project this target to automate the AWS provisioning process for ec2 and route53
Prerequisites
This code is tested with python 2.7, addtional modules (IPy, prettytable, boto3, paramiko) are required which will be installed automaticlly.
Need to configure following at home directory.
For Linux and Mac.
~/.aws/config
~/.aws/credentials
For Windows.
"%UserProfile%"/.aws/config
"%UserProfile%"/.aws/credentials
config file details
[default]
region=ap-southeast-1
output=json
credentials file details
[account1]
aws_access_key_id=AKIAIOSFODNN7EXAMPLE
aws_secret_access_key=wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY
[account2]
aws_access_key_id=AKIAIOSFODNN7TEST
aws_secret_access_key=wJalrXUtnFEMI/K7MDENG/bPxRfiCYTESTKEY
Installing
-
I have tested working on Mac and Linux
-
sudo pip install aws_toolkit==1.0.2
How to use it
from awspackage import aws
myaws = aws.AWS(DOMAIN="abc.com #Hosted at Route53",
PEM_LOCATION="/path/to/pem",
Module_Path="/path/to/ansible/playbook",
USERNAME="EC2_Username")
myaws.main()
Parameters to take note
- "Domain" refer to the domain name that registered to the AWS under the same account, eg. cjaiwenwen.com (Put dummy data if you dont have route53 service)
- "PEM_LOCATION" refer to the local pem key path eg, /Users/cjaiwenwen/Desktop/chenjun.pem
- "Module_Path" is exact location where the ansible yaml file is located, and the server is under [servers]
- "USERNAME" is the username to access the remote server
What can the library could achieve
- Could select the account to provision based on the section by select the account1 and account2
- Create instance on any region if the VPC has been already created
- Control the number of the VMs could provisioned
- Choose the AMI image
- Choose the subnets
- Choose the security group
- Modify the security group rules if need to be
- Choose the size of the VM
- Assign CNAME for the provisioned VM
- Continue ping the provisioned host
- SSH to the host to confirm accessible (need to add ssh incoming rule)
- Deploy
Authors
- Chen Jun - Initial work - CJAIWENWEN
Connect with me on Linkedin
License
This project is licensed under the MIT License - see the LICENSE.md file for details
Metadata
Release files for aws-toolkit 1.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| aws_toolkit-1.0.2.tar.gz | 9.7 kB | Without provenance | Details |
Release files / aws_toolkit-1.0.2.tar.gz
| Download URL | aws_toolkit-1.0.2.tar.gz |
|---|---|
| Size | 9.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
d601795795c5ea978c90e3afac29e8c66bafc2f37a73032d93b00b013066d907
|
|
BLAKE2b-256 checksum How to use checksums |
80efeede9135b6af596cf9b92287200afbbb3594b606fc60db853d05a13807e4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.11.0 pkginfo/1.4.2 requests/2.18.4 setuptools/38.5.1 requests-toolbelt/0.8.0 tqdm/4.23.4 CPython/2.7.13
|
Security for aws-toolkit 1.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.