-
Notifications
You must be signed in to change notification settings - Fork 138
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into angular-8
* master: (33 commits) Master test fixes (#3992) Fix npm audit error in dev dependency - handlebars used by istanbul & karma-coverage-istanbul-reporter - weird goings on in stratos (npm audit shows handlebars errors), vanilla angular 7 app (shows no handlebars errors) and vanilla angular 8 app (no handlabrs errors). Same istanbul and coverage dependencies in all node_modules directories and same coverage dependency in all apps - In the end fixed via audit's recommendation to `npm update handlebars --depth 4` Some unit test fixes Update versions links in readme Fix v2-master references and goreportcard link Trivial change Address some todo's, make issues for others Remove unused route Fix unit test Reverted the app wall and removed console.log Fix lint & unit tests Fix connect to endpoint subtype Ensure we're passing the correct params to action builders. Removed console logs Ensure endpoint register tiles are ordered correctly Start with empty CustomizationsMetadata Convert CustomizationsMetadata inject into singleton CustomizationService Fix npm audit vulnerabilities (#3899) Remove old ingress docs and add new (#3961) Helm Chart: Add ingress support (#3935) ...
- Loading branch information
Showing
157 changed files
with
2,587 additions
and
589 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
#!/usr/bin/env bash | ||
|
||
echo "Starting MariaDB database for development" | ||
|
||
STRATOS_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && cd ../.. && pwd)" | ||
echo $STRATOS_PATH | ||
|
||
docker stop stratos-db | ||
docker rm stratos-db | ||
|
||
ID=$(docker run --name stratos-db -d -e MYSQL_ROOT_PASSWORD=dbroot -p 3306:3306 splatform/stratos-mariadb) | ||
echo $ID | ||
|
||
rm -f dbsetup.sql init.sh | ||
cat <<EOF > dbsetup.sql | ||
CREATE DATABASE stratosdb; | ||
CREATE USER stratos IDENTIFIED BY 'strat0s'; | ||
GRANT ALL PRIVILEGES ON stratosdb.* to 'stratos'@'%'; | ||
EOF | ||
|
||
cat <<EOF > init.sh | ||
#!/usr/bin/env bash | ||
mysql -uroot -pdbroot < /dbsetup.sql | ||
EOF | ||
|
||
chmod +x init.sh | ||
docker cp ./dbsetup.sql ${ID}:/dbsetup.sql | ||
docker cp ./init.sh ${ID}:/init.sh | ||
rm dbsetup.sql init.sh | ||
|
||
#Fetch dockerize tool | ||
wget https://github.com/jwilder/dockerize/releases/download/v0.6.1/dockerize-linux-amd64-v0.6.1.tar.gz | ||
tar -xzvf dockerize-linux-amd64-v0.6.1.tar.gz | ||
rm dockerize-linux-amd64-v0.6.1.tar.gz | ||
|
||
chmod +x ./dockerize | ||
docker cp ./dockerize ${ID}:/dockerize | ||
rm dockerize | ||
|
||
#We us wait for the internal socket to come up before running init script | ||
echo "Just waiting a few seconds for the DB to come online ..." | ||
docker exec -t ${ID} /dockerize -wait file:///var/run/mysql/mysql.sock -timeout 1m | ||
|
||
echo "Database ready" | ||
docker exec -t ${ID} /init.sh | ||
|
||
mkdir -p ${STRATOS_PATH}/src/jetstream/db | ||
cp ${STRATOS_PATH}/deploy/db/dbconf.yml ${STRATOS_PATH}/src/jetstream/db | ||
|
||
if [ -f ${STRATOS_PATH}/src/jetstream/jetstream ]; then | ||
${STRATOS_PATH}/src/jetstream/jetstream --env=mariadb-dev up | ||
else | ||
echo "Build the Stratos backend and run db migrations with:" | ||
echo " ./jetstream --env=mariadb-local up" | ||
fi |
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,27 @@ | ||
#!/usr/bin/env bash | ||
|
||
echo "Startind Postgres database for development" | ||
|
||
STRATOS_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" && cd ../.. && pwd)" | ||
echo $STRATOS_PATH | ||
|
||
docker stop stratos-db | ||
docker rm stratos-db | ||
|
||
ID=$(docker run --name stratos-db -d -e POSTGRES_DB=stratosdb -e POSTGRES_USER=stratos -e POSTGRES_PASSWORD=strat0s -p 5432:5432 postgres) | ||
echo $ID | ||
|
||
echo "Just waiting a few seconds for the DB to come online ..." | ||
sleep 5 | ||
|
||
echo "Database ready" | ||
|
||
mkdir -p ${STRATOS_PATH}/src/jetstream/db | ||
cp ${STRATOS_PATH}/deploy/db/dbconf.yml ${STRATOS_PATH}/src/jetstream/db | ||
|
||
if [ -f ${STRATOS_PATH}/src/jetstream/jetstream ]; then | ||
${STRATOS_PATH}/src/jetstream/jetstream --env=postgres-dev up | ||
else | ||
echo "Build the Stratos backend and run db migrations with:" | ||
echo " ./jetstream --env=postgres-local up" | ||
fi |
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 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,76 @@ | ||
{{- if .Values.console.service -}} | ||
{{- if .Values.console.service.ingress -}} | ||
{{- if .Values.console.service.ingress.enabled -}} | ||
|
||
{{- if not .Values.console.service.ingress.secretName -}} | ||
--- | ||
# The certificate and key for the TLS secret are passed through ingress.tls.crt and ingress.tls.key | ||
# respectively. If the operator does not provide these values at installation time, the TLS secret | ||
# will contain empty values. The standard behaviour for NGINX ingress controller is to provide a | ||
# fake certificate instead. It is useful only for testing and development. It is expected that for | ||
# production use the operator will provide these values. | ||
apiVersion: "v1" | ||
kind: "Secret" | ||
type: kubernetes.io/tls | ||
metadata: | ||
name: "{{ .Release.Name }}-ingress-tls" | ||
labels: | ||
app.kubernetes.io/name: "stratos" | ||
app.kubernetes.io/instance: "{{ .Release.Name }}" | ||
app.kubernetes.io/version: "{{ .Chart.AppVersion }}" | ||
app.kubernetes.io/component: "console-ingress-tls" | ||
helm.sh/chart: "{{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}" | ||
data: | ||
tls.crt: {{ .Values.console.service.ingress.tls.crt | default "" | b64enc | quote }} | ||
tls.key: {{ .Values.console.service.ingress.tls.key | default "" | b64enc | quote }} | ||
{{- end }} | ||
|
||
--- | ||
# Ingress for the Console UI service | ||
apiVersion: "extensions/v1beta1" | ||
kind: "Ingress" | ||
metadata: | ||
name: "{{ .Release.Name }}-ingress" | ||
annotations: | ||
{{- if hasKey .Values.console.service.ingress.annotations "kubernetes.io/ingress.class" | not -}} | ||
{{ $_ := set .Values.console.service.ingress.annotations "kubernetes.io/ingress.class" "nginx" }} | ||
{{- end }} | ||
{{- if hasKey .Values.console.service.ingress.annotations "nginx.ingress.kubernetes.io/secure-backends" | not -}} | ||
{{ $_ := set .Values.console.service.ingress.annotations "nginx.ingress.kubernetes.io/secure-backends" "true" }} | ||
{{- end }} | ||
{{- if hasKey .Values.console.service.ingress.annotations "nginx.ingress.kubernetes.io/backend-protocol" | not -}} | ||
{{ $_ := set .Values.console.service.ingress.annotations "nginx.ingress.kubernetes.io/backend-protocol" "HTTPS" }} | ||
{{- end }} | ||
{{- if hasKey .Values.console.service.ingress.annotations "nginx.ingress.kubernetes.io/ssl-redirect" | not -}} | ||
{{ $_ := set .Values.console.service.ingress.annotations "nginx.ingress.kubernetes.io/ssl-redirect" "false" }} | ||
{{- end }} | ||
{{- if hasKey .Values.console.service.ingress.annotations "nginx.ingress.kubernetes.io/proxy-body-size" | not -}} | ||
{{ $_ := set .Values.console.service.ingress.annotations "nginx.ingress.kubernetes.io/proxy-body-size" "200m" }} | ||
{{- end }} | ||
{{ $_ := set .Values.console.service.ingress.annotations "nginx.org/websocket-services" (print .Release.Name "-ui-ext") }} | ||
{{ toYaml .Values.console.service.ingress.annotations | indent 4 }} | ||
labels: | ||
app.kubernetes.io/name: "stratos" | ||
app.kubernetes.io/component: "console-ingress" | ||
app.kubernetes.io/instance: "{{ .Release.Name }}" | ||
app.kubernetes.io/version: "{{ .Chart.AppVersion }}" | ||
helm.sh/chart: "{{ .Chart.Name }}-{{ .Chart.Version | replace "+" "_" }}" | ||
{{- range $key, $value := .Values.console.service.ingress.extraLabels }} | ||
{{ $key }}: {{ $value }} | ||
{{- end }} | ||
spec: | ||
tls: | ||
- secretName: {{ default "{{ .Release.Name }}-ingress-tls" .Values.console.service.ingress.secretName | quote }} | ||
hosts: | ||
- {{ template "ingress.host" . }} | ||
rules: | ||
- host: {{ template "ingress.host" . }} | ||
http: | ||
paths: | ||
- path: "/" | ||
backend: | ||
serviceName: "{{ .Release.Name }}-ui-ext" | ||
servicePort: 443 | ||
{{- end }} | ||
{{- end }} | ||
{{- end }} |
Oops, something went wrong.