Skip to content

Conversation

@abhinavdahiya
Copy link
Contributor

image-registry-operator is using the ID from clusterversion object in the cluster to tag s3 buckets 1.

$ AWS_PROFILE=ci aws s3api get-bucket-tagging  --bucket image-registry-us-east-1-f23dc729905144e6b844ab3d76a42ed7-a306
{
    "TagSet": [
        {
            "Key": "openshiftClusterID",
            "Value": "f23dc729-9051-44e6-b844-ab3d76a42ed7"
        },
        {
            "Key": "expirationDate",
            "Value": "2019-02-23T05:39+0000"
        }
    ]
}

Therefore the destroy code is leaking registry s3 buckets. Adding the openshiftClusterID tag to AWS metadata back to make sure we don't
leak resources.

Installer tried to move to single tag for AWS clusters here 2.

@openshift-ci-robot openshift-ci-robot added size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Feb 23, 2019
@crawford
Copy link
Contributor

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Feb 23, 2019
@openshift-bot
Copy link
Contributor

/retest

Please review the full test history for this PR and help us cut down flakes.

image-registry-operator is using the ID from clusterversion object in the cluster to tag s3 buckets [1].

```
$ AWS_PROFILE=ci aws s3api get-bucket-tagging  --bucket image-registry-us-east-1-f23dc729905144e6b844ab3d76a42ed7-a306
{
    "TagSet": [
        {
            "Key": "openshiftClusterID",
            "Value": "f23dc729-9051-44e6-b844-ab3d76a42ed7"
        },
        {
            "Key": "expirationDate",
            "Value": "2019-02-23T05:39+0000"
        }
    ]
}
```
Therefore the destroy code is leaking registry s3 buckets. Adding the `openshiftClusterID` tag to AWS metadata back to make sure we don't
leak resources.

Installer tried to move to single tag for AWS clusters here [2].

[1]: https://github.com/openshift/cluster-image-registry-operator/blob/7228534c826c92dee38d578445c93f2537f0b775/pkg/storage/s3/s3.go#L288
[2]: openshift#1280
@openshift-ci-robot openshift-ci-robot removed the lgtm Indicates that a PR is ready to be merged. label Feb 23, 2019
@abhinavdahiya
Copy link
Contributor Author

New changes are detected. LGTM label has been removed.

identifier is a list of OR filters. @crawford can you lgtm again?

@crawford
Copy link
Contributor

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Feb 23, 2019
@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: abhinavdahiya, crawford

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [abhinavdahiya,crawford]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci-robot
Copy link
Contributor

openshift-ci-robot commented Feb 23, 2019

@abhinavdahiya: The following test failed for commit e6f09ba, say /retest to rerun them:

Test name Details Rerun command
ci/prow/e2e-aws link /test e2e-aws

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Details

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. I understand the commands that are listed here.

@abhinavdahiya
Copy link
Contributor Author

Failing tests:

[sig-instrumentation] Cadvisor should be healthy on every node. [Suite:openshift/conformance/parallel] [Suite:k8s]

#1298 (comment) seems to have passed after seeing similar error....
/retest

@deads2k
Copy link
Contributor

deads2k commented Feb 23, 2019

cadvisor appears to be a flake. the rest of e2e passed. We need this to stop the leak and keep CI up. merging.

@deads2k deads2k merged commit 8e8774c into openshift:master Feb 23, 2019
@wking
Copy link
Member

wking commented Feb 26, 2019

We also need this for the credentials operator, which is currently using tags like:

$ AWS_PROFILE=ci aws iam list-user-tags --user-name ci-op-vsvyv7x0-fd334-openshift-image-registry-ssc87
{
    "Tags": [
        {
            "Value": "bd56b83d-87fd-4119-ac33-2a26ac1ad064",
            "Key": "openshiftClusterID"
        },
        {
            "Value": "ci-op-vsvyv7x0-fd334",
            "Key": "openshiftClusterName"
        },
        {
            "Value": "owned",
            "Key": "kubernetes.io/cluster/bd56b83d-87fd-4119-ac33-2a26ac1ad064"
        },
        {
            "Value": "2019-02-26T12:35+0000",
            "Key": "expirationDate"
        }
    ],
    "IsTruncated": false
}

That's using the cluster ID in the kubernetes.io/cluster/... tag, while our destroy code expects the infra ID. We're currently successfully destroying these users because they match the openshiftClusterID tag restored by this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants