Sign inSign up

zerolabssyseng/packer

By zerolabssyseng

•Updated almost 7 years ago

Packer Container

Image
0

349

zerolabssyseng/packer repository overview

⁠Packer Container

⁠Configure Makefile.am
IMAGE = zerolabssyseng/packer

clean-local:
	docker rmi $(CLEAN_OPTIONS) $(IMAGE):$(TAG) || true

build:
	docker build $(BUILD_OPTIONS) --build-arg TAG=${TAG} -t $(IMAGE):$(TAG) .

pull:
	docker pull $(PULL_OPTIONS) $(IMAGE):$(TAG)

push: build
	docker push $(PUSH_OPTIONS) $(IMAGE):$(TAG)
⁠Running with make
make [options]:
    clean-local
    build
    pull
    push
⁠Dockerfile
ARG TAG

FROM zerolabssyseng/build-make:${TAG:-latest}
MAINTAINER "System Engineer (SysEng)"

ENV PACKER_VERSION=1.4.3

RUN apk add --update curl zip && \
    curl -sSL https://releases.hashicorp.com/packer/${PACKER_VERSION}/packer_${PACKER_VERSION}_linux_amd64.zip \
        -o /tmp/packer.zip && \
    unzip /tmp/packer.zip -d /usr/bin && \
    rm /tmp/packer.zip && \
    apk del curl zip && \
    rm -rf /var/cache/apk/*
⁠Docker Compose (Skeleton)
version: '3.5'

volumes:
    packer:

services:
    packer:
        image: zerolabssyseng/packer:latest
        container_name: zerolabssyseng_packer
        volumes:
            - /etc/localtime:/etc/localtime:ro
            - /var/run/docker.sock:/var/run/docker.sock
        environment:
            - ENV=local                                         # environment name
            #- [email protected]:your/project.git  # git repository URL
            #- BUILD_GITREF=HEAD                                # git tag/commit reference to build
            #- BUILD_PROJECT=                                   # project directory (empty for the root of sources)
            #- BUILD_SCRIPT=/usr/local/build/build.sh           # build script
            #- BUILD_TIMEOUT=3600                               # build timeout
            #- CONFIGURE=1                                      # enable configure script (executed only if found)
            #- CONFIGURE_OPTIONS=                               # configure options
            #- MAKE_OPTIONS=                                    # make options
            #- MAKE_TARGET=                                     # make target (leave empty for default target)
            #- MAKE_TARGETOPTIONS=                              # make target options
            #- MAKE_INSTALL=0                                   # enable make install
            #- MAKE_INSTALLOPTIONS=                             # make install options

Tag summary

Content type

Image

Digest

Size

213.3 MB

Last updated

almost 7 years ago

docker pull zerolabssyseng/packer