Compare commits

..

1 Commits

Author SHA1 Message Date
dccf8d9837 feat: enable incus support in actionsdind container
All checks were successful
Build / build (pull_request) Successful in 3m4s
- add incus-images backend
- set incus-images as default backend
2025-04-21 17:09:48 +10:00
6 changed files with 0 additions and 25 deletions

View File

@ -91,8 +91,6 @@ $(DIRS):
export SUFFIX=$(SUFFIX) && \
export GIT_COMMIT=$(GIT_COMMIT) && \
export GIT_BRANCH=$(GIT_BRANCH) && \
export VAULT_ADDR=https://vault.query.consul:8200
export VAULT_TOKEN=$$(vault write -field=token auth/approle/login role_id=$$VAULT_ROLEID) && \
/usr/bin/packer init . && \
/usr/bin/packer build . )

View File

@ -21,18 +21,6 @@ build {
destination = "/"
}
# manage deploying incus client certficates
# this isnt super-secure, as the key ends up baked into the docker image
provisioner "shell" {
inline = [
"if [ ${var.include_incus_client_certs} = true ]; then",
" mkdir -p /root/.config/incus",
" echo '${replace(local.incus_crt, "'", "'\\''")}' > /root/.config/incus/client.crt",
" echo '${replace(local.incus_key, "'", "'\\''")}' > /root/.config/incus/client.key",
"fi"
]
}
# post-file-copy scripts
provisioner "shell" {
inline = var.scripts_post_file_copy

View File

@ -1,6 +1,4 @@
# almalinux/8.10/actionsdind
deploy_files_from_common = true
include_incus_client_certs = true
docker_source = "git.query.consul/unkin/almalinux8-base:latest"
packages = [
"bash",

View File

@ -1,6 +1,4 @@
# almalinux/9.5/actionsdind
deploy_files_from_common = true
include_incus_client_certs = true
docker_source = "git.query.consul/unkin/almalinux9-base:latest"
packages = [
"bash",

View File

@ -7,6 +7,4 @@ locals {
incus_base_name = "${var.os_name}${var.os_version_major}/${var.os_image}"
incus_output_image = "${local.incus_base_name}/${var.suffix}"
is_master = "${var.git_branch}" == "master"
incus_key = vault("kv/data/service/packer/builder/docker-incus-client", "private_key")
incus_crt = vault("kv/data/service/packer/builder/docker-incus-client", "public_key")
}

View File

@ -121,8 +121,3 @@ variable "git_branch" {
type = string
default = env("GIT_BRANCH")
}
variable "include_incus_client_certs" {
type = bool
default = false
}