Skip to content

Commit

Permalink
Merge pull request #114 from openshift/master
Browse files Browse the repository at this point in the history
sync with openshift/jenkins-sync-plugin
  • Loading branch information
coreydaley authored Jan 18, 2024
2 parents 95fa27a + 83ac37a commit 45585f8
Show file tree
Hide file tree
Showing 655 changed files with 47,245 additions and 29,269 deletions.
2 changes: 1 addition & 1 deletion .ci-operator.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
build_root_image:
name: release
namespace: openshift
tag: rhel-8-release-golang-1.20-openshift-4.14
tag: rhel-8-release-golang-1.21-openshift-4.16
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ all: test-e2e


test-e2e:
oc version
go version
hack/tag-ci-image.sh
KUBERNETES_CONFIG=${KUBECONFIG} go test -timeout 75m -v ./test/e2e/...

verify:
hack/verify.sh


51 changes: 25 additions & 26 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1,26 +1,25 @@
module github.com/openshift/jenkins-sync-plugin

go 1.20
go 1.21

require (
github.com/openshift/api v0.0.0-20230810152202-3e3f07aadec4
github.com/openshift/client-go v0.0.0-20230807132528-be5346fb33cb
k8s.io/api v0.27.4
k8s.io/apimachinery v0.27.4
k8s.io/client-go v0.27.4
github.com/davecgh/go-spew v1.1.1
github.com/openshift/api v0.0.0-20240116232628-6d48d55c0598
github.com/openshift/client-go v0.0.0-20240115204758-e6bf7d631d5e
k8s.io/api v0.29.0
k8s.io/apimachinery v0.29.0
k8s.io/client-go v0.29.0
)

