-
Notifications
You must be signed in to change notification settings - Fork 45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refactor Flux 2.3 update #172
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
diff --git a/charts/flux-operator/README.md b/charts/flux-operator/README.md | ||
index 071e024..2fccc5f 100644 | ||
--- a/charts/flux-operator/README.md | ||
+++ b/charts/flux-operator/README.md | ||
@@ -36,6 +36,7 @@ see the Flux Operator [documentation](https://fluxcd.control-plane.io/operator/) | ||
| commonAnnotations | object | `{}` | Common annotations to add to all deployed objects including pods. | | ||
| commonLabels | object | `{}` | Common labels to add to all deployed objects including pods. | | ||
| fullnameOverride | string | `""` | | | ||
+| hostNetwork | bool | `false` | If `true`, start flux-operator in hostNetwork mode. | | ||
| image | object | `{"pullSecrets":[],"repository":"ghcr.io/controlplaneio-fluxcd/flux-operator","tag":""}` | Container image settings. The image tag defaults to the chart appVersion. | | ||
| installCRDs | bool | `true` | Install and upgrade the custom resource definitions. | | ||
| livenessProbe | object | `{"httpGet":{"path":"/healthz","port":8081},"initialDelaySeconds":15,"periodSeconds":20}` | Container liveness probe settings. | | ||
diff --git a/charts/flux-operator/templates/deployment.yaml b/charts/flux-operator/templates/deployment.yaml | ||
index 2d75821..8ffd8d8 100644 | ||
--- a/charts/flux-operator/templates/deployment.yaml | ||
+++ b/charts/flux-operator/templates/deployment.yaml | ||
@@ -40,6 +40,9 @@ spec: | ||
securityContext: | ||
{{- toYaml . | nindent 8 }} | ||
{{- end }} | ||
+ {{- if .Values.hostNetwork }} | ||
+ hostNetwork: true | ||
+ {{- end }} | ||
containers: | ||
- name: manager | ||
env: | ||
diff --git a/charts/flux-operator/values.schema.json b/charts/flux-operator/values.schema.json | ||
index 85e4d02..64270a7 100644 | ||
--- a/charts/flux-operator/values.schema.json | ||
+++ b/charts/flux-operator/values.schema.json | ||
@@ -74,6 +74,10 @@ | ||
"fullnameOverride": { | ||
"type": "string" | ||
}, | ||
+ "hostNetwork": { | ||
+ "default": false, | ||
+ "type": "boolean" | ||
+ }, | ||
"image": { | ||
"properties": { | ||
"pullSecrets": { | ||
diff --git a/charts/flux-operator/values.yaml b/charts/flux-operator/values.yaml | ||
index 59b8a23..7ecefc0 100644 | ||
--- a/charts/flux-operator/values.yaml | ||
+++ b/charts/flux-operator/values.yaml | ||
@@ -87,3 +87,6 @@ tolerations: [ ] # @schema item: object ; uniqueItems: true | ||
marketplace: | ||
license: "" | ||
account: "" | ||
+ | ||
+# -- If `true`, start flux-operator in hostNetwork mode. | ||
+hostNetwork: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
diff --git a/packages/core/fluxcd/charts/flux-operator/templates/deployment.yaml b/packages/core/fluxcd/charts/flux-operator/templates/deployment.yaml | ||
index 8ffd8d8..5ad96a8 100644 | ||
--- a/charts/flux-operator/templates/deployment.yaml | ||
+++ b/charts/flux-operator/templates/deployment.yaml | ||
@@ -58,6 +58,7 @@ spec: | ||
- name: MARKETPLACE_LICENSE | ||
value: {{ . }} | ||
{{- end }} | ||
+ {{- include "cozy.kubernetes_envs" . | nindent 12 }} | ||
securityContext: | ||
{{- toYaml .Values.securityContext | nindent 12 }} | ||
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{{- define "cozy.kubernetes_envs" }} | ||
{{- $cozyDeployment := lookup "apps/v1" "Deployment" "cozy-system" "cozystack" }} | ||
{{- $cozyContainers := dig "spec" "template" "spec" "containers" dict $cozyDeployment }} | ||
{{- range $cozyContainers }} | ||
{{- if eq .name "cozystack" }} | ||
{{- range .env }} | ||
{{- if has .name (list "KUBERNETES_SERVICE_HOST" "KUBERNETES_SERVICE_PORT") }} | ||
- {{ toJson . }} | ||
{{- end }} | ||
{{- end }} | ||
{{- end }} | ||
{{- end }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
14 changes: 0 additions & 14 deletions
14
packages/system/dashboard/templates/allow-from-kubeapps.yaml
This file was deleted.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not in sync with the upstream chart, please copy https://github.com/controlplaneio-fluxcd/charts/tree/main/charts/flux-operator
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We have
make update
which pulls from OCI chart upstream, and for flux-operator 0.6 - #178 will bring it back in sync, before these changes are released. I already updated in that PR to fix fuzz in one of the patches here, and deleted the other one for hostNetwork that is no longer needed because it got merged upstream in controlplaneio-fluxcd/charts#10.