Skip to content

Conversation

@smarterclayton
Copy link
Contributor

@smarterclayton smarterclayton commented May 23, 2018

This adds a new pattern for reusing the openshift master for integration
style tests.

This is the last step to replacing all image-registry jobs with ci-operator.

Depended on openshift/image-registry#88

@openshift-ci-robot openshift-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels May 23, 2018
@smarterclayton smarterclayton requested a review from 0xmichalis May 24, 2018 02:18
Copy link
Contributor

Choose a reason for hiding this comment

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

needs an update

Copy link
Contributor

Choose a reason for hiding this comment

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

either use /tmp/admin.kubeconfig or copy from the other container to the right place

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Using /tmp/shared consistently.

Copy link
Contributor

Choose a reason for hiding this comment

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

Do you want this test to be triggered alongside the new?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

no, going to move to "old-integration" and then remove when it's truly gone.

Copy link
Contributor

Choose a reason for hiding this comment

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

You were thinking about something

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Wanted a working directory for crap that wouldn't show up in artifacts or shared content.

@smarterclayton smarterclayton force-pushed the integration branch 2 times, most recently from 6130080 to 3a0b218 Compare May 25, 2018 05:15
@smarterclayton smarterclayton changed the title WIP - Integration tests for registry, replacing existing Integration tests for registry, replacing existing May 25, 2018
@openshift-ci-robot openshift-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label May 25, 2018
This adds a new pattern for reusing the openshift master for integration
style tests.
@smarterclayton
Copy link
Contributor Author

Updated, i think this is good to go.

@0xmichalis
Copy link
Contributor

It seems that sidecar does not mount /tmp for artifacts but /logs. entrypoint also uses /logs/artifacts for ARTIFACTS even though COMMAND has the artifacts path you are using here (/tmp/artifacts). We probably want the sidecar to use the right path.

  - command:
    - /tools/entrypoint
    env:
    - name: COMMAND
      value: TEST_KUBECONFIG=${KUBECONFIG} ARTIFACT_DIR=/tmp/artifacts JUNIT_REPORT=true
        make test-integration
    - name: CONFIG_SPEC
      valueFrom:
        configMapKeyRef:
          key: config.json
          name: ci-operator-image-registry
    - name: ARTIFACTS
      value: /logs/artifacts
    - name: BUILD_ID
      value: "999883142342905856"
    - name: BUILD_NUMBER
      value: "999883142342905856"
    - name: ENTRYPOINT_OPTIONS
      value: '{"args":["ci-operator","--delete-when-idle=10m","--artifact-dir=$(ARTIFACTS)","--dry-run=false","--template=/usr/local/integration","--target=integration"],"timeout":7200000000000,"grace_period":15000000000,"artifact_dir":"/logs/artifacts","process_log":"/logs/process-log.txt","marker_file":"/logs/marker-file.txt"}'
    - name: GOPATH
      value: /home/prow/go
    - name: JOB_NAME
      value: pull-ci-image-registry-integration
    - name: JOB_SPEC
      value: '{"type":"presubmit","job":"pull-ci-image-registry-integration","buildid":"999883142342905856","prowjobid":"74e42940-5fdb-11e8-99d8-7831c1b76042","refs":{"org":"openshift","repo":"image-registry","base_ref":"master","base_sha":"ff73b7f5a67f99fa406d2cd21a20714d189f7d2c","pulls":[{"number":82,"author":"smarterclayton","sha":"cd907c3"}]}}'
    - name: JOB_TYPE
      value: presubmit
    - name: PROW_JOB_ID
      value: 74e42940-5fdb-11e8-99d8-7831c1b76042
    - name: PULL_BASE_REF
      value: master
    - name: PULL_BASE_SHA
      value: ff73b7f5a67f99fa406d2cd21a20714d189f7d2c
    - name: PULL_NUMBER
      value: "82"
    - name: PULL_PULL_SHA
      value: cd907c3
    - name: PULL_REFS
      value: master:ff73b7f5a67f99fa406d2cd21a20714d189f7d2c,82:cd907c3
    - name: REPO_NAME
      value: image-registry
    - name: REPO_OWNER
      value: openshift
    image: docker-registry.default.svc:5000/ci/ci-operator@sha256:7eb706071d71b89dcac6f586fd7b6cdda82b3519cc75ac2d821d2ef655d914a1
    imagePullPolicy: Always
    name: test
    resources: {}
    securityContext:
      capabilities:
        drop:
        - KILL
        - MKNOD
        - SETGID
        - SETUID
      runAsUser: 1000130000
    terminationMessagePath: /dev/termination-log
    terminationMessagePolicy: File
    volumeMounts:
    - mountPath: /usr/local/integration
      name: job-definition
      subPath: master-sidecar.yaml
    - mountPath: /logs
      name: logs
    - mountPath: /home/prow/go
      name: code
    - mountPath: /tools
      name: tools
    - mountPath: /var/run/secrets/kubernetes.io/serviceaccount
      name: ci-operator-token-tbshg
      readOnly: true
    workingDir: /home/prow/go/src/github.com/openshift/image-registry
  - command:
    - /sidecar
    env:
    - name: JOB_SPEC
      value: '{"type":"presubmit","job":"pull-ci-image-registry-integration","buildid":"999883142342905856","prowjobid":"74e42940-5fdb-11e8-99d8-7831c1b76042","refs":{"org":"openshift","repo":"image-registry","base_ref":"master","base_sha":"ff73b7f5a67f99fa406d2cd21a20714d189f7d2c","pulls":[{"number":82,"author":"smarterclayton","sha":"cd907c3"}]}}'
    - name: SIDECAR_OPTIONS
      value: '{"gcs_options":{"items":["/logs/artifacts"],"bucket":"origin-ci-test","path_strategy":"single","default_org":"openshift","default_repo":"origin","gcs_credentials_file":"/secrets/gcs/service-account.json","dry_run":false},"wrapper_options":{"process_log":"/logs/process-log.txt","marker_file":"/logs/marker-file.txt"}}'
    image: registry.svc.ci.openshift.org/ci/sidecar:latest-json
    imagePullPolicy: IfNotPresent
    name: sidecar
    resources: {}
    securityContext:
      capabilities:
        drop:
        - KILL
        - MKNOD
        - SETGID
        - SETUID
      runAsUser: 1000130000
    terminationMessagePath: /dev/termination-log
    terminationMessagePolicy: File
    volumeMounts:
    - mountPath: /logs
      name: logs
    - mountPath: /secrets/gcs
      name: gcs-credentials
    - mountPath: /var/run/secrets/kubernetes.io/serviceaccount
      name: ci-operator-token-tbshg
      readOnly: true

