Files
nomad/e2e/artifact/input/artifact_linux.nomad
Tim Gross 88dc842729 testing: use Docker Hub registry mirror for CI (#25703)
As of April 1, Docker Hub rate limits tightened. With only 10 pulls/hr/IP, we're
likely to encounter test failures. Switch all Docker images getting pulled from
this repository to use the HashiCorp managed registry mirror.

Note that most of our tests in `drivers/docker` don't pull from the remote
registry but load a local image, while others will need to pull from the remote
and fetch different images depending on OS/arch. Refactor the definition of test
task configuration to make it clear which is which, and de-factor some false
sharing of setup functions.

Updates the E2E tests to use that registry by configuring the Docker
daemon. This required changing out a few container images that we don't have in
the registry, but these new images are all smaller. There are a couple of tests
that still use explicitly-tagged `docker.io` images or other third-party
registries, which have been left in place.

Ref: https://hashicorp.atlassian.net/browse/NET-12233

update E2E images to those in the registry mirror

fix windows and docklog test build

fix stopsignal test

mop-up

more mop-up
2025-04-18 14:21:49 -04:00

347 lines
7.7 KiB
HCL

# Copyright (c) HashiCorp, Inc.
# SPDX-License-Identifier: BUSL-1.1
job "linux" {
datacenters = ["dc1"]
type = "batch"
constraint {
attribute = "${attr.kernel.name}"
value = "linux"
}
group "rawexec" {
task "rawexec_file_default" {
artifact {
source = "https://raw.githubusercontent.com/hashicorp/go-set/main/go.mod"
}
driver = "raw_exec"
config {
command = "cat"
args = ["local/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "rawexec_file_custom" {
artifact {
source = "https://raw.githubusercontent.com/hashicorp/go-set/main/go.mod"
destination = "local/my/path"
}
driver = "raw_exec"
config {
command = "cat"
args = ["local/my/path/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "rawexec_file_alloc_dots" {
artifact {
source = "https://raw.githubusercontent.com/hashicorp/go-set/main/go.mod"
destination = "../alloc/go.mod"
mode = "file"
}
driver = "raw_exec"
config {
command = "cat"
args = ["../alloc/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "rawexec_file_alloc_env" {
artifact {
source = "https://raw.githubusercontent.com/hashicorp/go-set/main/go.mod"
destination = "${NOMAD_ALLOC_DIR}/go.mod"
mode = "file"
}
driver = "raw_exec"
config {
command = "cat"
args = ["${NOMAD_ALLOC_DIR}/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "rawexec_zip_default" {
artifact {
source = "https://github.com/hashicorp/go-set/archive/refs/heads/main.zip"
}
driver = "raw_exec"
config {
command = "cat"
args = ["local/go-set-main/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "rawexec_zip_custom" {
artifact {
source = "https://github.com/hashicorp/go-set/archive/refs/heads/main.zip"
destination = "local/my/zip"
}
driver = "raw_exec"
config {
command = "cat"
args = ["local/my/zip/go-set-main/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "rawexec_git_custom" {
artifact {
source = "git::https://github.com/hashicorp/go-set"
destination = "local/repository"
}
driver = "raw_exec"
config {
command = "cat"
args = ["local/repository/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
}
group "exec" {
task "exec_file_default" {
artifact {
source = "https://raw.githubusercontent.com/hashicorp/go-set/main/go.mod"
}
driver = "exec"
config {
command = "cat"
args = ["local/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 256
}
}
task "exec_file_custom" {
artifact {
source = "https://raw.githubusercontent.com/hashicorp/go-set/main/go.mod"
destination = "local/my/path"
}
driver = "exec"
config {
command = "cat"
args = ["local/my/path/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 256
}
}
task "exec_file_alloc" {
artifact {
source = "https://raw.githubusercontent.com/hashicorp/go-set/main/go.mod"
destination = "${NOMAD_ALLOC_DIR}/go.mod"
mode = "file"
}
driver = "exec"
config {
command = "cat"
args = ["${NOMAD_ALLOC_DIR}/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "exec_zip_default" {
artifact {
source = "https://github.com/hashicorp/go-set/archive/refs/heads/main.zip"
}
driver = "exec"
config {
command = "cat"
args = ["local/go-set-main/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 256
}
}
task "exec_zip_custom" {
artifact {
source = "https://github.com/hashicorp/go-set/archive/refs/heads/main.zip"
destination = "local/my/zip"
}
driver = "exec"
config {
command = "cat"
args = ["local/my/zip/go-set-main/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 256
}
}
task "exec_git_custom" {
artifact {
source = "git::https://github.com/hashicorp/go-set"
destination = "local/repository"
}
driver = "exec"
config {
command = "cat"
args = ["local/repository/go.mod"]
}
resources {
cpu = 16
memory = 32
disk = 256
}
}
}
group "docker" {
task "docker_file_default" {
artifact {
source = "https://raw.githubusercontent.com/hashicorp/go-set/main/go.mod"
}
driver = "docker"
config {
image = "busybox:1"
command = "/bin/sh"
args = ["-c", "cat local/go.mod && sleep 10"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "docker_file_custom" {
artifact {
source = "https://raw.githubusercontent.com/hashicorp/go-set/main/go.mod"
destination = "local/my/path"
}
driver = "docker"
config {
image = "busybox:1"
command = "/bin/sh"
args = ["-c", "cat local/my/path/go.mod && sleep 10"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "docker_file_alloc" {
artifact {
source = "https://raw.githubusercontent.com/hashicorp/go-set/main/go.mod"
destination = "${NOMAD_ALLOC_DIR}/go.mod"
mode = "file"
}
driver = "docker"
config {
image = "busybox:1"
command = "/bin/sh"
args = ["-c", "cat ${NOMAD_ALLOC_DIR}/go.mod && sleep 10"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "docker_zip_default" {
artifact {
source = "https://github.com/hashicorp/go-set/archive/refs/heads/main.zip"
}
driver = "docker"
config {
image = "busybox:1"
command = "/bin/sh"
args = ["-c", "cat local/go-set-main/go.mod && sleep 10"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "docker_zip_custom" {
artifact {
source = "https://github.com/hashicorp/go-set/archive/refs/heads/main.zip"
destination = "local/my/zip"
}
driver = "docker"
config {
image = "busybox:1"
command = "/bin/sh"
args = ["-c", "cat local/my/zip/go-set-main/go.mod && sleep 10"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
task "docker_git_custom" {
artifact {
source = "git::https://github.com/hashicorp/go-set"
destination = "local/repository"
}
driver = "docker"
config {
image = "busybox:1"
command = "/bin/sh"
args = ["-c", "cat local/repository/go.mod && sleep 10"]
}
resources {
cpu = 16
memory = 32
disk = 64
}
}
}
}