This repository has been archived by the owner on Oct 27, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
porter.yaml
144 lines (135 loc) · 5.65 KB
/
porter.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
#
# Copyright (c) 2023 SAP SE
#
# This program and the accompanying materials are made available under the
# terms of the Apache License, Version 2.0 which is available at
# https://www.apache.org/licenses/LICENSE-2.0
#
# SPDX-License-Identifier: Apache-2.0
#
# Contributors:
# SAP SE - initial implementation
#
# See https://porter.sh/authoring-bundles for documentation on how to configure your bundle
name: spaicer-platform-edge
version: 0.0.1
description: "Run the SPAICER Platform on the Edge"
# invocationImage: spaicer/spaicer-platform-edge:v0.0.1
# tag: spaicer/spaicer-platform-edge-bundle:v0.0.1
registry: ghcr.io/spaicer
dockerfile: Dockerfile.tmpl
parameters:
- name: namespace
description: "Namespace to install platform"
type: string
default: "spaicerns1"
- name: helm_release
description: "Helm release name"
type: string
default: "spaicerns1-helm"
- name: domain # Example:"KUBERNETES_CLUSTER_NAME.KUBERNETES_CLUSTER_PROJECT_NAME.shoot.canary.k8s-hana.ondemand.com"
description: "Domain name"
type: string
- name: github-spaicer-user
description: "GitHub SPAICER username"
type: string
- name: github-spaicer-token
description: "GitHub SPAICER auth token"
type: string
- name: oauth_client_id
description: "OAuth Client ID"
type: string
- name: oauth_client_secret
description: "OAuth Client Secret"
type: string
outputs:
- name: CLUSTER_IP_ADDRESS
description: "IP Address assigned to the Cluster Load Balancer"
type: string
applyTo:
- install
- upgrade
mixins:
- exec
- helm3:
clientVersion: v3.7.0
repositories:
stable:
url: "https://charts.helm.sh/stable"
# A specific kubeconfig file is provided via CLI command porter credential generate
credentials:
- name: kubeconfig
description: "Kube config file with permissions to deploy on the target environment"
path: /root/.kube/config
applyTo:
- install
- uninstall
install:
- helm3:
description: "Deploy SPAICER Platform Edge with Helm"
name: "{{bundle.parameters.helm_release}}"
namespace: "{{bundle.parameters.namespace}}"
chart: helm/umbrella-charts/spaicer-platform-v0.0.1
wait: true
timeout: 5m
debug: true
set:
global.domain: "{{bundle.parameters.domain}}"
global.oauth_client_id: "{{bundle.parameters.oauth_client_id}}"
global.oauth_client_secret: "{{bundle.parameters.oauth_client_secret}}"
ingress.controller.service.annotations.dns\.gardener\.cloud/dnsnames: "*.{{bundle.parameters.domain}}"
kong.admin.ingress.hostname: "kong-admin.{{bundle.parameters.domain}}"
kong.proxy.ingress.hostname: "kong-proxy.{{bundle.parameters.domain}}"
airflow.ingress.web.host: "airflow-web.{{bundle.parameters.domain}}"
digitalcoilbackend.namespace: "{{bundle.parameters.namespace}}"
digitalcoilbackend.imageCredentials.username: "{{bundle.parameters.github-spaicer-user}}"
digitalcoilbackend.imageCredentials.accessToken: "{{bundle.parameters.github-spaicer-token}}"
digitalcoilui.namespace: "{{bundle.parameters.namespace}}"
digitalcoilui.imageCredentials.username: "{{bundle.parameters.github-spaicer-user}}"
digitalcoilui.imageCredentials.accessToken: "{{bundle.parameters.github-spaicer-token}}"
supplychainanalyzer.namespace: "{{bundle.parameters.namespace}}"
supplychainanalyzer.imageCredentials.username: "{{bundle.parameters.github-spaicer-user}}"
supplychainanalyzer.imageCredentials.accessToken: "{{bundle.parameters.github-spaicer-token}}"
supplychainui.namespace: "{{bundle.parameters.namespace}}"
supplychainui.imageCredentials.username: "{{bundle.parameters.github-spaicer-user}}"
supplychainui.imageCredentials.accessToken: "{{bundle.parameters.github-spaicer-token}}"
ap7maintenancelevelprediction.namespace: "{{bundle.parameters.namespace}}"
ap7maintenancelevelprediction.imageCredentials.username: "{{bundle.parameters.github-spaicer-user}}"
ap7maintenancelevelprediction.imageCredentials.accessToken: "{{bundle.parameters.github-spaicer-token}}"
maintenancelevelpredictionui.namespace: "{{bundle.parameters.namespace}}"
maintenancelevelpredictionui.imageCredentials.username: "{{bundle.parameters.github-spaicer-user}}"
maintenancelevelpredictionui.imageCredentials.accessToken: "{{bundle.parameters.github-spaicer-token}}"
annotatormodule.namespace: "{{bundle.parameters.namespace}}"
annotatormodule.imageCredentials.username: "{{bundle.parameters.github-spaicer-user}}"
annotatormodule.imageCredentials.accessToken: "{{bundle.parameters.github-spaicer-token}}"
outputs:
- name: CLUSTER_IP_ADDRESS
resourceType: service
resourceName: "{{bundle.parameters.helm_release}}-ingress-platform-controller"
namespace: "{{bundle.parameters.namespace}}"
jsonPath: "{.spec.clusterIP}"
- exec:
description: "Echo the IP Address"
command: "bash"
arguments:
- "utils.sh"
- "echo-ip {{bundle.outputs.CLUSTER_IP_ADDRESS}}"
- exec:
description: "Get Ingress IP"
command: "kubectl"
arguments:
- "get"
- "service"
- "{{bundle.parameters.helm_release}}-ingress-platorm-controller"
flags:
o: "json"
namespace: "{{bundle.parameters.namespace}}"
outputs:
- name: "service_ip"
jsonPath: "$.status.loadBalancer.ingress[0].ip"
uninstall:
- helm3:
description: "Uninstall SPAICER Platform Edge with Helm"
purge: true
releases:
- "{{bundle.parameters.helm_release}}"