@smarterclayton
Copy link
Contributor Author

smarterclayton commented May 25, 2018

The core pod (ci operator) is writing to /logs/artifacts. That's now hardcoded in the test-infra (which I thought was weird)

The pods are definitely different.

@smarterclayton smarterclayton merged commit 73dc128 into openshift:master May 25, 2018
@openshift-ci-robot
Copy link
Contributor

@smarterclayton: Updated the config configmap from file cluster/ci/config/prow/config.yaml

Details

In response to this:

This adds a new pattern for reusing the openshift master for integration
style tests.

This is the last step to replacing all image-registry jobs with ci-operator.

Depended on openshift/image-registry#88

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@smarterclayton smarterclayton deleted the integration branch April 24, 2019 14:01
wking added a commit to wking/openshift-release that referenced this pull request Dec 9, 2020
…rator tests

The outgoing integration tests have used a master-sidecar since they
landed in d1af815 (Integration tests for registry, replacing
existing, 2018-05-23, openshift#888).  This recently broke, with jobs like [1]
failing with:

  Waiting for kube-apiserver to come up
  !!! [1118 23:29:05] Timed out waiting for kube-apiserver:  to answer at https://10.130.11.147:8443/healthz; tried 60 waiting 1 between each

With the Kubernetes API-server dying with:

  $ curl -s https://gcsweb-ci.apps.ci.l2s4.p1.openshiftapps.com/gcs/origin-ci-test/pr-logs/pull/opensift_cluster-version-operator/443/pull-ci-openshift-cluster-version-operator-master-integration/1329201271097266176/artifacts/integration/logs/kube-apiserver.log | tail -n2
  I1118 23:28:05.064590     308 flags.go:59] FLAG: --watch-cache-sizes="[]"
  Error: error creating self-signed certificates: mkdir /var/run/kubernetes: permission denied

This commit pivots to the off-the-shelf openshift-e2e-gcp workflow,
substituting in a custom 'test' step to run the existing integration
tests.

Porting back to 4.4.  Older releases are end-of-life [2], but if we
need to revive them for some reason we can port this back further
then.

[1]: https://prow.ci.openshift.org/view/gs/origin-ci-test/pr-logs/pull/openshift_cluster-version-operator/443/pull-ci-openshift-cluster-version-operator-master-integration/1329201271097266176
[2]: https://access.redhat.com/support/policy/updates/openshift#dates
derekhiggins pushed a commit to derekhiggins/release that referenced this pull request Oct 24, 2023
Most people have already moved to CentOS 8 or RHEL 8 at this point.
Let's give one last very clear warning that CentOS 7 is going away,
and then a bit later we can drop all related code for CentOS 7.

Closes openshift#888
derekhiggins pushed a commit to derekhiggins/release that referenced this pull request Oct 24, 2023
We use yq in utils.sh but do not install it. There is no system
package, so we have to install via pip.

Fixes openshift#888

Signed-off-by: Doug Hellmann <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants