-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add mfe type, deprecated attributes
- Loading branch information
1 parent
4143d97
commit 1d31691
Showing
3 changed files
with
72 additions
and
24 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,32 +1,37 @@ | ||
{{ if .Values.operator.microfrontend.enabled }} | ||
{{- range $mfe_name, $mfe_spec := .Values.operator.microfrontend.specs }} | ||
--- | ||
apiVersion: onecx.tkit.org/v1 | ||
kind: Microfrontend | ||
metadata: | ||
name: {{ include "app.fullname" . }} | ||
name: {{ include "app.fullname" $ }}-{{ $mfe_name }} | ||
labels: | ||
app: {{ include "app.fullname" . }} | ||
app: {{ include "app.fullname" $ }} | ||
{{ include "app.labels.common" $ | indent 4 }} | ||
spec: | ||
appId: {{ .Values.operator.microfrontend.spec.appId | default (include "app.id" .) }} | ||
appName: {{ .Values.operator.microfrontend.spec.appName | default (include "app.fullname" .) }} | ||
appId: {{ $mfe_spec.appId | default (include "app.id" $) }} | ||
appName: {{ $mfe_spec.appName | default (include "app.fullname" $) }} | ||
appVersion: {{ template "app.version" $ }} | ||
classifications: {{ .Values.operator.microfrontend.spec.classifications }} | ||
contact: {{ .Values.operator.microfrontend.spec.contact }} | ||
description: {{ .Values.operator.microfrontend.spec.description }} | ||
exposedModule: {{ .Values.operator.microfrontend.spec.exposedModule }} | ||
iconName: {{ .Values.operator.microfrontend.spec.iconName }} | ||
note: {{ .Values.operator.microfrontend.spec.note }} | ||
tagName: {{ .Values.operator.microfrontend.spec.tagName }} | ||
remoteName: {{ .Values.operator.microfrontend.spec.remoteName }} | ||
productName: {{ .Values.operator.microfrontend.spec.productName | default .Release.Name }} | ||
remoteBaseUrl: {{ .Values.operator.microfrontend.spec.remoteBaseUrl | default .Values.routing.path }} | ||
remoteEntry: {{ .Values.operator.microfrontend.spec.remoteBaseUrl | default .Values.routing.path }}{{ .Values.operator.microfrontend.entrySuffix }} | ||
technology: {{ .Values.operator.microfrontend.spec.technology }} | ||
{{ if (.Values.operator.microfrontend.spec.endpoints) }} | ||
classifications: {{ $mfe_spec.classifications | default $.Values.operator.microfrontend.spec.classifications }} | ||
contact: {{ $mfe_spec.contact | default $.Values.operator.microfrontend.spec.contact }} | ||
description: {{ $mfe_spec.description | default $.Values.operator.microfrontend.spec.description }} | ||
exposedModule: {{ $mfe_spec.exposedModule }} | ||
iconName: {{ $mfe_spec.iconName | default $.Values.operator.microfrontend.spec.iconName }} | ||
note: {{ $mfe_spec.note | default $.Values.operator.microfrontend.spec.note }} | ||
tagName: {{ $mfe_spec.tagName | default $.Values.operator.microfrontend.spec.tagName }} | ||
remoteName: {{ $mfe_spec.remoteName }} | ||
productName: {{ $mfe_spec.productName | default (include "app.product.name" $) }} | ||
remoteBaseUrl: {{ $mfe_spec.remoteBaseUrl | default $.Values.routing.path }} | ||
remoteEntry: {{ $mfe_spec.remoteBaseUrl | default $.Values.routing.path }}{{ $.Values.operator.microfrontend.entrySuffix }} | ||
technology: {{ $mfe_spec.technology | default $.Values.operator.microfrontend.spec.technology }} | ||
type: {{ $mfe_spec.type | default $.Values.operator.microfrontend.spec.type }} | ||
deprecated: {{ $mfe_spec.deprecated | default $.Values.operator.microfrontend.spec.deprecated }} | ||
{{ if ($mfe_spec.endpoints) }} | ||
endpoints: | ||
{{- range $item := .Values.operator.microfrontend.spec.endpoints }} | ||
{{- range $item := $mfe_spec.endpoints }} | ||
- name: {{ $item.name }} | ||
path: {{ $item.path }} | ||
{{- 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
operator: | ||
microfrontend: | ||
enabled: true | ||
specs: | ||
OneCXProductStoreModule1: | ||
exposedModule: "./OneCXProductStoreModule1" | ||
description: "OneCX Product Store UI 1" | ||
OneCXProductStoreModule2: | ||
exposedModule: "./OneCXProductStoreModule2" | ||
description: "OneCX Product Store UI 2" | ||
spec: | ||
note: "OneCX Product Store UI module auto import via MF operator" |
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 |
---|---|---|
|
@@ -292,35 +292,66 @@ operator: | |
microfrontend: | ||
# enable or disable configuration for operator | ||
enabled: false | ||
|
||
# default remote entry path suffix | ||
entrySuffix: remoteEntry.js | ||
|
||
# definnition | ||
# map of <name, spec> of mfe spec ( see spec ) | ||
specs: | ||
|
||
# definnition and default values for the list of spec 'specs' | ||
spec: | ||
|
||
# deprecated true | false | ||
deprecated: false | ||
|
||
# type oe mfe [ MODULE, COMPONENT ] | ||
type: MODULE | ||
|
||
# description text | ||
description: change-me | ||
|
||
# exposed module name | ||
exposedModule: change-me | ||
|
||
# icon name | ||
iconName: | ||
note: change-me | ||
|
||
# note | ||
note: | ||
|
||
# remote name | ||
remoteName: | ||
tagName: | ||
|
||
# tag name | ||
tagName: | ||
|
||
# list of strings | ||
classifications: [] | ||
|
||
# list of name and path | ||
endpoints: | ||
# - name: | ||
# path: | ||
endpoints: | ||
|
||
# technology is free text | ||
technology: ANGULAR | ||
|
||
# contact email | ||
contact: [email protected] | ||
|
||
# default is app.routing.path | ||
remoteBaseUrl: | ||
|
||
# default is app.routing.path + entrySuffix | ||
remoteEntry: | ||
|
||
# default release name (product name) | ||
productName: | ||
productName: | ||
|
||
# default deployment name (release_name-name or appId) | ||
appId: | ||
|
||
# default deployment name (release_name-name) | ||
appName: | ||
|
||
|