-
Notifications
You must be signed in to change notification settings - Fork 0
/
application-deployment.yaml
104 lines (103 loc) · 2.31 KB
/
application-deployment.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
#
# Copyright IBM Corp. All Rights Reserved.
#
# SPDX-License-Identifier: Apache-2.0
#
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: runhfsc-web
spec:
replicas: 1
selector:
matchLabels:
app: runhfsc-web
template:
metadata:
labels:
app: runhfsc-web
spec:
containers:
- name: main
image: localhost:5000/runhfsc-web:0.0.5
resources:
requests:
memory: "50Mi"
cpu: "0.1"
env:
- name: RUNHFSC_CONFIG_JSON_FILE
value: /fabric/appcfg/runhfsc.json
volumeMounts:
- name: fabricid
mountPath: /fabric/application/ids
- name: connectionprofile
mountPath: /fabric/application/cp
- name: runhfsccfg
mountPath: /fabric/appcfg
volumes:
- name: runhfsccfg
configMap:
name: app-runhfsc-v1-config
- name: fabricid
configMap:
name: app-fabric-ids-v2-map
- name: connectionprofile
configMap:
name: app-org1peer-endpoint
---
apiVersion: v1
kind: ConfigMap
metadata:
name: app-runhfsc-v1-config
data:
runhfsc.json : |
{
"default": {
"type": "gateway",
"tlsEnabled": true,
"identity": {
"idFile":"/fabric/application/ids/asset-transfer_appid.json",
"mspId":"Org1MSP"
},
"endpoint": {
"connectionProfileFile":"/fabric/application/cp/profile.json"
},
"defaultChannel":"mychannel",
"defaultContract":"asset-transfer"
}
}
---
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
annotations:
nginx.ingress.kubernetes.io/proxy-connect-timeout: 60s
labels:
app: runhfsc-web
name: runhfsc-web
spec:
ingressClassName: nginx
rules:
- host: runhfsc-web.localho.st
http:
paths:
- backend:
service:
name: runhfsc-web
port:
name: http
path: /
pathType: ImplementationSpecific
---
apiVersion: v1
kind: Service
metadata:
name: runhfsc-web
spec:
ports:
- name: http
port: 4000
protocol: TCP
selector:
app: runhfsc-web