Skip to content

Commit

Permalink
run linter and update resources
Browse files Browse the repository at this point in the history
  • Loading branch information
pb82 committed May 17, 2023
1 parent 5693ba5 commit b494b84
Show file tree
Hide file tree
Showing 3 changed files with 157 additions and 5 deletions.
3 changes: 2 additions & 1 deletion api/v1beta1/grafanadatasource_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,10 @@ import (
"encoding/json"
"errors"
"fmt"
v1 "k8s.io/api/core/v1"
"time"

v1 "k8s.io/api/core/v1"

metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
)

Expand Down
3 changes: 2 additions & 1 deletion controllers/datasource_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@ import (
"context"
"encoding/json"
"fmt"
v1 "k8s.io/api/core/v1"
"strings"
"time"

v1 "k8s.io/api/core/v1"

simplejson "github.com/bitly/go-simplejson"
"github.com/grafana-operator/grafana-operator/v5/controllers/metrics"

Expand Down
156 changes: 153 additions & 3 deletions docs/docs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -539,10 +539,10 @@ GrafanaDatasourceSpec defines the desired state of GrafanaDatasource
</td>
<td>false</td>
</tr><tr>
<td><b>secrets</b></td>
<td>[]string</td>
<td><b><a href="grafanadatasourcespecvaluesfromindex">valuesFrom</a></b></td>
<td>[]object</td>
<td>
secrets used for variable expansion<br/>
environments variables from secrets or config maps<br/>
</td>
<td>false</td>
</tr></tbody>
Expand Down Expand Up @@ -778,6 +778,156 @@ A label selector requirement is a selector that contains values, a key, and an o
</table>


### GrafanaDatasource.spec.valuesFrom[index]
<sup><sup>[↩ Parent](grafanadatasourcespec)</sup></sup>





<table>
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Description</th>
<th>Required</th>
</tr>
</thead>
<tbody><tr>
<td><b>targetPath</b></td>
<td>string</td>
<td>
<br/>
</td>
<td>true</td>
</tr><tr>
<td><b><a href="grafanadatasourcespecvaluesfromindexvaluefrom">valueFrom</a></b></td>
<td>object</td>
<td>
<br/>
</td>
<td>true</td>
</tr></tbody>
</table>


### GrafanaDatasource.spec.valuesFrom[index].valueFrom
<sup><sup>[↩ Parent](grafanadatasourcespecvaluesfromindex)</sup></sup>





<table>
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Description</th>
<th>Required</th>
</tr>
</thead>
<tbody><tr>
<td><b><a href="grafanadatasourcespecvaluesfromindexvaluefromconfigmapkeyref">configMapKeyRef</a></b></td>
<td>object</td>
<td>
Selects a key of a ConfigMap.<br/>
</td>
<td>false</td>
</tr><tr>
<td><b><a href="grafanadatasourcespecvaluesfromindexvaluefromsecretkeyref">secretKeyRef</a></b></td>
<td>object</td>
<td>
Selects a key of a Secret.<br/>
</td>
<td>false</td>
</tr></tbody>
</table>


### GrafanaDatasource.spec.valuesFrom[index].valueFrom.configMapKeyRef
<sup><sup>[↩ Parent](grafanadatasourcespecvaluesfromindexvaluefrom)</sup></sup>



Selects a key of a ConfigMap.

<table>
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Description</th>
<th>Required</th>
</tr>
</thead>
<tbody><tr>
<td><b>key</b></td>
<td>string</td>
<td>
The key to select.<br/>
</td>
<td>true</td>
</tr><tr>
<td><b>name</b></td>
<td>string</td>
<td>
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?<br/>
</td>
<td>false</td>
</tr><tr>
<td><b>optional</b></td>
<td>boolean</td>
<td>
Specify whether the ConfigMap or its key must be defined<br/>
</td>
<td>false</td>
</tr></tbody>
</table>


### GrafanaDatasource.spec.valuesFrom[index].valueFrom.secretKeyRef
<sup><sup>[↩ Parent](grafanadatasourcespecvaluesfromindexvaluefrom)</sup></sup>



Selects a key of a Secret.

<table>
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Description</th>
<th>Required</th>
</tr>
</thead>
<tbody><tr>
<td><b>key</b></td>
<td>string</td>
<td>
The key of the secret to select from. Must be a valid secret key.<br/>
</td>
<td>true</td>
</tr><tr>
<td><b>name</b></td>
<td>string</td>
<td>
Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names TODO: Add other useful fields. apiVersion, kind, uid?<br/>
</td>
<td>false</td>
</tr><tr>
<td><b>optional</b></td>
<td>boolean</td>
<td>
Specify whether the Secret or its key must be defined<br/>
</td>
<td>false</td>
</tr></tbody>
</table>


### GrafanaDatasource.status
<sup><sup>[↩ Parent](grafanadatasource)</sup></sup>

Expand Down

0 comments on commit b494b84

Please sign in to comment.