Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bpschmitt/crossplane-demo
A repo for testing and demoing Crossplane in K8s
https://github.com/bpschmitt/crossplane-demo
Last synced: 12 days ago
JSON representation
A repo for testing and demoing Crossplane in K8s
- Host: GitHub
- URL: https://github.com/bpschmitt/crossplane-demo
- Owner: bpschmitt
- License: apache-2.0
- Created: 2023-09-06T15:08:09.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-09-06T17:40:19.000Z (over 1 year ago)
- Last Synced: 2024-11-14T00:16:00.603Z (2 months ago)
- Language: HCL
- Size: 12.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# crossplane-demo
This repo contains a simple example showcasing how [Crossplane](https://www.crossplane.io/) can be used to manage New Relic alerts via Terraform.
# Prerequisites
- Minikube (or cluster of your choice)
- [Crossplane](https://docs.crossplane.io/v1.13/software/install/)# Setup
Rename the `./module/terraform.tfvars.json.example` file to `./module/terraform.tfvars.json` and modify the values. Then, create a Kubernetes Secret with the data.
```
kubectl create secret generic terraform --from-file=./module/terraform.tfvars.json
```Create the provider.
```
kubectl apply -f ./crossplane-config/provider.yaml
```Create the provider config.
```
kubectl apply -f ./crossplane-config/providerconfig.yaml
```Create the Terraform workspace.
```
kubectl apply -f ./crossplane-config/workspace-remote.yaml
```Validate that the workspace is ready and synced.
```
$ kubectl get workspaces
NAME READY SYNCED AGE
newrelic-alerts True True 11m
```# Validation
If successful, you should see the `Crossplane Demo` alert policy created in your New Relic account.
![alert condition](https://p191.p3.n0.cdn.getcloudapp.com/items/7KuXeXOj/d3e4c04a-084a-4f57-986f-227c2ba31958.jpg?v=0fac78c1954335a22f3222d8244e755b)