mirror of
https://github.com/hashicorp/packer.git
synced 2026-06-10 09:10:27 -04:00
docker: add full image to docker README
This commit is contained in:
parent
376f0e9991
commit
168e464ee4
1 changed files with 26 additions and 17 deletions
|
|
@ -1,37 +1,46 @@
|
|||
# Packer Docker Container
|
||||
|
||||
The root of this repository contains the officially supported HashiCorp Dockerfile to build the hashicorp/packer docker image. The `dev` docker image should be built for local dev and testing, while the production docker image, `release`, is built in CI and makes use of CI-built binaries. The `official` docker image is built using the official binaries from releases.hashicorp.com.
|
||||
The root of this repository contains the officially supported HashiCorp Dockerfile to build the hashicorp/packer docker image. The `dev` docker image should be built for local dev and testing, while the production docker image, `release`, is built in CI and makes use of CI-built binaries. The `light` and `full` docker images are built using the official binaries from releases.hashicorp.com.
|
||||
|
||||
## Build
|
||||
|
||||
See the Makefile targets in the root of this repository for building Packer images in either
|
||||
development or release modes:
|
||||
|
||||
- `make docker-dev`
|
||||
- `make docker-official`
|
||||
- `make docker-multiarch-official`
|
||||
- `make docker`
|
||||
Refer to the Makefile of this repository, especially the `docker` and `docker-dev` targets to build a local version of the dev image based on the sources available.
|
||||
|
||||
### Usage
|
||||
|
||||
This repository automatically builds containers for using the
|
||||
[`packer`](https://packer.io) command line program. It contains two distinct
|
||||
varieties of build, an `official` version, aka `light`, which just contains the binary.
|
||||
It also contains a `dev` version, aka `full`, which compiles the binary from source
|
||||
[`packer`](https://developer.hashicorp.com/packer) command line program. It contains three distinct
|
||||
varieties of build: a `light` version, which just contains the binary,
|
||||
a `full` build, which contains the Packer binary with pre-installed plugins,
|
||||
and a `dev` version, which compiles the binary from source
|
||||
inside the container before exposing it for use.
|
||||
|
||||
##### `official`
|
||||
##### `light`
|
||||
|
||||
The `official` version of this container will copy the current stable version of
|
||||
The `light` version of this container will copy the current stable version of
|
||||
the binary, taken from releases.hashicorp.com, into the container. It will also
|
||||
set it for use as the default entrypoint. This will be the best option for most uses,
|
||||
especially if you are just looking to run the binary from a container. This image
|
||||
is tagged as both `official` and `light`.
|
||||
especially if you are just looking to run the binary from a container.
|
||||
The `latest` tag on DockerHub also points to this version.
|
||||
|
||||
You can use this version with the following:
|
||||
```shell
|
||||
docker run <args> hashicorp/packer:official <command>
|
||||
docker run <args> hashicorp/packer:light <command>
|
||||
```
|
||||
|
||||
##### `full`
|
||||
|
||||
The `full` version of the container builds upon `light` and pre-installs
|
||||
the plugins officially maintained by HashiCorp.
|
||||
|
||||
You can use this version with the following:
|
||||
```shell
|
||||
docker run <args> hashicorp/packer:full <command>
|
||||
```
|
||||
|
||||
You can view the list of pre-installed plugins with the following:
|
||||
```shell
|
||||
docker run <args> hashicorp/packer:full plugins installed
|
||||
```
|
||||
|
||||
##### `dev`
|
||||
|
|
@ -41,7 +50,7 @@ the current ref of this [repository](https://github.com/hashicorp/packer). Using
|
|||
official `golang` image](https://hub.docker.com/_/golang/) as a base, this
|
||||
container will copy the source from the current branch, build the binary, and
|
||||
expose it for running. Because all build artifacts are included, it should be quite a bit larger than
|
||||
the `official` image. This version of the container is most useful for development or
|
||||
the `light` image. This version of the container is most useful for development or
|
||||
debugging.
|
||||
|
||||
You can use this version with the following:
|
||||
|
|
|
|||
Loading…
Reference in a new issue