Public Repository

Last pushed: 10 months ago
Short Description
Gathers tools used across infrastructure
Full Description

Gathers tools used across infrastructure and make them available using docker container

Included tools

  terraform
  packer
  awscli

Image build commands

$make help
TARGETS:

  all    - Build all
  build  - Build docker tool container
  show   - Display current configuration
  help   - Display this help

ENV VARIABLES:

  IMG_NAME       - Docker image name
  TAG_NAME       - Docker image tag
  TAG_LATEST     - Create latest tag image
  INSPECT        - Inspect image after build
  IMG_PUSH       - Push docker image to docker hub
  IMG_PUSH_RETRY - Push retry number

Current image build configuration (with default parameters)

$make show
COMMAND:

bin/build-image.sh -n infra-tools -t dev  -l -i -f 3

CURRENT ENV VARIABLES SETUP:

  IMG_NAME       - infra-tools
  TAG_NAME       - dev
  TAG_LATEST     - yes
  INSPECT        - yes
  IMG_PUSH       - no
  IMG_PUSH_RETRY - 3

Usage

Tools like terraform and packer assumes that necessary data are mounted in /data volume.
Example scripts available in bin/{packer-cli,terraform-cli}.sh mounts current working directory into it.

AWS cli tool requires existing aws configuration. This has to be mounted during tool execution.
Example usage script bin/awscli.sh mounts there user $HOME/.aws (which is assumed to exists)

docker run -it --rm -v <local_path>:/data skipjaq/infra-tools <tool> <command> [<args>]

Example:

direct usage

docker run -it --rm -v /opt/terraform:/data skipjaq/infra-tools terraform plan

using script

bin/awscli.sh s3 ls s3://skipjaq-vagrant-boxes
Docker Pull Command
Owner
skipjaq