require (
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/emicklei/go-restful/v3 v3.9.0 // indirect
github.com/go-logr/logr v1.2.4 // indirect
github.com/emicklei/go-restful/v3 v3.11.0 // indirect
github.com/go-logr/logr v1.3.0 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
github.com/go-openapi/jsonreference v0.20.1 // indirect
github.com/go-openapi/jsonreference v0.20.2 // indirect
github.com/go-openapi/swag v0.22.3 // indirect
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/google/gnostic v0.5.7-v3refs // indirect
github.com/google/go-cmp v0.5.9 // indirect
github.com/google/gnostic-models v0.6.8 // indirect
github.com/google/gofuzz v1.2.0 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/imdario/mergo v0.3.6 // indirect
Expand All @@ -31,28 +30,28 @@ require (
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect
github.com/spf13/pflag v1.0.5 // indirect
golang.org/x/net v0.10.0 // indirect
golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5 // indirect
golang.org/x/sys v0.8.0 // indirect
golang.org/x/term v0.8.0 // indirect
golang.org/x/text v0.9.0 // indirect
golang.org/x/time v0.0.0-20220210224613-90d013bbcef8 // indirect
golang.org/x/net v0.17.0 // indirect
golang.org/x/oauth2 v0.10.0 // indirect
golang.org/x/sys v0.13.0 // indirect
golang.org/x/term v0.13.0 // indirect
golang.org/x/text v0.13.0 // indirect
golang.org/x/time v0.3.0 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/protobuf v1.28.1 // indirect
google.golang.org/protobuf v1.31.0 // indirect
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/klog/v2 v2.100.1 // indirect
k8s.io/kube-openapi v0.0.0-20230501164219-8b0f38b5fd1f // indirect
k8s.io/utils v0.0.0-20230505201702-9f6742963106 // indirect
k8s.io/klog/v2 v2.110.1 // indirect
k8s.io/kube-openapi v0.0.0-20231010175941-2dd684a91f00 // indirect
k8s.io/utils v0.0.0-20230726121419-3b25d923346b // indirect
sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect
sigs.k8s.io/structured-merge-diff/v4 v4.4.1 // indirect
sigs.k8s.io/yaml v1.3.0 // indirect
)

replace (
k8s.io/api => k8s.io/api v0.27.4
k8s.io/apimachinery => k8s.io/apimachinery v0.27.4
k8s.io/client-go => k8s.io/client-go v0.27.4
k8s.io/api => k8s.io/api v0.29.0
k8s.io/apimachinery => k8s.io/apimachinery v0.29.0
k8s.io/client-go => k8s.io/client-go v0.29.0

)
442 changes: 57 additions & 385 deletions go.sum

Large diffs are not rendered by default.

105 changes: 68 additions & 37 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<parent>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>plugin</artifactId>
<version>4.69</version>
<version>4.77</version>
<relativePath />
</parent>
<groupId>io.fabric8.jenkins.plugins</groupId>
Expand All @@ -22,7 +22,7 @@
<properties>
<revision>1.1.0</revision>
<changelist>999999-SNAPSHOT</changelist>
<jenkins.version>2.401.1</jenkins.version>
<jenkins.version>2.426.2</jenkins.version>
<log.level>INFO</log.level>
</properties>

Expand Down Expand Up @@ -85,72 +85,77 @@
<dependency>
<groupId>org.jenkins-ci.plugins.workflow</groupId>
<artifactId>workflow-multibranch</artifactId>
<version>756.v891d88f2cd46</version>
</dependency>
<dependency>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>script-security</artifactId>
<version>1251.vfe552ed55f8d</version>
<groupId>org.jenkins-ci.plugins.workflow</groupId>
<artifactId>workflow-support</artifactId>
</dependency>
<dependency>
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
<version>2.12.5</version>
<groupId>org.jenkins-ci.plugins.pipeline-stage-view</groupId>
<artifactId>pipeline-rest-api</artifactId>
</dependency>
<dependency>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>git</artifactId>
<version>5.1.0</version>
</dependency>
<dependency>
<groupId>io.jenkins.blueocean</groupId>
<artifactId>blueocean-rest</artifactId>
<version>1.27.4</version>
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
</dependency>
<dependency>
<groupId>org.jenkins-ci.plugins.pipeline-stage-view</groupId>
<artifactId>pipeline-rest-api</artifactId>
<version>2.33</version>
<groupId>io.jenkins.blueocean</groupId>
<artifactId>blueocean-rest</artifactId>
</dependency>
<dependency>
<groupId>org.csanchez.jenkins.plugins</groupId>
<artifactId>kubernetes</artifactId>
<version>3923.v294a_d4250b_91</version>
</dependency>
</dependencies>

<dependencyManagement>
<dependencies>
<!-- https://mvnrepository.com/artifact/io.jenkins.tools.bom/bom-2.303.x -->
<!-- https://mvnrepository.com/artifact/io.jenkins.tools.bom/bom-2.426.x -->
<dependency>
<groupId>io.jenkins.tools.bom</groupId>
<artifactId>bom-2.401.x</artifactId>
<version>2244.vd60654536b_96</version>
<artifactId>bom-2.426.x</artifactId>
<version>2705.vf5c48c31285b_</version>
<scope>import</scope>
<type>pom</type>
</dependency>
<!-- https://mvnrepository.com/artifact/io.jenkins.plugins/snakeyaml-api -->
<dependency>
<groupId>io.jenkins.plugins</groupId>
<artifactId>snakeyaml-api</artifactId>
<version>2.0-100.v5c28c7cb_1e67</version>
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
<version>2.12.5</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.jenkins-ci.plugins.workflow/workflow-job -->
<dependency>
<groupId>org.jenkins-ci.plugins.workflow</groupId>
<artifactId>workflow-job</artifactId>
<version>1316.vd2290d3341a_f</version>
<artifactId>workflow-multibranch</artifactId>
<version>773.vc4fe1378f1d5</version>
</dependency>
<!-- https://mvnrepository.com/artifact/io.jenkins.plugins/ionicons-api -->
<dependency>
<groupId>io.jenkins.plugins</groupId>
<artifactId>ionicons-api</artifactId>
<version>57.v70787cec562e</version>
<groupId>org.jenkins-ci.plugins.workflow</groupId>
<artifactId>workflow-support</artifactId>
<version>865.v43e78cc44e0d</version>
</dependency>
<dependency>
<groupId>org.jenkins-ci.plugins.pipeline-stage-view</groupId>
<artifactId>pipeline-rest-api</artifactId>
<version>2.34</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.jenkins-ci.plugins/jackson2-api -->
<dependency>
<groupId>org.jenkins-ci.plugins</groupId>
<artifactId>jackson2-api</artifactId>
<version>2.15.2-350.v0c2f3f8fc595</version>
<artifactId>git</artifactId>
<version>5.2.1</version>
</dependency>
<dependency>
<groupId>io.jenkins.blueocean</groupId>
<artifactId>blueocean-rest</artifactId>
<version>1.27.9</version>
</dependency>
<dependency>
<groupId>org.csanchez.jenkins.plugins</groupId>
<artifactId>kubernetes</artifactId>
<version>4174.v4230d0ccd951</version>
</dependency>
</dependencies>
</dependencyManagement>
Expand All @@ -170,13 +175,16 @@
<plugin>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<version>4.7.3.5</version>
<version>4.8.2.0</version>
<configuration>
<failOnError>false</failOnError>
</configuration>
<dependencies>
<!-- overwrite dependency on spotbugs if you want to specify the version of spotbugs -->
<dependency>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs</artifactId>
<version>4.7.3</version>
<version>4.8.3</version>
</dependency>
</dependencies>
</plugin>
Expand Down Expand Up @@ -238,6 +246,29 @@
</mapping>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>3.4.1</version>
<executions>
<execution>
<id>enforce-no-snapshots</id>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<banDuplicatePomDependencyVersions />
<requireReleaseDeps>
<message>No Snapshots Allowed!</message>
</requireReleaseDeps>
</rules>
<fail>true</fail>
</configuration>
</execution>
</executions>
</plugin>

</plugins>
</build>
<profiles>
Expand All @@ -262,7 +293,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>3.3.0</version>
<version>3.4.1</version>
<executions>
<execution>
<id>enforce-no-snapshots</id>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.dataformat.yaml.YAMLFactory;

import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
import hudson.BulkChange;
import hudson.model.Item;
import hudson.model.ItemGroup;
Expand Down Expand Up @@ -685,6 +686,7 @@ abstract class StatelessReplicationControllerMixIn extends ReplicationController
@JsonIgnore
private ReplicationControllerStatus status;

@SuppressFBWarnings(value="SIC_INNER_SHOULD_BE_STATIC")
StatelessReplicationControllerMixIn() {
}

Expand All @@ -706,6 +708,7 @@ abstract class ObjectMetaMixIn extends ObjectMeta {
@JsonIgnore
private String uid;

@SuppressFBWarnings(value="SIC_INNER_SHOULD_BE_STATIC")
ObjectMetaMixIn() {
}

Expand Down
12 changes: 10 additions & 2 deletions test/e2e/sync_plugin_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ import (
"k8s.io/apimachinery/pkg/util/validation"
"k8s.io/apimachinery/pkg/util/wait"
"k8s.io/apimachinery/pkg/watch"

"github.com/davecgh/go-spew/spew"
)

const (
Expand Down Expand Up @@ -120,7 +122,7 @@ func instantiateTemplate(ta *testArgs) {
}

default:
ta.t.Logf("unexpected event type %s: %#v", string(event.Type), event.Object)
ta.t.Logf("unexpected event type %s: %#v", string(event.Type), spew.Sdump(event.Object))
}
}

Expand Down Expand Up @@ -1146,7 +1148,12 @@ func TestBlueGreen(t *testing.T) {
buildAndSwitch("blue")
}

func TestPersistentVolumes(t *testing.T) {
/*
Failing due to more restrictive Security Policies in newer OCP versions
It is unlikely that we will reenable this test without a drastic overhaul
*/
/*
func TestPersistentVolumes(t *testing.T) {
ta := &testArgs{t: t}
setupClients(ta.t)
randomTestNamespaceName := generateName(testNamespace)
Expand Down Expand Up @@ -1258,3 +1265,4 @@ func TestPersistentVolumes(t *testing.T) {
}
}
*/
1 change: 1 addition & 0 deletions vendor/github.com/davecgh/go-spew/spew/bypass.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions vendor/github.com/davecgh/go-spew/spew/bypasssafe.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 45585f8

Please sign in to comment.