mirror of https://github.com/abpframework/eventhub
30 changed files with 165 additions and 76 deletions
@ -1,23 +1,23 @@ |
|||||
apiVersion: networking.k8s.io/v1 |
apiVersion: networking.k8s.io/v1 |
||||
kind: Ingress |
kind: Ingress |
||||
metadata: |
metadata: |
||||
name: account-ingress |
name: {{ .Release.Name }}-{{ .Chart.Name }}-ingress |
||||
annotations: |
annotations: |
||||
nginx.ingress.kubernetes.io/rewrite-target: / |
nginx.ingress.kubernetes.io/rewrite-target: / |
||||
nginx.ingress.kubernetes.io/force-ssl-redirect: "true" |
nginx.ingress.kubernetes.io/force-ssl-redirect: "true" |
||||
spec: |
spec: |
||||
tls: |
tls: |
||||
- hosts: |
- hosts: |
||||
- account.openeventhub.com |
- {{ .Values.accountUrl }} |
||||
secretName: account-tls |
secretName: {{ .Release.Name }}-{{ .Chart.Name }}-tls |
||||
rules: |
rules: |
||||
- host: "account.openeventhub.com" |
- host: "{{ .Values.accountUrl }}" |
||||
http: |
http: |
||||
paths: |
paths: |
||||
- path: / |
- path: / |
||||
pathType: Prefix |
pathType: Prefix |
||||
backend: |
backend: |
||||
service: |
service: |
||||
name: account |
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
port: |
port: |
||||
number: 80 |
number: 80 |
||||
@ -1,22 +1,22 @@ |
|||||
apiVersion: apps/v1 |
apiVersion: apps/v1 |
||||
kind: Deployment |
kind: Deployment |
||||
metadata: |
metadata: |
||||
name: account |
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
spec: |
spec: |
||||
selector: |
selector: |
||||
matchLabels: |
matchLabels: |
||||
app: account |
app: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
template: |
template: |
||||
metadata: |
metadata: |
||||
labels: |
labels: |
||||
app: account |
app: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
spec: |
spec: |
||||
containers: |
containers: |
||||
- image: eventhub.account |
- image: eventhub.account |
||||
imagePullPolicy: Never |
imagePullPolicy: Never |
||||
name: account |
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
ports: |
ports: |
||||
- name: accounthttp |
- name: http |
||||
containerPort: 80 |
containerPort: 80 |
||||
- name: accounthttps |
- name: https |
||||
containerPort: 443 |
containerPort: 443 |
||||
@ -0,0 +1,3 @@ |
|||||
|
accountUrl: eh-st-account |
||||
|
apiUrl: eh-st-api |
||||
|
wwwUrl: eh-st-www |
||||
@ -1,18 +1,18 @@ |
|||||
apiVersion: networking.k8s.io/v1 |
apiVersion: networking.k8s.io/v1 |
||||
kind: Ingress |
kind: Ingress |
||||
metadata: |
metadata: |
||||
name: api-ingress |
name: {{ .Release.Name }}-{{ .Chart.Name }}-ingress |
||||
annotations: |
annotations: |
||||
nginx.ingress.kubernetes.io/rewrite-target: / |
nginx.ingress.kubernetes.io/rewrite-target: / |
||||
spec: |
spec: |
||||
rules: |
rules: |
||||
- host: "api.openeventhub.com" |
- host: "{{ .Values.apiUrl }}" |
||||
http: |
http: |
||||
paths: |
paths: |
||||
- path: / |
- path: / |
||||
pathType: Prefix |
pathType: Prefix |
||||
backend: |
backend: |
||||
service: |
service: |
||||
name: api |
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
port: |
port: |
||||
number: 80 |
number: 80 |
||||
@ -1,28 +1,22 @@ |
|||||
apiVersion: apps/v1 |
apiVersion: apps/v1 |
||||
kind: Deployment |
kind: Deployment |
||||
metadata: |
metadata: |
||||
name: api |
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
spec: |
spec: |
||||
selector: |
selector: |
||||
matchLabels: |
matchLabels: |
||||
app: api |
app: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
template: |
template: |
||||
metadata: |
metadata: |
||||
labels: |
labels: |
||||
app: api |
app: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
spec: |
spec: |
||||
containers: |
containers: |
||||
- image: eventhub.api |
- image: eventhub.api |
||||
imagePullPolicy: Never |
imagePullPolicy: Never |
||||
name: api |
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
ports: |
ports: |
||||
- name: apihttp |
- name: http |
||||
containerPort: 80 |
containerPort: 80 |
||||
- name: apihttps |
- name: https |
||||
containerPort: 443 |
containerPort: 443 |
||||
hostAliases: |
|
||||
- ip: 10.105.172.183 |
|
||||
hostnames: |
|
||||
- "account.openeventhub.com" |
|
||||
- "openeventhub.com" |
|
||||
- "api.openeventhub.com" |
|
||||
@ -0,0 +1,3 @@ |
|||||
|
accountUrl: eh-st-account |
||||
|
apiUrl: eh-st-api |
||||
|
wwwUrl: eh-st-www |
||||
@ -1,13 +1,13 @@ |
|||||
apiVersion: batch/v1 |
apiVersion: batch/v1 |
||||
kind: Job |
kind: Job |
||||
metadata: |
metadata: |
||||
name: migrator |
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
spec: |
spec: |
||||
activeDeadlineSeconds: 100 |
activeDeadlineSeconds: 100 |
||||
template: |
template: |
||||
spec: |
spec: |
||||
containers: |
containers: |
||||
- name: migrator |
- name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
image: eventhubmigrator |
image: eventhubmigrator |
||||
imagePullPolicy: Never |
imagePullPolicy: Never |
||||
restartPolicy: Never |
restartPolicy: Never |
||||
|
|||||
@ -0,0 +1,3 @@ |
|||||
|
accountUrl: eh-st-account |
||||
|
apiUrl: eh-st-api |
||||
|
wwwUrl: eh-st-www |
||||
@ -1,25 +1,20 @@ |
|||||
apiVersion: apps/v1 |
apiVersion: apps/v1 |
||||
kind: Deployment |
kind: Deployment |
||||
metadata: |
metadata: |
||||
name: redis |
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
spec: |
spec: |
||||
replicas: 1 |
replicas: 1 |
||||
selector: |
selector: |
||||
matchLabels: |
matchLabels: |
||||
app: redis |
app: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
template: |
template: |
||||
metadata: |
metadata: |
||||
labels: |
labels: |
||||
app: redis |
app: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
spec: |
spec: |
||||
containers: |
containers: |
||||
- image: redis:6.0.10-alpine |
- image: redis:6.0.10-alpine |
||||
name: redis |
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
ports: |
ports: |
||||
- name: redis |
- name: redis |
||||
containerPort: 6379 |
containerPort: 6379 |
||||
env: |
|
||||
- name: POSTGRES_USER |
|
||||
value: "root" |
|
||||
- name: POSTGRES_PASSWORD |
|
||||
value: "root" |
|
||||
@ -0,0 +1,6 @@ |
|||||
|
apiVersion: v2 |
||||
|
name: www |
||||
|
appVersion: "1.0" |
||||
|
description: EventHub WWW Application |
||||
|
version: 1.0.0 |
||||
|
type: application |
||||
@ -0,0 +1,23 @@ |
|||||
|
apiVersion: networking.k8s.io/v1 |
||||
|
kind: Ingress |
||||
|
metadata: |
||||
|
name: {{ .Release.Name }}-{{ .Chart.Name }}-ingress |
||||
|
annotations: |
||||
|
nginx.ingress.kubernetes.io/rewrite-target: / |
||||
|
nginx.ingress.kubernetes.io/force-ssl-redirect: "true" |
||||
|
spec: |
||||
|
tls: |
||||
|
- hosts: |
||||
|
- {{ .Values.wwwUrl }} |
||||
|
secretName: {{ .Release.Name }}-{{ .Chart.Name }}-tls |
||||
|
rules: |
||||
|
- host: "{{ .Values.wwwUrl }}" |
||||
|
http: |
||||
|
paths: |
||||
|
- path: / |
||||
|
pathType: Prefix |
||||
|
backend: |
||||
|
service: |
||||
|
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
|
port: |
||||
|
number: 80 |
||||
@ -0,0 +1,14 @@ |
|||||
|
apiVersion: v1 |
||||
|
kind: Service |
||||
|
metadata: |
||||
|
labels: |
||||
|
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
|
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
|
spec: |
||||
|
ports: |
||||
|
- name: "80" |
||||
|
port: 80 |
||||
|
- name: "443" |
||||
|
port: 443 |
||||
|
selector: |
||||
|
app: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
@ -0,0 +1,22 @@ |
|||||
|
apiVersion: apps/v1 |
||||
|
kind: Deployment |
||||
|
metadata: |
||||
|
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
|
spec: |
||||
|
selector: |
||||
|
matchLabels: |
||||
|
app: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
|
template: |
||||
|
metadata: |
||||
|
labels: |
||||
|
app: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
|
spec: |
||||
|
containers: |
||||
|
- image: eventhub.www |
||||
|
imagePullPolicy: Never |
||||
|
name: {{ .Release.Name }}-{{ .Chart.Name }} |
||||
|
ports: |
||||
|
- name: http |
||||
|
containerPort: 80 |
||||
|
- name: https |
||||
|
containerPort: 443 |
||||
@ -0,0 +1,3 @@ |
|||||
|
accountUrl: eh-st-account |
||||
|
apiUrl: eh-st-api |
||||
|
wwwUrl: eh-st-www |
||||
@ -0,0 +1,3 @@ |
|||||
|
accountUrl: eh-st-account |
||||
|
apiUrl: eh-st-api |
||||
|
wwwUrl: eh-st-www |
||||
@ -0,0 +1,4 @@ |
|||||
|
FROM mcr.microsoft.com/dotnet/aspnet:5.0 |
||||
|
COPY bin/Release/net5.0/publish/ app/ |
||||
|
WORKDIR /app |
||||
|
ENTRYPOINT ["dotnet", "EventHub.Web.dll"] |
||||
Loading…
Reference in new issue