-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test: deduplicate test manifests and fix "stress" profile #14001
Open
MasonM
wants to merge
4
commits into
argoproj:main
Choose a base branch
from
MasonM:deduplicate-manifest
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This deduplicates the test manifests using [Kustomize Components](https://kubectl.docs.kubernetes.io/guides/config_management/components/) and fixes the "stress" profile, which it seems has been broken ever since `87cb1559107ec88dd418229b38113d70ba2a8580`. Running `make install PROFILE=stress` on the `main` branch gives this error: ``` error: accumulating resources: accumulation err='merging resources from 'workflow-controller-podpriorityclass.yaml': may not add resource with an already registered id: PriorityClass.v1.scheduling.k8s.io/workflow-controller.[noNs]': must build at directory: '/home/vscode/go/src/github.com/argoproj/argo-workflows/test/e2e/manifests/stress/workflow-controller-podpriorityclass.yaml': file is not directory ``` I also used a component to handle scaling `deploy/workflow-controller`/`deploy/argo-server` so we can remove those lines from `Makefile`. I used the following script to verify nothing unexpected changed: ``` set -e for PROFILE in events minimal mysql plugins postgres prometheus sso; do echo "diffing $PROFILE" git checkout --quiet main kubectl kustomize --load-restrictor=LoadRestrictionsNone test/e2e/manifests/$PROFILE > "old_$PROFILE.yaml" git checkout --quiet deduplicate-manifest kubectl kustomize --load-restrictor=LoadRestrictionsNone test/e2e/manifests/$PROFILE > "new_$PROFILE.yaml" diff -U3 "old_$PROFILE.yaml" "new_$PROFILE.yaml" || true done ``` Output: ``` diffing events --- old_events.yaml 2024-12-16 03:45:49.404387813 +0000 +++ new_events.yaml 2024-12-16 03:45:49.650400191 +0000 @@ -3760,6 +3760,17 @@ apiVersion: v1 kind: Secret metadata: + annotations: + kubernetes.io/service-account.name: argo-server + labels: + app.kubernetes.io/part-of: argo + name: argo-server.service-account-token + namespace: argo +type: kubernetes.io/service-account-token +--- +apiVersion: v1 +kind: Secret +metadata: labels: app.kubernetes.io/part-of: argo name: argo-workflows-webhook-clients diffing minimal diffing mysql diffing plugins diffing postgres diffing prometheus --- old_prometheus.yaml 2024-12-16 03:45:52.009518890 +0000 +++ new_prometheus.yaml 2024-12-16 03:45:52.203528651 +0000 @@ -3499,6 +3499,16 @@ apiVersion: v1 kind: Secret metadata: + annotations: + kubernetes.io/service-account.name: argo-server + labels: + app.kubernetes.io/part-of: argo + name: argo-server.service-account-token +type: kubernetes.io/service-account-token +--- +apiVersion: v1 +kind: Secret +metadata: labels: app.kubernetes.io/part-of: argo name: argo-workflows-webhook-clients @@ -3728,7 +3738,6 @@ name: argo-server namespace: argo spec: - replicas: 0 selector: matchLabels: app: argo-server @@ -3785,7 +3794,6 @@ name: workflow-controller namespace: argo spec: - replicas: 0 selector: matchLabels: app: workflow-controller diffing sso ``` Signed-off-by: Mason Malone <[email protected]>
Signed-off-by: Mason Malone <[email protected]>
blkperl
approved these changes
Dec 20, 2024
/retest |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
The duplication of the Kustomization files under
test/e2e/manifests/
makes them hard to follow. Also, the "stress" profile is broken, which I'm guessing was introduced in 87cb155:Modifications
I used Kustomize Components to clean up the manifests by extracting common configuration to a
base
component.I also added a
local-argo
component to handle scalingworkflow-controller
andargo-server
so we can remove the corresponding lines fromMakefile
, since it's cleaner to letkustomize
handle that.Verification
I used the following script to verify nothing unexpected changed:
Output: