mirror of
https://github.com/kairos-io/osbuilder.git
synced 2025-07-17 16:51:19 +00:00
update osartifact chart
This commit is contained in:
parent
3ff8acf5bb
commit
9ccb59d242
2
.github/workflows/osbuilder-chart.yml
vendored
2
.github/workflows/osbuilder-chart.yml
vendored
@ -1,7 +1,7 @@
|
|||||||
name: Publish OS Builder Chart
|
name: Publish OS Builder Chart
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
push:
|
push:
|
||||||
paths:
|
paths:
|
||||||
- charts/osbuilder
|
- charts/osbuilder
|
||||||
|
@ -5,4 +5,4 @@ maintainers:
|
|||||||
- name: Plural
|
- name: Plural
|
||||||
email: support@plural.sh
|
email: support@plural.sh
|
||||||
type: application
|
type: application
|
||||||
version: 0.3.0
|
version: 0.4.0
|
@ -1,7 +1,8 @@
|
|||||||
apiVersion: build.kairos.io/v1alpha2
|
apiVersion: build.kairos.io/v1alpha2
|
||||||
kind: OSArtifact
|
kind: OSArtifact
|
||||||
metadata:
|
metadata:
|
||||||
name: '{{ include "osartifact.fullname" . }}'
|
name: {{ include "osartifact.fullname" . }}
|
||||||
|
namespace: {{ .Release.Namespace }}
|
||||||
spec:
|
spec:
|
||||||
imageName: {{ .Values.image }}
|
imageName: {{ .Values.image }}
|
||||||
iso: true
|
iso: true
|
||||||
@ -19,24 +20,13 @@ spec:
|
|||||||
{{ $key }}: {{ $value }}
|
{{ $key }}: {{ $value }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
cloudConfigRef:
|
cloudConfigRef:
|
||||||
name: '{{ include "osartifact.fullname" . }}-cloud-config'
|
name: {{ include "osartifact.fullname" . }}-config
|
||||||
key: 'cloud-config.yaml'
|
key: cloud-config.yaml
|
||||||
exporters:
|
outputImage:
|
||||||
- template:
|
registry: {{ .Values.exporter.registry }}
|
||||||
spec:
|
repository: {{ .Values.exporter.repository }}
|
||||||
restartPolicy: Never
|
tag: {{ .Values.exporter.tag }}
|
||||||
containers:
|
username: {{ .Values.exporter.username }}
|
||||||
- name: upload
|
passwordSecretKeyRef:
|
||||||
image: quay.io/curl/curl
|
name: {{ .Values.exporter.configSecret.name | default (printf "%s-%s" (include "osartifact.fullname" .) "config") }}
|
||||||
command:
|
key: {{ .Values.exporter.configSecret.key }}
|
||||||
- /bin/sh
|
|
||||||
args:
|
|
||||||
- -c
|
|
||||||
- |
|
|
||||||
for f in $(ls /artifacts)
|
|
||||||
do
|
|
||||||
curl -T /artifacts/$f http://osartifactbuilder-operator-osbuilder-nginx/upload/$f
|
|
||||||
done
|
|
||||||
volumeMounts:
|
|
||||||
- name: artifacts
|
|
||||||
mountPath: /artifacts
|
|
||||||
|
@ -5,11 +5,18 @@
|
|||||||
|
|
||||||
{{ $token := index $tokenSecret.data .Values.tokenSecret.key | b64dec }}
|
{{ $token := index $tokenSecret.data .Values.tokenSecret.key | b64dec }}
|
||||||
{{ $password := index $passwordSecret.data .Values.passwordSecret.key | b64dec }}
|
{{ $password := index $passwordSecret.data .Values.passwordSecret.key | b64dec }}
|
||||||
|
{{ $dockerUserPassword := "" }}
|
||||||
|
|
||||||
|
{{- if .Values.exporter.passwordSecret.name }}
|
||||||
|
{{ $dockerUserPasswordSecret := (lookup "v1" "Secret" .Release.Namespace .Values.exporter.passwordSecret.name )}}
|
||||||
|
{{ $dockerUserPassword = index $passwordSecret.data .Values.exporter.passwordSecret.key | b64dec }}
|
||||||
|
{{- end }}
|
||||||
|
|
||||||
kind: Secret
|
kind: Secret
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
metadata:
|
metadata:
|
||||||
name: '{{ include "osartifact.fullname" . }}-cloud-config'
|
name: {{ include "osartifact.fullname" . }}-config
|
||||||
|
namespace: {{ .Release.Namespace }}
|
||||||
stringData:
|
stringData:
|
||||||
cloud-config.yaml: |
|
cloud-config.yaml: |
|
||||||
#cloud-config
|
#cloud-config
|
||||||
@ -80,4 +87,14 @@ stringData:
|
|||||||
{{ .Values.extraCloudConfig | toYaml | nindent 4 }}
|
{{ .Values.extraCloudConfig | toYaml | nindent 4 }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
|
||||||
|
{{- if $dockerUserPassword }}
|
||||||
|
config.json: |
|
||||||
|
{
|
||||||
|
"auths": {
|
||||||
|
"{{ .Values.exporter.registry }}": {
|
||||||
|
"auth": {{ printf "%s:%s" .Values.exporter.username $dockerUserPassword | b64enc }}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
{{- end }}
|
||||||
{{- end}}
|
{{- end}}
|
@ -24,10 +24,9 @@ project: default
|
|||||||
# Console URL that will be used by the device to join the fleet, i.e. console.plrl-xyz.onplural.sh
|
# Console URL that will be used by the device to join the fleet, i.e. console.plrl-xyz.onplural.sh
|
||||||
url: ~
|
url: ~
|
||||||
|
|
||||||
|
# Secret that holds bootstrap token used to register the cluster within Plural
|
||||||
tokenSecret:
|
tokenSecret:
|
||||||
# Name of the secret that holds the bootstrap token
|
|
||||||
name: ~
|
name: ~
|
||||||
# Key in the secret that holds the bootstrap token
|
|
||||||
key: token
|
key: token
|
||||||
|
|
||||||
# A list of our required bundles that should be added to the result ISO image.
|
# A list of our required bundles that should be added to the result ISO image.
|
||||||
@ -62,4 +61,25 @@ extraUserCloudConfig: ~
|
|||||||
# authorized_keys:
|
# authorized_keys:
|
||||||
# kairos:
|
# kairos:
|
||||||
# - github:myusername
|
# - github:myusername
|
||||||
extraCloudConfig: ~
|
extraCloudConfig: ~
|
||||||
|
|
||||||
|
# Export configuration for the final ISO images
|
||||||
|
exporter:
|
||||||
|
# Docker registry DNS name where we should export packed ISO images
|
||||||
|
registry: ~
|
||||||
|
# Name of the repository where images should be stored
|
||||||
|
repository: plural-edge
|
||||||
|
# Image tag that should be used when pushing to the registry
|
||||||
|
tag: latest
|
||||||
|
# Repository username used for basic auth
|
||||||
|
username: ~
|
||||||
|
# Secret that stores just the password for the docker registry user.
|
||||||
|
# One of 'passwordSecret' or 'configSecret' must be provided.
|
||||||
|
passwordSecret:
|
||||||
|
name: ~
|
||||||
|
key: password
|
||||||
|
# Secret configuration that stores the docker config.json file with the auth information.
|
||||||
|
# It is in the default docker format.
|
||||||
|
configSecret:
|
||||||
|
name: ~
|
||||||
|
key: config.json
|
Loading…
Reference in New Issue
Block a user