Skip to content

Commit

Permalink
docs: provide version args
Browse files Browse the repository at this point in the history
  • Loading branch information
addetz committed Dec 11, 2023
1 parent f272c67 commit a9e2f74
Show file tree
Hide file tree
Showing 5 changed files with 25 additions and 8 deletions.
7 changes: 6 additions & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@ env:
PALETTE_VERSION: 4.0.2
PALETTE_CLI_VERSION: 4.0.1
PALETTE_EDGE_VERSION: 3.4.3

PACKER_VERSION: 1.9.4
ORAS_VERSION: 1.0.0
TERRAFORM_VERSION: 1.6.5


jobs:
Expand Down Expand Up @@ -66,6 +68,9 @@ jobs:
PALETTE_VERSION=${{env.PALETTE_VERSION}}
PALETTE_CLI_VERSION=${{env.PALETTE_CLI_VERSION}}
PALETTE_EDGE_VERSION=${{env.PALETTE_EDGE_VERSION}}
PACKER_VERSION=${{env.PACKER_VERSION}}
ORAS_VERSION=${{env.ORAS_VERSION}}
TERRAFORM_VERSION=${{env.TERRAFORM_VERSION}}
platforms: linux/amd64,linux/arm64
push: true
tags: ghcr.io/${{ github.repository }}:${{steps.dependencies.outputs.VERSION}}
Expand Down
8 changes: 7 additions & 1 deletion .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ env:
PALETTE_VERSION: 4.0.2
PALETTE_CLI_VERSION: 4.0.1
PALETTE_EDGE_VERSION: 3.4.3
PACKER_VERSION: 1.9.4
ORAS_VERSION: 1.0.0
TERRAFORM_VERSION: 1.6.5

concurrency:
group: docker-${{ github.ref }}
Expand Down Expand Up @@ -73,5 +76,8 @@ jobs:
PALETTE_VERSION=${{env.PALETTE_VERSION}}
PALETTE_CLI_VERSION=${{env.PALETTE_CLI_VERSION}}
PALETTE_EDGE_VERSION=${{env.PALETTE_EDGE_VERSION}}
PACKER_VERSION=${{env.PACKER_VERSION}}
ORAS_VERSION=${{env.ORAS_VERSION}}
TERRAFORM_VERSION=${{env.TERRAFORM_VERSION}}
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ ADD static/defaults/registry-config.yml etc/spectro/config.yml

ARG PALETTE_CLI_VERSION
ARG PALETTE_EDGE_VERSION
ARG PACKER_VERSION=1.9.4
ARG ORAS_VERSION=1.0.0
ARG TERRAFORM_VERSION=1.6.5
ARG PACKER_VERSION
ARG ORAS_VERSION
ARG TERRAFORM_VERSION

ENV REGISTRY_LOG_LEVEL=info
ENV REGISTRY_AUTH=htpasswd
Expand Down
8 changes: 7 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,10 @@ help: ## Display this help

build-docker: ## Build docker image
@echo "Building docker image"
docker build --build-arg PALETTE_VERSION=$(VERSION) --build-arg PALETTE_CLI_VERSION=$(VERSION) --build-arg PALETTE_EDGE_VERSION=$(EDGE) --build-arg PACKER_VERSION=1.8.7 -t tutorials .
docker build --build-arg PALETTE_VERSION=$(PALETTE_VERSION) \
--build-arg PALETTE_CLI_VERSION=$(PALETTE_CLI_VERION) \
--build-arg PALETTE_EDGE_VERSION=$(PALETTE_EDGE_VERSION) \
--build-arg PACKER_VERSION=$(PACKER_VERSION) \
--build-arg ORAS_VERSION=$(PACKER_VERSION) \
--build-arg TERRAFORM_VERSION=$(TERRAFORM_VERSION) \
-t tutorials .
4 changes: 2 additions & 2 deletions docs/docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,9 @@ registry serve /etc/spectro/config.yml > /var/log/registry.log 2>&1 &

# Local Builds

If you are wanting to build the docker image locally you must provide the the build arguments for `PALETTE_VERSION` and `PALETTE_CLI_VERSION`, `PALETTE_EDGE_VERSION`. Use the following command to build a local image. Replace the versions as needed.
If you are wanting to build the docker image locally you must provide the the build arguments for `PALETTE_VERSION`, `PALETTE_CLI_VERSION`, `PALETTE_EDGE_VERSION`, `PACKER_VERSION`, `ORAS_VERSION` and `TERRAFORM_VERSION`. Use the following command to build a local image. Replace the versions as needed.


```shell
docker build --build-arg PALETTE_VERSION=4.0.2 --build-arg PALETTE_CLI_VERSION=4.0.1 --build-arg PALETTE_EDGE_VERSION=3.4.3 --build-arg PACKER_VERSION=1.9.4 -t tutorials .
docker build --build-arg PALETTE_VERSION=4.0.2 --build-arg PALETTE_CLI_VERSION=4.0.1 --build-arg PALETTE_EDGE_VERSION=3.4.3 --build-arg PACKER_VERSION=1.9.4 --build-arg ORAS_VERSION=1.0.0 --build-arg TERRAFORM_VERSION=1.6.5 -t tutorials .
```

0 comments on commit a9e2f74

Please sign in to comment.