Skip to content

Commit d8fcff6

Browse files
committed
github: OLM
Signed-off-by: Feruzjon Muyassarov <[email protected]>
1 parent e13c3b8 commit d8fcff6

12 files changed

+2895
-0
lines changed

.github/workflows/publish-olm.yaml

+67
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
name: Publish a release
2+
3+
on:
4+
push:
5+
tags:
6+
- '*' # Triggers on any tag creation
7+
8+
jobs:
9+
update:
10+
name: Publish new OperatorHub release
11+
runs-on: ubuntu-22.04
12+
steps:
13+
14+
- name: Get the release tag
15+
run: echo ${GITHUB_REF##*/}
16+
17+
- name: Get the release tag
18+
run: echo "VERSION=${GITHUB_REF##*/}" >> $GITHUB_OUTPUT
19+
20+
- name: Checkout
21+
uses: actions/checkout@v4
22+
with:
23+
fetch-depth: 0
24+
25+
- name: Run make bundle
26+
run: pushd deployment/operator && ls -lah && pwd && popd
27+
28+
- name: Checkout tools repo
29+
uses: actions/checkout@v4
30+
with:
31+
repository: fmuyassarov/operator-demo
32+
path: operator-demo
33+
ref: main
34+
token: ${{ secrets.MACHINE_PAT }}
35+
36+
- name: Import GPG key
37+
uses: crazy-max/ghaction-import-gpg@v6
38+
id: import-gpg
39+
with:
40+
gpg_private_key: ${{ secrets.MACHINE_GPG_PRIVATE_KEY }}
41+
passphrase: ${{ secrets.MACHINE_PASSPHRASE }}
42+
git_user_signingkey: true
43+
git_commit_gpgsign: true
44+
workdir: operator-demo
45+
46+
- name: Make changes to pull request
47+
run: date +%s > operator-demo/report.txt
48+
49+
- name: Run pwd
50+
run: cd && cd work/nri-plugins && ls -lah
51+
# && cp nri-plugins/Tiltfile operator-demo/ && ls -lah operator-demo/
52+
53+
- name: Create Pull Request
54+
uses: peter-evans/create-pull-request@v6
55+
with:
56+
signoff: true
57+
committer: "Github Actions <${{ steps.import-gpg.outputs.email }}>"
58+
path: operator-demo
59+
push-to-fork: nri-plugins-bot/operator-demo
60+
branch: olm-${{ github.ref_name }}
61+
token: ${{ secrets.MACHINE_PAT }}
62+
delete-branch: false
63+
title: 'operator nri-plugins-operator ${{ github.ref_name }}'
64+
commit-message: 'Submit operator nri-plugins-operator ${{ github.ref_name }}'
65+
body: |
66+
Added OLM bundle for [nri-plugins operator ${{ github.ref_name }}](https://github.com/containers/nri-plugins/releases/tag/${{ github.ref_name }})
67+
> Auto-generated by `Github Actions Bot`

deployment/operator/config/crd/bases/config.nri_balloonspolicies.yaml

+561
Large diffs are not rendered by default.

deployment/operator/config/crd/bases/config.nri_nriplugindeployments.yaml

+1,061
Large diffs are not rendered by default.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,250 @@
1+
---
2+
apiVersion: apiextensions.k8s.io/v1
3+
kind: CustomResourceDefinition
4+
metadata:
5+
annotations:
6+
controller-gen.kubebuilder.io/version: v0.16.5
7+
name: templatepolicies.config.nri
8+
spec:
9+
group: config.nri
10+
names:
11+
kind: TemplatePolicy
12+
listKind: TemplatePolicyList
13+
plural: templatepolicies
14+
singular: templatepolicy
15+
scope: Namespaced
16+
versions:
17+
- name: v1alpha1
18+
schema:
19+
openAPIV3Schema:
20+
description: TemplatePolicy represents the configuration for the template
21+
policy.
22+
properties:
23+
apiVersion:
24+
description: |-
25+
APIVersion defines the versioned schema of this representation of an object.
26+
Servers should convert recognized schemas to the latest internal value, and
27+
may reject unrecognized values.
28+
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
29+
type: string
30+
kind:
31+
description: |-
32+
Kind is a string value representing the REST resource this object represents.
33+
Servers may infer this from the endpoint the client submits requests to.
34+
Cannot be updated.
35+
In CamelCase.
36+
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
37+
type: string
38+
metadata:
39+
type: object
40+
spec:
41+
description: TemplatePolicySpec describes a template policy.
42+
properties:
43+
agent:
44+
default:
45+
nodeResourceTopology: true
46+
description: AgentConfig provides access to configuration data for
47+
the agent.
48+
properties:
49+
nodeResourceTopology:
50+
description: |-
51+
NodeResourceTopology enables support for exporting resource usage using
52+
NodeResourceTopology Custom Resources.
53+
type: boolean
54+
podResourceAPI:
55+
description: PodResourceAPI enables support for querying kubelet
56+
Pod Resource API.
57+
type: boolean
58+
type: object
59+
availableResources:
60+
additionalProperties:
61+
type: string
62+
type: object
63+
control:
64+
properties:
65+
cpu:
66+
properties:
67+
classes:
68+
additionalProperties:
69+
properties:
70+
energyPerformancePreference:
71+
description: EnergyPerformancePreference for CPUs in
72+
this class.
73+
type: integer
74+
freqGovernor:
75+
description: CPUFreq Governor for this class.
76+
type: string
77+
maxFreq:
78+
description: MaxFreq is the maximum frequency for this
79+
class.
80+
type: integer
81+
minFreq:
82+
description: MinFreq is the minimum frequency for this
83+
class.
84+
type: integer
85+
uncoreMaxFreq:
86+
description: UncoreMaxFreq is the maximum uncore frequency
87+
for this class.
88+
type: integer
89+
uncoreMinFreq:
90+
description: UncoreMinFreq is the minimum uncore frequency
91+
for this class.
92+
type: integer
93+
type: object
94+
type: object
95+
required:
96+
- classes
97+
type: object
98+
type: object
99+
instrumentation:
100+
description: Config provides runtime configuration for instrumentation.
101+
properties:
102+
httpEndpoint:
103+
description: |-
104+
HTTPEndpoint is the address our HTTP server listens on. This endpoint is used
105+
to expose Prometheus metrics among other things.
106+
example: :8891
107+
type: string
108+
metrics:
109+
default:
110+
enabled:
111+
- policy
112+
- buildinfo
113+
description: Metrics defines which metrics to collect.
114+
properties:
115+
enabled:
116+
description: Enabled enables collection for metrics matched
117+
by glob patterns.
118+
example:
119+
- '*'
120+
items:
121+
type: string
122+
type: array
123+
polled:
124+
description: Polled forces polled collection for metrics matched
125+
by glob patterns.
126+
example:
127+
- computationally-expensive-metrics
128+
items:
129+
type: string
130+
type: array
131+
type: object
132+
prometheusExport:
133+
description: PrometheusExport enables exporting /metrics for Prometheus.
134+
type: boolean
135+
reportPeriod:
136+
default: 30s
137+
description: ReportPeriod is the interval between collecting polled
138+
metrics.
139+
format: duration
140+
type: string
141+
samplingRatePerMillion:
142+
description: SamplingRatePerMillion is the number of samples to
143+
collect per million spans.
144+
example: 100000
145+
type: integer
146+
tracingCollector:
147+
description: |-
148+
TracingCollector defines the external endpoint for tracing data collection.
149+
Endpoints are specified as full URLs, or as plain URL schemes which then
150+
imply scheme-specific defaults. The supported schemes and their default
151+
URLs are:
152+
- otlp-http, http: localhost:4318
153+
- otlp-grpc, grpc: localhost:4317
154+
example: otlp-http://localhost:4318
155+
type: string
156+
type: object
157+
log:
158+
properties:
159+
debug:
160+
description: Debub turns on debug messages matching listed logger
161+
sources.
162+
items:
163+
type: string
164+
type: array
165+
klog:
166+
description: Klog configures the klog backend.
167+
properties:
168+
add_dir_header:
169+
type: boolean
170+
alsologtostderr:
171+
type: boolean
172+
log_backtrace_at:
173+
type: string
174+
log_dir:
175+
type: string
176+
log_file:
177+
type: string
178+
log_file_max_size:
179+
format: int64
180+
type: integer
181+
logtostderr:
182+
type: boolean
183+
one_output:
184+
type: boolean
185+
skip_headers:
186+
type: boolean
187+
skip_log_headers:
188+
type: boolean
189+
stderrthreshold:
190+
type: string
191+
v:
192+
type: integer
193+
vmodule:
194+
type: string
195+
type: object
196+
source:
197+
description: Source controls whether messages are prefixed with
198+
their logger source.
199+
type: boolean
200+
type: object
201+
reservedResources:
202+
additionalProperties:
203+
type: string
204+
type: object
205+
required:
206+
- reservedResources
207+
type: object
208+
status:
209+
description: ConfigStatus is the per-node status for a configuration resource.
210+
properties:
211+
nodes:
212+
additionalProperties:
213+
description: NodeStatus is the configuration status for a single
214+
node.
215+
properties:
216+
errors:
217+
description: Error can provide further details of a configuration
218+
error.
219+
type: string
220+
generation:
221+
description: Generation is the generation the configuration
222+
this status was set for.
223+
format: int64
224+
type: integer
225+
status:
226+
description: Status of activating the configuration on this
227+
node.
228+
enum:
229+
- Success
230+
- Failure
231+
type: string
232+
timestamp:
233+
description: Timestamp of setting this status.
234+
format: date-time
235+
type: string
236+
required:
237+
- generation
238+
- status
239+
type: object
240+
type: object
241+
required:
242+
- nodes
243+
type: object
244+
required:
245+
- spec
246+
type: object
247+
served: true
248+
storage: true
249+
subresources:
250+
status: {}

0 commit comments

Comments
 (0)