Generalised Docker container for AWS & other tasks.
1.5K
Generalised Docker container for AWS & other tasks. Has support for the following:
vi at some point.Copy the run.sh.tpl file to something else, say, run.sh and add in your AWS details:
#!/bin/bash
docker rm -f aws-gen
docker run \
--name aws-gen \
-v ~/myproject:/project \
-e CONSUL_KEY= \
-e AWS_ACCESS_KEY_ID= \
-e AWS_SECRET_ACCESS_KEY= \
-e AWS_DEFAULT_REGION=eu-west-1 \
-e EC2_URL=https://ec2.eu-west-1.amazonaws.com \
-ti \
chrisramsay/aws-gen \
/bin/bash
To run the container:
$ ./run.sh
Edit the run.sh file to add as many extra mount commands as you need, as well as adding any credentials you might want to access AWS and Consul.
The Dockerfile ADDs a bashrc file to give an extra few niceties on the command line:
AWS CLI comes with command completion set up so that you can tab away all those spare keyboard strokes:
aws-gen:/srv$ aws s<TAB>
s3 sdb ses snowball sqs storagegateway support
s3api servicecatalog sms sns ssm sts swf
There is a build.sh file packaged here. This is to help with further development of the container. One of a number of possible options must be passed at run time.
Runs the standard docker build command with a few build arguments; tags as both verson and latest picking up build version from the VERSION file.
Does not execute docker build. Instead modifies the Dockerfile replacing in-place values from the Dockerfile.tmpl with label values. This should be done prior to a tagged release.
Used in order to reinstate the normal Dockerfile for continuing development. Utility function only.
build directorybuild/VERSION$ ./build.sh restore to set up a clean Dockerfilebuild/Dockerfile.tmpl$ ./build.sh build to build current tag and latest$ ./build.sh releaseContent type
Image
Digest
Size
373.1 MB
Last updated
almost 9 years ago
docker pull chrisramsay/aws-gen