-
Notifications
You must be signed in to change notification settings - Fork 10
/
devMode.go
121 lines (110 loc) · 2.22 KB
/
devMode.go
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
// SPDX-FileCopyrightText: 2017 Comcast Cable Communications Management, LLC
// SPDX-License-Identifier: Apache-2.0
package main
const (
// devMode is the YAML configuration parsed by Viper when the server is run with the dev mode flag
devMode = `
servers:
key:
address: :8080
disableHTTPKeepAlives: true
header:
X-Midt-Server:
- issuer
X-Midt-Version:
- development
issuer:
address: :8081
disableHTTPKeepAlives: true
header:
X-Midt-Server:
- issuer
X-Midt-Version:
- development
claims:
address: :8082
disableHTTPKeepAlives: true
header:
X-Midt-Server:
- issuer
X-Midt-Version:
- development
metrics:
address: :8083
disableHTTPKeepAlives: true
pprof:
address: :9999
disableHTTPKeepAlives: true
health:
address: :8084
disableHTTPKeepAlives: true
header:
X-Midt-Server:
- issuer
X-Midt-Version:
- development
health:
disableLogging: false
custom:
server: development
prometheus:
defaultNamespace: xmidt
defaultSubsystem: issuer
constLabels:
development: "true"
token:
alg: RS256
nonce: true
notBeforeDelta: -15s
duration: 24h
claims:
- key: mac
header: X-Midt-Mac-Address
parameter: mac
- key: serial
header: X-Midt-Serial-Number
parameter: serial
- key: uuid
header: X-Midt-Uuid
parameter: uuid
- key: iss
value: "development"
- key: trust
value: 1000
- key: sub
value: "client-supplied"
- key: aud
value: "XMiDT"
- key: capabilities
value:
-
x1:issuer:test:.*:all
- key: allowedResources
json: '{
"allowedPartners": ["comcast"],
"allowedServiceAccountIds": ["1234", "5678"]
}'
metadata:
- key: mac
header: X-Midt-Mac-Address
parameter: mac
- key: serial
header: X-Midt-Serial-Number
parameter: serial
- key: uuid
header: X-Midt-Uuid
parameter: uuid
partnerID:
claim: partner-id
header: X-Midt-Partner-Id
parameter: pid
default: comcast
key:
kid: development
type: rsa
bits: 1024
log:
file: stdout
level: INFO
`
)