Skip to content
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

Drop remaining trusted jobs #33352

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
156 changes: 0 additions & 156 deletions config/jobs/kubernetes/test-infra/test-infra-trusted.yaml

This file was deleted.

20 changes: 4 additions & 16 deletions config/tests/jobs/jobs_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -292,33 +292,21 @@ func TestRetestMatchJobsName(t *testing.T) {
func TestCommunityJobs(t *testing.T) {
const legacyDefault = "default"
const legacyTrusted = "test-infra-trusted"

// These jobs are used to automate prow itself and will not be migrating
// They run in prow's own cluster and will be removed right before we migrate the control plane
// DO NOT ADD ANY MORE JOBS HERE
knownBadJobs := sets.NewString(
"ci-test-infra-gencred-refresh-kubeconfig",
"post-test-infra-deploy-prow",
"post-test-infra-gencred-refresh-kubeconfig",
"ci-test-infra-autobump-prow",
"ci-test-infra-autobump-prow-for-auto-deploy",
)

// error if any job tries to run in the legacy default cluster
// error if any unknown job tries to run in the legacy trusted cluster
// error if any job tries to run in the legacy trusted cluster
const errFmt = "job %q uses deprecated cluster: %q which may not be used for new jobs, see: https://groups.google.com/a/kubernetes.io/g/dev/c/p6PAML90ZOU"
for _, job := range c.AllStaticPresubmits(nil) {
if job.Cluster == legacyDefault || (job.Cluster == legacyTrusted && !knownBadJobs.Has(job.Name)) {
if job.Cluster == legacyDefault || job.Cluster == legacyTrusted {
t.Errorf(errFmt, job.Name, job.Cluster)
}
}
for _, job := range c.AllStaticPostsubmits(nil) {
if job.Cluster == legacyDefault || (job.Cluster == legacyTrusted && !knownBadJobs.Has(job.Name)) {
if job.Cluster == legacyDefault || job.Cluster == legacyTrusted {
t.Errorf(errFmt, job.Name, job.Cluster)
}
}
for _, job := range c.AllPeriodics() {
if job.Cluster == legacyDefault || (job.Cluster == legacyTrusted && !knownBadJobs.Has(job.Name)) {
if job.Cluster == legacyDefault || job.Cluster == legacyTrusted {
t.Errorf(errFmt, job.Name, job.Cluster)
}
}
Expand Down