Skip to content

Commit

Permalink
remove duplicate entries
Browse files Browse the repository at this point in the history
Signed-off-by: Sebastian Hoß <[email protected]>
  • Loading branch information
sebhoss committed Nov 17, 2023
1 parent 8623d39 commit 37dcee5
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 30 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,29 @@ yq --inplace "del(${properties}.remoteWrite.items.properties.writeRelabelConfigs

yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.role.enum[] | select(. == \"node\"))" \
"${project}/scrapeconfigs.yaml"
yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.role.enum[] | select(. == \"service\"))" \
"${project}/scrapeconfigs.yaml"
yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.role.enum[] | select(. == \"pod\"))" \
"${project}/scrapeconfigs.yaml"
yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.role.enum[] | select(. == \"endpoints\"))" \
"${project}/scrapeconfigs.yaml"
yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.role.enum[] | select(. == \"endpointslice\"))" \
"${project}/scrapeconfigs.yaml"
yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.role.enum[] | select(. == \"ingress\"))" \
"${project}/scrapeconfigs.yaml"

yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.selectors.items.properties.role.enum[] | select(. == \"node\"))" \
"${project}/scrapeconfigs.yaml"
yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.selectors.items.properties.role.enum[] | select(. == \"service\"))" \
"${project}/scrapeconfigs.yaml"
yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.selectors.items.properties.role.enum[] | select(. == \"pod\"))" \
"${project}/scrapeconfigs.yaml"
yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.selectors.items.properties.role.enum[] | select(. == \"endpoints\"))" \
"${project}/scrapeconfigs.yaml"
yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.selectors.items.properties.role.enum[] | select(. == \"endpointslice\"))" \
"${project}/scrapeconfigs.yaml"
yq --inplace "del(${properties}.kubernetesSDConfigs.items.properties.selectors.items.properties.role.enum[] | select(. == \"ingress\"))" \
"${project}/scrapeconfigs.yaml"

yq --inplace "del(${properties}.metricRelabelings.items.properties.action.enum[] | select(. == \"replace\"))" \
"${project}/scrapeconfigs.yaml"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -829,15 +829,10 @@ spec:
enum:
- Node
- Service
- service
- Pod
- pod
- Endpoints
- endpoints
- EndpointSlice
- endpointslice
- Ingress
- ingress
type: string
selectors:
description: Selector to select objects.
Expand All @@ -853,15 +848,10 @@ spec:
enum:
- Node
- Service
- service
- Pod
- pod
- Endpoints
- endpoints
- EndpointSlice
- endpointslice
- Ingress
- ingress
type: string
required:
- role
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -881,19 +881,9 @@ pub struct ScrapeConfigKubernetesSdConfigs {
pub enum ScrapeConfigKubernetesSdConfigsRole {
Node,
Service,
#[serde(rename = "service")]
Service,
Pod,
#[serde(rename = "pod")]
Pod,
Endpoints,
#[serde(rename = "endpoints")]
Endpoints,
EndpointSlice,
#[serde(rename = "endpointslice")]
Endpointslice,
Ingress,
#[serde(rename = "ingress")]
Ingress,
}

Expand All @@ -913,19 +903,9 @@ pub struct ScrapeConfigKubernetesSdConfigsSelectors {
pub enum ScrapeConfigKubernetesSdConfigsSelectorsRole {
Node,
Service,
#[serde(rename = "service")]
Service,
Pod,
#[serde(rename = "pod")]
Pod,
Endpoints,
#[serde(rename = "endpoints")]
Endpoints,
EndpointSlice,
#[serde(rename = "endpointslice")]
Endpointslice,
Ingress,
#[serde(rename = "ingress")]
Ingress,
}

Expand Down

0 comments on commit 37dcee5

Please sign in to comment.