- Download user credentials from Educate and configure in .aws/ folder via CLI (~/.aws/credentials for keys and ~/.aws/config for region)
- Create Key Pair (In code it's named "cloud")
- Create Custom AMI Image:
- Launch new EC2 instance (Linux2 AMI x86)
- SSH into machine ssh -i "cloud.pem" [email protected]
- Run sudo yum install python3.x86_64 (see sudo yum list | grep python3 for all py3 versions)
- Run pip3 install boto3 awscli --user
- in case pip is not installed, run curl -O https://bootstrap.pypa.io/get-pip.py and then python3 get-pip.py --user
- validate install (python3 --version; pip3 --version)
- exit VM
- scp nonce.py and .aws folder on machine (scp -r -i "cloud.pem" ./.aws [email protected]:~)
- In AWS web, click on instance -> Image -> Create New Image
- Use new custom AMI in script.py file when launching new instances
- Run script.py:
- gnuOptions = ["runtime=", "block=", "confidence=", "numberofmachines=", "difficulty=", "price="]
- e.g python3 script.py -n 4 -d 25
- Run stop.py in order to stop all instances in a clean fashion (if needed as an extension)
-
Notifications
You must be signed in to change notification settings - Fork 0
Grakkus/cloudcomputing
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
Cloud Computing CW
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published