Browse Source

test: update deployer default images (#19554)

pull/19577/head
R.B. Boyer 1 year ago committed by GitHub
parent
commit
d203c0abe3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      test-integ/catalogv2/explicit_destinations_test.go
  2. 2
      test-integ/catalogv2/implicit_destinations_test.go
  3. 36
      test-integ/topoutil/images.go
  4. 8
      testing/deployer/topology/default_versions.go
  5. 2
      testing/deployer/update-latest-versions.sh

2
test-integ/catalogv2/explicit_destinations_test.go

@ -108,7 +108,7 @@ func (c testBasicL4ExplicitDestinationsCreator) NewConfig(t *testing.T) *topolog
}
return &topology.Config{
Images: topoutil.TargetImages(),
Images: utils.TargetImages(),
Networks: []*topology.Network{
{Name: clusterName},
{Name: "wan", Type: "wan"},

2
test-integ/catalogv2/implicit_destinations_test.go

@ -108,7 +108,7 @@ func (c testBasicL4ImplicitDestinationsCreator) NewConfig(t *testing.T) *topolog
}
return &topology.Config{
Images: topoutil.TargetImages(),
Images: utils.TargetImages(),
Networks: []*topology.Network{
{Name: clusterName},
{Name: "wan", Type: "wan"},

36
test-integ/topoutil/images.go

@ -1,36 +0,0 @@
// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: BUSL-1.1
package topoutil
import (
"os"
"github.com/hashicorp/consul/test/integration/consul-container/libs/utils"
"github.com/hashicorp/consul/testing/deployer/topology"
)
func TargetImages() topology.Images {
// Start with no preferences.
var images topology.Images
if !runningInCI() {
// Until 1.17 GAs, we want the pre-release versions for these tests,
// run outside of CI for convenience.
images = topology.Images{
ConsulCE: HashicorpDockerProxy + "/hashicorppreview/consul:1.17-dev",
ConsulEnterprise: HashicorpDockerProxy + "/hashicorppreview/consul-enterprise:1.17-dev",
Dataplane: HashicorpDockerProxy + "/hashicorppreview/consul-dataplane:1.3-dev",
}
}
// We want the image overridden by the local build produced by
// 'make test-deployer-setup' or 'make dev-docker'.
testImages := utils.TargetImages()
images = images.OverrideWith(testImages)
return images
}
func runningInCI() bool {
return os.Getenv("GITHUB_ACTIONS") != "" || os.Getenv("CI") != ""
}

8
testing/deployer/topology/default_versions.go

@ -6,8 +6,8 @@
package topology
const (
DefaultConsulImage = "hashicorp/consul:1.16.2"
DefaultConsulEnterpriseImage = "hashicorp/consul-enterprise:1.16.2-ent"
DefaultEnvoyImage = "envoyproxy/envoy:v1.26.4"
DefaultDataplaneImage = "hashicorp/consul-dataplane:1.2.2"
DefaultConsulImage = "hashicorp/consul:1.17.0"
DefaultConsulEnterpriseImage = "hashicorp/consul-enterprise:1.17.0-ent"
DefaultEnvoyImage = "envoyproxy/envoy:v1.27.2"
DefaultDataplaneImage = "hashicorp/consul-dataplane:1.3.0"
)

2
testing/deployer/update-latest-versions.sh

@ -32,7 +32,9 @@ docker run -d --name consul-envoy-check "$consul_latest"
envoy_version=""
while true; do
# We have to retry in case consul doesn't fully start up before we get here.
set +e
envoy_version="$(docker exec consul-envoy-check sh -c 'wget -q localhost:8500/v1/agent/self -O -' | jq -r '.xDS.SupportedProxies.envoy[0]')"
set -e
if [[ -n "$envoy_version" ]]; then
break
fi

Loading…
Cancel
Save