pipeline:
- functionRef:
name: crossplane-contrib-function-kcl
input:
apiVersion: template.fn.crossplane.io/v1beta1
kind: KCLInput
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import regex | |
oxr = option("params").oxr | |
_ocds = option("params").ocds | |
_dxr = option("params").dxr | |
dcds = option("params").dcds | |
_metadata = lambda name: str -> any { | |
{ annotations = { "krm.kcl.dev/composition-resource-name" = name }} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
This file was generated by the KCL auto-gen tool. DO NOT EDIT. | |
Editing this file might prove futile when you re-run the KCL auto-gen generate command. | |
""" | |
import k8s.apimachinery.pkg.apis.meta.v1 | |
schema Cluster: | |
r""" | |
Cluster is the Schema for the Clusters API. Manages an EKS Cluster |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -e | |
if [ ! -z "$DEBUG" ] ; then | |
set -x | |
fi | |
REGIONS="us-east-2 | |
us-east-1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
NAMESPACE=crossplane-system | |
# Define secret names |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- step: addon-keyvault-secrets-provider | |
functionRef: | |
name: crossplane-contrib-function-go-templating | |
input: | |
apiVersion: gotemplating.fn.crossplane.io/v1beta1 | |
kind: GoTemplate | |
source: Inline | |
inline: | |
template: | | |
{{ if and (ne $.observed.resources nil) }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: v1 | |
items: | |
- apiVersion: ec2.aws.upbound.io/v1beta1 | |
kind: SecurityGroup | |
metadata: | |
name: my-db-b9t8p-scfnc | |
spec: | |
forProvider: | |
description: Allow access to PostgreSQL | |
name: uxp-getting-started |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## get all managed resources | |
kubectl get managed -l crossplane.io/claim-name=test123 -o yaml >> export.yaml | |
## use only .items[] | |
cat export.yaml | yq e -P '.items' >> temp.yaml | |
## create individual files | |
yq '.[]' temp.yaml -s '"backup_" + .kind +"_"+ .metadata.name' | |
## add paused annotation | |
for file in backup* ; do yq eval '.metadata.annotations += {"crossplane.io/paused": "true"}' -i "$file"; done | |
## apply all files | |
kubectl apply --dry-run=client $(ls backup*.yml | awk ' { print " -f " $1 } ') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: escalation.pagerduty.crossplane.io/v1alpha1 | |
kind: Policy | |
metadata: | |
annotations: | |
meta.upbound.io/example-id: escalation/v1alpha1/policy | |
labels: | |
testing.upbound.io/example-name: example | |
name: example | |
spec: | |
forProvider: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
// Use IntelliSense to learn about possible attributes. | |
// Hover to view descriptions of existing attributes. | |
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"name": "Launch Package", | |
"type": "go", | |
"request": "launch", |
NewerOlder