diff --git a/build_package.sh b/build_package.sh index b22461c1169a998d9928ca900518818d224f1061..08c2d26523097f24594eb33765b87be12ea36460 100644 --- a/build_package.sh +++ b/build_package.sh @@ -1,4 +1,4 @@ # Builds the crossplane configuration package image and pushes it to EC gitlab -# VERSION=v0.3.8 +# VERSION=v0.3.9 crossplane xpkg build -f package/ -e package/examples/ -o configuration-${VERSION}.xpkg --verbose crossplane xpkg push code.europa.eu:4567/simpl/simpl-open/development/infrastructure/infrastructure-crossplane/configuration:${VERSION} -f configuration-${VERSION}.xpkg --domain https://code.europa.eu \ No newline at end of file diff --git a/charts/dependencies/values.yaml b/charts/dependencies/values.yaml index 59f403c6d937bd0ce5ae18b1b8730e346150ae3d..d0c50eddd295ce00bce0e67624cc526788f0cf5b 100644 --- a/charts/dependencies/values.yaml +++ b/charts/dependencies/values.yaml @@ -3,7 +3,7 @@ crossplane: - ec-pull-secret configuration: packages: - - code.europa.eu:4567/simpl/simpl-open/development/infrastructure/infrastructure-crossplane/configuration:v0.3.7 + - code.europa.eu:4567/simpl/simpl-open/development/infrastructure/infrastructure-crossplane/configuration:v0.3.9 gitea: # storageClassName: standard diff --git a/charts/resources/templates/crossplane/provider-ionos-config.yaml b/charts/resources/templates/crossplane/provider-ionos-config.yaml index 1d8795fc5a9e1f1131c6be3b48d3210e2c6ccb62..9a8d01159d8fc167403803186846acacb5a85524 100644 --- a/charts/resources/templates/crossplane/provider-ionos-config.yaml +++ b/charts/resources/templates/crossplane/provider-ionos-config.yaml @@ -2,7 +2,6 @@ apiVersion: ionoscloud.crossplane.io/v1alpha1 kind: ProviderConfig metadata: name: example - namespace: {{ .Release.Namespace }} spec: credentials: source: Secret diff --git a/charts/resources/values.yaml b/charts/resources/values.yaml index 5941d462ee643e22a414afa4c55611eab50caf86..476211566736ee0ab41a4f65ce9665c49d06db4f 100644 --- a/charts/resources/values.yaml +++ b/charts/resources/values.yaml @@ -7,4 +7,4 @@ kafkaEndpoint: kafka.infrastructure.dev.simpl-europe.eu:9092 kafkaAuth: enable: true mechanism: PLAIN - secretName: kafka-secret \ No newline at end of file + secretName: kafka-secret diff --git a/k8s/argocd-claim-manager.yaml b/k8s/argocd-claim-manager.yaml deleted file mode 100644 index 7e8154a2503bb87b77193f4810b3310d66236366..0000000000000000000000000000000000000000 --- a/k8s/argocd-claim-manager.yaml +++ /dev/null @@ -1,21 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Application -metadata: - name: claim-management - finalizers: - - resources-finalizer.argocd.argoproj.io -spec: - project: default - source: - repoURL: http://gitea-http.gitea.svc.cluster.local:3000/gitops_test/management-repo.git - path: applications - targetRevision: master - directory: - recurse: true - destination: - server: https://kubernetes.default.svc - syncPolicy: - automated: - selfHeal: true - prune: true - allowEmpty: true \ No newline at end of file diff --git a/k8s/crossplane-configuration.yaml b/k8s/crossplane-configuration.yaml deleted file mode 100644 index f488bf227ce1b8608a319a599a2020b2571a461e..0000000000000000000000000000000000000000 --- a/k8s/crossplane-configuration.yaml +++ /dev/null @@ -1,10 +0,0 @@ -apiVersion: pkg.crossplane.io/v1 -kind: Configuration -metadata: - name: demo -spec: - package: code.europa.eu:4567/simpl/simpl-open/development/infrastructure/infrastructure-crossplane/configuration:v0.3.3 - packagePullSecrets: - - name: ec-pull-secret - revisionHistoryLimit: 0 - packagePullPolicy: Always \ No newline at end of file diff --git a/k8s/debug.yaml b/k8s/debug.yaml deleted file mode 100644 index 83407aaf210e0425eda3ebdf19229e4ee8d2ec55..0000000000000000000000000000000000000000 --- a/k8s/debug.yaml +++ /dev/null @@ -1,44 +0,0 @@ -apiVersion: v1 -kind: Pod -metadata: - name: kafkacat - namespace: infrastructure -spec: - containers: - - name: kafkacat - image: confluentinc/cp-kafkacat - command: - - sleep - - "3600" - imagePullPolicy: Always - restartPolicy: Always ---- -apiVersion: v1 -kind: Pod -metadata: - name: nettools - namespace: infrastructure -spec: - containers: - - name: nettools - image: jrecord/nettools:latest - command: - - sleep - - "3600" - imagePullPolicy: Always - restartPolicy: Always ---- -apiVersion: v1 -kind: Pod -metadata: - name: alpinegit - namespace: infrastructure -spec: - containers: - - name: alpinegit - image: alpine/git:latest - command: - - sleep - - "3600" - imagePullPolicy: Always - restartPolicy: Always \ No newline at end of file diff --git a/k8s/events/decommission/sensor.yaml b/k8s/events/decommission/sensor.yaml deleted file mode 100644 index b4ebe68c0fedf8b234ce113834d2bfe39e3b0763..0000000000000000000000000000000000000000 --- a/k8s/events/decommission/sensor.yaml +++ /dev/null @@ -1,107 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Sensor -metadata: - name: to-decommission-wf - namespace: argoev -spec: - eventBusName: provisioner - template: - serviceAccountName: operate-workflow - dependencies: - - name: message - eventSourceName: kafka-to-decommission - eventName: decommissionRequest - triggers: - - template: - name: argo-workflow-trigger - argoWorkflow: - operation: submit - source: - resource: - apiVersion: argoproj.io/v1alpha1 - kind: Workflow - metadata: - generateName: workflow-gitops- - namespace: argowf - spec: - imagePullSecrets: - - name: ec-pull-secret - volumes: - - name: repos - emptyDir: {} - serviceAccountName: cli - entrypoint: main - workflowMetadata: - labels: - track-workflow: "true" - workflow-type: to-decommission - labelsFrom: - scriptTriggerId: - expression: workflow.parameters.scriptTriggerId - arguments: - parameters: - - name: scriptTriggerId - value: default-is-overriden - templates: - - name: main - inputs: - artifacts: - - name: data-repo - path: repos/data - git: - repo: http://gitea-http.gitea.svc.cluster.local:3000/gitops_test/data-repo.git - revision: "master" - - name: management-repo - path: /repos/management - git: - repo: http://gitea-http.gitea.svc.cluster.local:3000/gitops_test/management-repo.git - revision: "master" - parameters: - - name: scriptTriggerId - value: "'{{workflow.parameters.scriptTriggerId}}'" - script: - image: alpine/git:v2.45.2 - env: - - name: GIT_USER - valueFrom: - secretKeyRef: - name: gitea-secret - key: username - - name: GIT_PASSWORD - valueFrom: - secretKeyRef: - name: gitea-secret - key: password - command: [sh, -c] - args: [' - echo --- decommissioning request with ID: {{inputs.parameters.scriptTriggerId}}; - echo ---ls ../work---; - ls; - echo ---ls ../repos---; - ls ../repos; - git config --global user.email "workflow@argo.kube"; - git config --global user.name "gitops_test"; - echo ---commit data changes---; - git -C ../repos/data checkout master; - git -C ../repos/data rm -r claims/claim_{{inputs.parameters.scriptTriggerId}}; - git -C ../repos/data commit -v -m "Remove claim_{{inputs.parameters.scriptTriggerId}}"; - git -C ../repos/data push http://$GIT_USER:$GIT_PASSWORD@gitea-http.gitea.svc.cluster.local:3000/gitops_test/data-repo.git; - echo ---commit management changes---; - git -C ../repos/management checkout master; - git -C ../repos/management rm -r applications/application_{{inputs.parameters.scriptTriggerId}}; - git -C ../repos/management commit -v -m "Remove application_{{inputs.parameters.scriptTriggerId}}"; - git -C ../repos/management push http://$GIT_USER:$GIT_PASSWORD@gitea-http.gitea.svc.cluster.local:3000/gitops_test/management-repo.git; - '] - volumeMounts: - - name: repos - mountPath: /repos - workingDir: /work - parameters: - - src: - dependencyName: message - dataKey: headers.scriptTriggerId - value: "" - dest: spec.arguments.parameters.0.value - retryStrategy: - steps: 2 - duration: 30s \ No newline at end of file diff --git a/k8s/events/decommission/source.yaml b/k8s/events/decommission/source.yaml deleted file mode 100644 index 4dcd5cd5ef26ec4195d4987669f57903987e3899..0000000000000000000000000000000000000000 --- a/k8s/events/decommission/source.yaml +++ /dev/null @@ -1,18 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: EventSource -metadata: - name: kafka-to-decommission - namespace: argoev -spec: - eventBusName: provisioner - kafka: - decommissionRequest: - url: {{ .Values.kafkaEndpoint }} - topic: to-decommission - jsonBody: false - partition: "0" - connectionBackoff: - duration: 10s - steps: 3 - factor: 1 - jitter: 0.2 \ No newline at end of file diff --git a/k8s/events/decommission/status-emitter.yaml b/k8s/events/decommission/status-emitter.yaml deleted file mode 100644 index 7ab6b17737ffa2292f17d88d97fea2ea899bb605..0000000000000000000000000000000000000000 --- a/k8s/events/decommission/status-emitter.yaml +++ /dev/null @@ -1,32 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Sensor -metadata: - name: decommission-status-emitter - namespace: argoev -spec: - eventBusName: provisioner - dependencies: - - name: message - eventSourceName: decommission-status-tracker - eventName: decommissionStatus - triggers: - - template: - name: kafka - kafka: - url: {{ .Values.kafkaEndpoint }} - topic: decommissioned - payload: - - src: - dependencyName: message - dataKey: body.metadata.labels.claim-uuid - value: "" - dest: scriptTriggerId - - src: - dependencyName: message - value: "Succeeded" - dest: status - - src: - dependencyName: message - dataKey: body.metadata.deletionTimestamp - value: "" - dest: deletionTimestamp \ No newline at end of file diff --git a/k8s/events/decommission/status-source.yaml b/k8s/events/decommission/status-source.yaml deleted file mode 100644 index e9f3eda0976174ff608bf3690af7922c76147858..0000000000000000000000000000000000000000 --- a/k8s/events/decommission/status-source.yaml +++ /dev/null @@ -1,24 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: EventSource -metadata: - name: decommission-status-tracker - namespace: argoev -spec: - eventBusName: provisioner - template: - serviceAccountName: claim-application-status - resource: - decommissionStatus: - namespace: argocd - group: argoproj.io - version: v1alpha1 - resource: applications - eventTypes: - - DELETE - filter: - afterStart: true - labels: - - key: track-events - operation: "==" - value: "claim-application" - diff --git a/k8s/events/eventbus.yaml b/k8s/events/eventbus.yaml deleted file mode 100644 index 7ed73ad67a0cd130e5e24a6b5c097e77f9f87319..0000000000000000000000000000000000000000 --- a/k8s/events/eventbus.yaml +++ /dev/null @@ -1,10 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: EventBus -metadata: - name: provisioner - namespace: argoev -spec: - nats: - native: - replicas: 2 - auth: token diff --git a/k8s/events/provision/sensor.yaml b/k8s/events/provision/sensor.yaml deleted file mode 100644 index 1aeafa660210d1488c23cd12f09b8dcb25f8ad4e..0000000000000000000000000000000000000000 --- a/k8s/events/provision/sensor.yaml +++ /dev/null @@ -1,123 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Sensor -metadata: - name: to-provision-wf - namespace: argoev -spec: - eventBusName: provisioner - template: - serviceAccountName: operate-workflow - dependencies: - - name: message - eventSourceName: kafka-to-provision - eventName: provisionRequest - triggers: - - template: - name: argo-workflow-trigger - argoWorkflow: - operation: submit - source: - resource: - apiVersion: argoproj.io/v1alpha1 - kind: Workflow - metadata: - generateName: workflow-gitops- - namespace: argowf - spec: - imagePullSecrets: - - name: ec-pull-secret - volumes: - - name: repos - emptyDir: {} - serviceAccountName: cli - entrypoint: main - workflowMetadata: - labels: - track-workflow: "true" - workflow-type: to-provision - labelsFrom: - scriptTriggerId: - expression: workflow.parameters.scriptTriggerId - arguments: - parameters: - - name: headers - value: default-is-overriden - - name: scriptTriggerId - value: default-is-overriden - - name: body - value: default-is-overriden - templates: - - name: main - inputs: - artifacts: - - name: data-repo - path: repos/data - git: - repo: http://gitea-http.gitea.svc.cluster.local:3000/gitops_test/data-repo.git - revision: "master" - - name: management-repo - path: /repos/management - git: - repo: http://gitea-http.gitea.svc.cluster.local:3000/gitops_test/management-repo.git - revision: "master" - parameters: - - name: headers - value: "'{{workflow.parameters.headers}}'" - - name: scriptTriggerId - value: "'{{workflow.parameters.scriptTriggerId}}'" - - name: body - value: "'{{workflow.parameters.body}}'" - container: - image: code.europa.eu:4567/simpl/simpl-open/development/infrastructure/infrastructure-crossplane/to-provision-workflow:v0.2.1 - env: - - name: GIT_USER - valueFrom: - secretKeyRef: - name: gitea-secret - key: username - - name: GIT_PASSWORD - valueFrom: - secretKeyRef: - name: gitea-secret - key: password - command: [sh, -c] - args: [' - echo --- provisioning request with ID: {{inputs.parameters.scriptTriggerId}}; - echo ---ls ../work---; - ls; - echo ---ls ../repos---; - ls ../repos; - python doesntexist.py; - python main.py {{inputs.parameters.scriptTriggerId}} {{inputs.parameters.body}} || exit $?; - git config --global user.email "workflow@argo.kube"; - git config --global user.name "gitops_test"; - echo ---commit data changes---; - git -C ../repos/data checkout master; - git -C ../repos/data/claims add -A && git -C ../repos/data commit -m "add UUID {{inputs.parameters.scriptTriggerId}}"; - git -C ../repos/data push http://$GIT_USER:$GIT_PASSWORD@gitea-http.gitea.svc.cluster.local:3000/gitops_test/data-repo.git; - echo ---commit management changes---; - git -C ../repos/management checkout master; - git -C ../repos/management/applications add -A && git -C ../repos/management commit -m "add UUID {{inputs.parameters.scriptTriggerId}}"; - git -C ../repos/management push http://$GIT_USER:$GIT_PASSWORD@gitea-http.gitea.svc.cluster.local:3000/gitops_test/management-repo.git; - '] - volumeMounts: - - name: repos - mountPath: /repos - workingDir: /work - parameters: - - src: - dependencyName: message - dataKey: headers - dest: spec.arguments.parameters.0.value - - src: - dependencyName: message - dataKey: headers.scriptTriggerId - value: dummy - dest: spec.arguments.parameters.1.value - - src: - dependencyName: message - dataKey: body - dest: spec.arguments.parameters.2.value - retryStrategy: - steps: 2 - duration: 30s \ No newline at end of file diff --git a/k8s/events/provision/source.yaml b/k8s/events/provision/source.yaml deleted file mode 100644 index 26ea9cbc3567be863e33a06a5246ec7b76aee4e4..0000000000000000000000000000000000000000 --- a/k8s/events/provision/source.yaml +++ /dev/null @@ -1,18 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: EventSource -metadata: - name: kafka-to-provision - namespace: argoev -spec: - eventBusName: provisioner - kafka: - provisionRequest: - url: {{ .Values.kafkaEndpoint }} - topic: to-provision - jsonBody: false - partition: "0" - connectionBackoff: - duration: 10s - steps: 3 - factor: 1 - jitter: 0.2 \ No newline at end of file diff --git a/k8s/events/provision/status-emitter.yaml b/k8s/events/provision/status-emitter.yaml deleted file mode 100644 index 65fd351f3d1c7618a83250ddb8e5e1f097077d6f..0000000000000000000000000000000000000000 --- a/k8s/events/provision/status-emitter.yaml +++ /dev/null @@ -1,44 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Sensor -metadata: - name: to-provision-wf-status-emitter - namespace: argoev -spec: - eventBusName: provisioner - dependencies: - - name: wf-status - eventSourceName: to-provision-wf-status-tracker - eventName: toProvisionWorkflow - triggers: - - template: - name: kafka - kafka: - url: {{ .Values.kafkaEndpoint }} - topic: provisioned - partition: 0 - payload: - - src: - dependencyName: wf-status - dataKey: body.metadata.name - value: "None" - dest: name - - src: - dependencyName: wf-status - dataKey: "body.metadata.labels.workflows\\.argoproj\\.io/phase" - value: "Unknown" - dest: phase - - src: - dependencyName: wf-status - dataKey: "body.metadata.labels.workflows\\.argoproj\\.io/completed" - value: "false" - dest: completed - - src: - dependencyName: wf-status - dataKey: "body.metadata.labels.scriptTriggerId" - value: "" - dest: scriptTriggerId - - src: - dependencyName: wf-status - dataKey: body.status.message - value: "" - dest: message \ No newline at end of file diff --git a/k8s/events/provision/status-source.yaml b/k8s/events/provision/status-source.yaml deleted file mode 100644 index f95be3aabf2576e856e33b9e96fbbd84d660f889..0000000000000000000000000000000000000000 --- a/k8s/events/provision/status-source.yaml +++ /dev/null @@ -1,27 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: EventSource -metadata: - name: claim-application-status-tracker - namespace: argoev -spec: - eventBusName: provisioner - template: - serviceAccountName: claim-application-status - resource: - claimApplicationStatus: - namespace: argocd - group: argoproj.io - version: v1alpha1 - resource: applications - eventTypes: - - UPDATE - filter: - afterStart: true - labels: - - key: track-events - operation: "==" - value: "claim-application" - - key: provisioning-status - operation: "!=" - value: "finalized" - diff --git a/k8s/events/provision/workflow-status-sensor.yaml b/k8s/events/provision/workflow-status-sensor.yaml deleted file mode 100644 index 75b9b988f4ccf69116958925422018af762f2587..0000000000000000000000000000000000000000 --- a/k8s/events/provision/workflow-status-sensor.yaml +++ /dev/null @@ -1,175 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: Sensor -metadata: - name: claim-application-status-wf - namespace: argoev -spec: - eventBusName: provisioner - template: - serviceAccountName: operate-workflow - dependencies: - - name: message - eventSourceName: claim-application-status-tracker - eventName: claimApplicationStatus - triggers: - - template: - name: argo-workflow-trigger - argoWorkflow: - operation: submit - source: - resource: - apiVersion: argoproj.io/v1alpha1 - kind: Workflow - metadata: - generateName: workflow-claim-application-status - namespace: argowf - spec: - serviceAccountName: cli - entrypoint: main - workflowMetadata: - arguments: - parameters: - - name: body - value: default-is-overriden - templates: - - name: main - steps: - - - name: validate - template: validate-status - arguments: - parameters: - - name: message - value: "{{workflow.parameters.body}}" - - - name: label - template: done-label - arguments: - parameters: - - name: UUID - value: "{{steps.validate.outputs.result}}" - - - name: parse-application - template: parse-application - arguments: - parameters: - - name: resource - value: "{{steps.label.outputs.parameters.application-resource}}" - - - name: parse-claim - template: parse-claim - arguments: - parameters: - - name: claim-reference - value: "{{steps.parse-application.outputs.result}}" - - - name: payload - template: payload - arguments: - parameters: - - name: resource - value: "{{steps.parse-claim.outputs.parameters.claim-resource}}" - - - name: message - template: message - arguments: - parameters: - - name: payload - value: "{{steps.payload.outputs.result}}" - - name: validate-status - inputs: - parameters: - - name: message - script: - image: python:alpine3.10 - command: [python] - source: | - import json - rawstr = r'''{{inputs.parameters.message}}''' - d = json.loads(rawstr) - try: - app_status = d['status'] - app_meta = d['metadata'] - app_health = app_status['health']['status'] - app_sync = app_status['sync']['status'] - # Application only tracks the Claim, so one resource should be present - claim = app_status['resources'][0] - claim_health = claim['health']['status'] - claim_sync = claim['status'] - claim_id = app_meta['labels']['claim-uuid'] - assert app_health == "Healthy" and claim_health == "Healthy" and app_sync == "Synced" and claim_sync == "Synced" - print(f"{claim_id}") - except (KeyError, IndexError): - raise ValueError("Not all status fields available") - - name: done-label - inputs: - parameters: - - name: UUID - script: - image: bitnami/kubectl:latest - command: [sh] - source: | - echo "patching application with label claim-uuid:{{inputs.parameters.UUID}}" - kubectl label -n argocd applications crossplane-claim-{{inputs.parameters.UUID}} provisioning-status="finalized" - kubectl get -n argocd applications --selector=claim-uuid={{inputs.parameters.UUID}} -o json > /tmp/resource.json - outputs: - parameters: - - name: application-resource - valueFrom: - path: /tmp/resource.json - - name: parse-application - inputs: - parameters: - - name: resource - script: - image: python:alpine3.10 - command: [python] - source: | - import json - rawstr = r'''{{inputs.parameters.resource}}''' - d = json.loads(rawstr) - claim_kind = d['items'][0]['metadata']['labels']['claim-kind'] - claim_selector = d['items'][0]['metadata']['labels']['claim-uuid'] - print(f"{claim_kind} --selector=uuid={claim_selector}") - - name: parse-claim - inputs: - parameters: - - name: claim-reference - script: - image: bitnami/kubectl:latest - command: [sh] - source: | - kubectl get -n crossplane-system {{inputs.parameters.claim-reference}} - kubectl get -n crossplane-system -o json {{inputs.parameters.claim-reference}} > /tmp/resource.json - outputs: - parameters: - - name: claim-resource - valueFrom: - path: /tmp/resource.json - - name: payload - inputs: - parameters: - - name: resource - script: - image: python:alpine3.10 - command: [python] - source: | - import json - rawstr = r'''{{inputs.parameters.resource}}''' - d = json.loads(rawstr) - payload = {} - payload["vmIps"] = d["items"][0]["status"]["vmIps"] - payload["status"] = "Provisioning finalized successfully" - payload["scriptTriggerId"] = d["items"][0]["metadata"]["labels"]["uuid"] - print(json.dumps(payload).replace('"', '\\"')) - - name: message - inputs: - parameters: - - name: payload - script: - image: confluentinc/cp-kafkacat:7.1.14 - command: [sh] - source: | - echo {{inputs.parameters.payload}} | kafkacat -P -b {{ .Values.kafkaEndpoint }} -t provisioned -J - parameters: - - src: - dependencyName: message - dataKey: body - dest: spec.arguments.parameters.0.value - retryStrategy: - steps: 2 - duration: 30s \ No newline at end of file diff --git a/k8s/events/provision/workflow-status-source.yaml b/k8s/events/provision/workflow-status-source.yaml deleted file mode 100644 index 86441f1dd666c346d5470d9dc90917c7f6459d9c..0000000000000000000000000000000000000000 --- a/k8s/events/provision/workflow-status-source.yaml +++ /dev/null @@ -1,27 +0,0 @@ -apiVersion: argoproj.io/v1alpha1 -kind: EventSource -metadata: - name: to-provision-wf-status-tracker - namespace: argoev -spec: - eventBusName: provisioner - template: - serviceAccountName: operate-workflow - resource: - toProvisionWorkflow: - namespace: argowf - group: argoproj.io - version: v1alpha1 - resource: workflows - eventTypes: - - ADD - - UPDATE - filter: - afterStart: true - labels: - - key: track-workflow - operation: "==" - value: "true" - - key: workflow-type - operation: "==" - value: to-provision diff --git a/k8s/provider-ionos-configuration.yaml b/k8s/provider-ionos-configuration.yaml deleted file mode 100644 index e4eda6e78fbb316c3c6f3de33ca959c496dbea1e..0000000000000000000000000000000000000000 --- a/k8s/provider-ionos-configuration.yaml +++ /dev/null @@ -1,12 +0,0 @@ -apiVersion: ionoscloud.crossplane.io/v1alpha1 -kind: ProviderConfig -metadata: - name: example - namespace: crossplane-system -spec: - credentials: - source: Secret - secretRef: - namespace: crossplane-system - name: ionos-provider - key: credentials diff --git a/k8s/rbac/argocd-application-rbac.yaml b/k8s/rbac/argocd-application-rbac.yaml deleted file mode 100644 index 8a7c71fc9a5661d1b71f87fc1cddfce68caa574f..0000000000000000000000000000000000000000 --- a/k8s/rbac/argocd-application-rbac.yaml +++ /dev/null @@ -1,62 +0,0 @@ -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: view-application - namespace: argocd -rules: - - apiGroups: - - argoproj.io - resources: - - applications - verbs: - - list - - get - - watch ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: view-application - namespace: argocd -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: view-application -subjects: -- kind: ServiceAccount - name: claim-application-status - namespace: argoev -- kind: ServiceAccount - name: operate-workflow - namespace: argoev -- kind: ServiceAccount - name: cli - namespace: argowf - ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: Role -metadata: - name: patch-application - namespace: argocd -rules: - - apiGroups: - - argoproj.io - resources: - - applications - verbs: - - patch ---- -apiVersion: rbac.authorization.k8s.io/v1 -kind: RoleBinding -metadata: - name: patch-application - namespace: argocd -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: Role - name: patch-application -subjects: -- kind: ServiceAccount - name: cli - namespace: argowf diff --git a/k8s/rbac/crossplane-composites.yaml b/k8s/rbac/crossplane-composites.yaml deleted file mode 100644 index 4c80c05587417b72fa791491d8ae1ae52637b85d..0000000000000000000000000000000000000000 --- a/k8s/rbac/crossplane-composites.yaml +++ /dev/null @@ -1,15 +0,0 @@ -apiVersion: rbac.authorization.k8s.io/v1 -kind: ClusterRoleBinding -metadata: - name: view-composite-status-events -roleRef: - apiGroup: rbac.authorization.k8s.io - kind: ClusterRole - name: crossplane-view -subjects: - - kind: ServiceAccount - name: composite-status - namespace: argoev - - kind: ServiceAccount - name: cli - namespace: argowf \ No newline at end of file diff --git a/k8s/workflows/cli-token.yaml b/k8s/workflows/cli-token.yaml deleted file mode 100644 index 5aabb14b129585b8b9e8869711943c16d9fa5299..0000000000000000000000000000000000000000 --- a/k8s/workflows/cli-token.yaml +++ /dev/null @@ -1,7 +0,0 @@ -apiVersion: v1 -kind: Secret -metadata: - name: argocli.service-account-token - annotations: - kubernetes.io/service-account.name: argocli -type: kubernetes.io/service-account-token \ No newline at end of file diff --git a/package/apis/demo/definition.yaml b/package/apis/demo/definition.yaml index 6de7c2ee9badbbc23e62178da18963dc1a23b0e4..bb15d9a4c63c4e7e6de3981f95f37e211615b6c7 100644 --- a/package/apis/demo/definition.yaml +++ b/package/apis/demo/definition.yaml @@ -64,7 +64,7 @@ spec: type: array items: type: string - minItems: 2 + minItems: 1 maxItems: 2 datacenterId: type: string diff --git a/package/apis/demo/ionos.yaml b/package/apis/demo/ionos.yaml index 81eb6c810b3d3873f594afe7bd48d5b6e05a0fea..32540260409e43b07acdde5f517bf0ec3e494bd5 100644 --- a/package/apis/demo/ionos.yaml +++ b/package/apis/demo/ionos.yaml @@ -6,7 +6,6 @@ metadata: crossplane.io/xrd: xserversinstances.platform.example.org provider: ionoscloud spec: - writeConnectionSecretsToNamespace: infrastructure compositeTypeRef: apiVersion: platform.example.org/v1alpha1 kind: XServerInstance @@ -113,7 +112,7 @@ spec: spec: forProvider: name: ipblock1 - size: 2 + size: 1 location: us/las providerConfigRef: name: example @@ -138,7 +137,6 @@ spec: ipsConfigs: ips: - 0.0.0.0 - - 0.0.0.0 datacenterConfig: datacenterIdRef: name: datacenter