Skip to content

Commit

Permalink
finish adding ref and selector fields for all Grafana OnCall reso…
Browse files Browse the repository at this point in the history
…urces (#162)

* finish adding `ref` and `selector` fields for all Grafana OnCall resources

* WIP

* pr comment

* make generate output

* update escalation policy ref/selector names

* add some notes to README.md

* add more local dev notes to README + update apiVersion for package provider

* revert change to Provider
  • Loading branch information
joeyorlando authored Jun 18, 2024
1 parent f8b1427 commit 803d418
Show file tree
Hide file tree
Showing 9 changed files with 839 additions and 26 deletions.
48 changes: 48 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,54 @@ Build binary:
make build
```

### Installing Provider/CRDs into your local k8s cluster

1. Ensure Crossplane is installed on your local cluster (instructions [here](https://docs.crossplane.io/latest/software/install/))
2. Run the following:

```bash
kubectl config use-context <name-of-your-local-k8s-context>
kubectl apply -f ./package/crossplane.yaml
kubectl apply -f ./package/crds
```

### Possible issues when running locally

Below are some issues that have been encountered and may be helpful in the future
to others.

```bash
❯ make generate
14:35:30 [ .. ] generating provider schema for grafana/grafana 2.19.1
make[1]: *** [config/schema.json] Error 1
make: *** [generate] Error 2
```

**Solution**: ensure that you do not have a `.terraformrc` defined somewhere. For example
`~/.terraformrc`:

```bash
❯ cat ~/.terraformrc
provider_installation {
dev_overrides {
"grafana/grafana" = "/Users/joeyorlando/coding/grafana/terraform-provider-grafana"
}
}
```

Additionally, you can check the `terraform` logs via:

```bash
❯ cat ./.work/terraform/terraform-logs.txt
...
```

Lastly, make sure that you have the following defined in your `.bashrc` (or `.zshrc`):

```bash
export PATH="$PATH:$HOME/go/bin"
```

## Report a Bug

For filing bugs, suggesting improvements, or requesting new features, please
Expand Down
44 changes: 44 additions & 0 deletions apis/oncall/v1alpha1/zz_escalation_types.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

64 changes: 64 additions & 0 deletions apis/oncall/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

106 changes: 106 additions & 0 deletions apis/oncall/v1alpha1/zz_generated.resolvers.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 803d418

Please sign in to comment.