Skip to content

Instantly share code, notes, and snippets.

@luismayta
Created January 13, 2021 15:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save luismayta/60f0987cc474c16bbfdd2212833ade2c to your computer and use it in GitHub Desktop.
Save luismayta/60f0987cc474c16bbfdd2212833ade2c to your computer and use it in GitHub Desktop.
## Packer
.PHONY: packer.help
PACKER_VERSION := 1.3.1
PACKER_DIR:=$(PROVISION_DIR)/packer
packer := packer
packer.help:
@echo ' packer:'
@echo ''
@echo ' packer.validate validate by ami=python'
@echo ' packer.build build by ami=python'
@echo ''
packer:
make packer.help
packer.update:
@ansible-galaxy install -r "${PACKER_DIR}/${ami}/provisioners/ansible/"requirements.yml \
--roles-path "${PACKER_DIR}/${ami}/provisioners/ansible/"roles/contrib --force
packer.validate:
cd "${PACKER_DIR}/${ami}/" && $(packer) validate packer.json
packer.build:
cd "${PACKER_DIR}/${ami}/" && $(packer) build packer.json
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment