Skip to content

Backport of Fix default Ent image tag in acceptance tests into release/0.49.x#2698

Merged
zalimeni merged 1 commit intorelease/0.49.xfrom
backport/zalimeni/fix-acceptance-ent-image-tag/officially-tender-rabbit
Jul 31, 2023
Merged

Backport of Fix default Ent image tag in acceptance tests into release/0.49.x#2698
zalimeni merged 1 commit intorelease/0.49.xfrom
backport/zalimeni/fix-acceptance-ent-image-tag/officially-tender-rabbit

Conversation

@hc-github-team-consul-core
Copy link
Copy Markdown
Collaborator

Backport

This PR is auto-generated from #2683 to be assessed for backporting due to the inclusion of the label backport/0.49.x.

🚨

Warning automatic cherry-pick of commits failed. If the first commit failed,
you will see a blank no-op commit below. If at least one commit succeeded, you
will see the cherry-picked commits up to, not including, the commit where
the merge conflict occurred.

The person who merged in the original PR is:
@zalimeni
This person should manually cherry-pick the original PR into a new backport PR,
and close this one when the manual backport PR is merged in.

merge conflict error: POST https://api.github.com/repos/hashicorp/consul-k8s/merges: 409 Merge conflict []

The below text is copied from the body of the original PR.


Rather than hard-coding the Docker repository and parsing the non-Ent image tag for a version, simply replace the image name and retain other coordinates. This is consistent with our tagging scheme introduced in hashicorp/consul#13541 and will allow for using hashicorppreview images seamlessly regardless of whether OSS or Ent is being tested.

Also add a make target to help with testing local images in multi-cluster scenarios.

Changes proposed in this PR:

  • Align consul-enterprise image tag derivation with our OSS + Ent tagging scheme
  • Add a make target for loading dev images across kind clusters

How I've tested this PR:

  • Updated unit tests
  • Tested manually:
❯ go test ./sameness/... -v -timeout 2h -failfast -use-kind -no-cleanup-on-failure -kube-contexts="kind-dc1,kind-dc2,kind-dc3,kind-dc4" -enable-enterprise -enable-multi-cluster -debug-directory=/tmp/debug -consul-k8s-image=consul-k8s-control-plane-dev
...
    command.go:... Running command helm with args... --set global.image=docker.mirror.hashicorp.services/hashicorppreview/consul-enterprise:1.17-dev...
❯ make kind-load
kind load docker-image --name dc1 consul-k8s-control-plane-dev
Image: "consul-k8s-control-plane-dev" with ID "sha256:609bbc07ce629667028157d8c14113123a87ef49592cc2aa94e89bc5707da313" not yet present on node "dc1-control-plane", loading...
kind load docker-image --name dc2 consul-k8s-control-plane-dev
Image: "consul-k8s-control-plane-dev" with ID "sha256:609bbc07ce629667028157d8c14113123a87ef49592cc2aa94e89bc5707da313" not yet present on node "dc2-control-plane", loading...
kind load docker-image --name dc3 consul-k8s-control-plane-dev
Image: "consul-k8s-control-plane-dev" with ID "sha256:609bbc07ce629667028157d8c14113123a87ef49592cc2aa94e89bc5707da313" not yet present on node "dc3-control-plane", loading...
kind load docker-image --name dc4 consul-k8s-control-plane-dev
Image: "consul-k8s-control-plane-dev" with ID "sha256:609bbc07ce629667028157d8c14113123a87ef49592cc2aa94e89bc5707da313" not yet present on node "dc4-control-plane", loading...

❯ DEV_IMAGE=zalimeni-local/consul:recent make kind-load
kind load docker-image --name dc1 zalimeni-local/consul:recent
Image: "zalimeni-local/consul:recent" with ID "sha256:4850dee3c23a007cd30f9814194de884c1336ea6b16c8bfd34a13f6c45651d5a" not yet present on node "dc1-control-plane", loading...
kind load docker-image --name dc2 zalimeni-local/consul:recent
Image: "zalimeni-local/consul:recent" with ID "sha256:4850dee3c23a007cd30f9814194de884c1336ea6b16c8bfd34a13f6c45651d5a" not yet present on node "dc2-control-plane", loading...
kind load docker-image --name dc3 zalimeni-local/consul:recent
Image: "zalimeni-local/consul:recent" with ID "sha256:4850dee3c23a007cd30f9814194de884c1336ea6b16c8bfd34a13f6c45651d5a" not yet present on node "dc3-control-plane", loading...
kind load docker-image --name dc4 zalimeni-local/consul:recent
Image: "zalimeni-local/consul:recent" with ID "sha256:4850dee3c23a007cd30f9814194de884c1336ea6b16c8bfd34a13f6c45651d5a" not yet present on node "dc4-control-plane", loading...

How I expect reviewers to test this PR: 👀

Checklist:


Overview of commits

@hc-github-team-consul-core hc-github-team-consul-core force-pushed the backport/zalimeni/fix-acceptance-ent-image-tag/officially-tender-rabbit branch from ce204fd to 396a783 Compare July 31, 2023 13:55
@zalimeni zalimeni reopened this Jul 31, 2023
@zalimeni zalimeni marked this pull request as ready for review July 31, 2023 14:14
@zalimeni zalimeni force-pushed the backport/zalimeni/fix-acceptance-ent-image-tag/officially-tender-rabbit branch from 74c2c5b to 96d13e4 Compare July 31, 2023 14:15
Comment on lines +132 to +134
kind-load:
kind load docker-image --name dc1 $(DEV_IMAGE)
kind load docker-image --name dc2 $(DEV_IMAGE)
Copy link
Copy Markdown
Member

@zalimeni zalimeni Jul 31, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For this backport, when fixing conflicts, I left out the dc3 and dc4 load commands as the change that introduced those DC's wasn't backported to 0.49.x.

@zalimeni zalimeni requested a review from wilkermichael July 31, 2023 15:20
@zalimeni
Copy link
Copy Markdown
Member

zalimeni commented Jul 31, 2023

@wilkermichael requesting a quick review of this one since unlike the other backports, I technically changed a few lines (removed dc3 + dc4 in load command).

@zalimeni zalimeni enabled auto-merge (squash) July 31, 2023 15:24
@zalimeni zalimeni merged commit abe28a5 into release/0.49.x Jul 31, 2023
@zalimeni zalimeni deleted the backport/zalimeni/fix-acceptance-ent-image-tag/officially-tender-rabbit branch July 31, 2023 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants