Skip to content

fix: Update CRDs after API changes #264

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

Merged
merged 1 commit into from
May 14, 2021

Conversation

Demonsthere
Copy link
Collaborator

@Demonsthere Demonsthere commented May 13, 2021

Related issue

Proposed changes

Update CRDs in charts to be in line with the current controllers

Checklist

  • I have read the contributing guidelines
    and signed the CLA.
  • I have read the security policy.
  • I confirm that this pull request does not address a security
    vulnerability. If this pull request addresses a security vulnerability, I
    confirm that I got green light (please contact
    security@ory.sh) from the maintainers to push
    the changes.
  • I have added tests that prove my fix is effective or that my feature
    works.
  • I have added necessary documentation within the code base (if
    appropriate).

Further comments

@Demonsthere Demonsthere marked this pull request as draft May 13, 2021 14:19
@Demonsthere Demonsthere marked this pull request as ready for review May 13, 2021 14:30
@Demonsthere
Copy link
Collaborator Author

Sample rules created after updating CRDs:

apiVersion: v1
data:
  access-rules.json: |-
    [
      {
        "upstream": {
          "url": "http://abc.ef",
          "preserve_host": false
        },
        "id": "sample-rule-handlers-1.default",
        "match": {
          "url": "<http|https>://foo.bar",
          "methods": [
            "GET"
          ]
        },
        "authenticators": [
          {
            "handler": "anonymous",
            "config": {
              "foo": "bar",
              "long": "{\n  \"bar\": \"foo\"\n}\n"
            }
          }
        ],
        "authorizer": {
          "handler": "allow",
          "config": {
            "answer": 42,
            "lorem": "ipsum"
          }
        },
        "mutators": [
          {
            "handler": "noop",
            "config": {}
          },
          {
            "handler": "id_token",
            "config": {
              "claims": "{\n  \"aud\": [ \"hub.animeapis.dev\" ],\n  \"session\": {{ .Extra | toJson }}\n}\n",
              "ttl": "3600s"
            }
          }
        ],
        "configMapName": "handlers-test-cm"
      },
      {
        "upstream": {
          "url": "",
          "preserve_host": false
        },
        "id": "sample-rule-handlers-2.default",
        "match": {
          "url": "<{https,http}>://hub.foobar.dev/<**>",
          "methods": [
            "GET",
            "POST",
            "PUT",
            "DELETE",
            "OPTIONS",
            "HEAD"
          ]
        },
        "authenticators": [
          {
            "handler": "anonymous"
          },
          {
            "handler": "cookie_session"
          }
        ],
        "authorizer": {
          "handler": "allow"
        },
        "mutators": [
          {
            "handler": "id_token",
            "config": {
              "claims": "{\n  \"aud\": [ \"hub.animeapis.dev\" ],\n  \"session\": {{ .Extra | toJson }}\n}\n",
              "ttl": "3600s"
            }
          }
        ],
        "configMapName": "handlers-test-cm"
      }
    ]
kind: ConfigMap
metadata:
  creationTimestamp: "2021-05-13T14:28:27Z"
  name: handlers-test-cm
  namespace: default
  resourceVersion: "689"
  uid: 674d7310-1955-47d7-8305-8f0554743430

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Handlers "config" attribute is replaced by an empty object
2 participants