Repository navigation
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
132 lines (126 loc) · 3.05 KB
/
Copy pathdocker-compose.yml
File metadata and controls
132 lines (126 loc) · 3.05 KB
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
services:
client:
build:
context: ./client
dockerfile: Dockerfile.client.dev
args:
- VITE_BACKEND_ROOT=http://localhost:5000
- NODE_ENV=development
ports:
- 3000:3000
volumes:
- type: bind
source: ./client/src/
target: /app/src
server:
build:
context: ./server
dockerfile: Dockerfile.server.dev
environment:
- CLIENT_URL=http://localhost:3000
- HIVE_API_URL=http://nyckeln:7004/api/v1
- HIVE_API_KEY=1234567890abcdefabcdef
- JWT_SECRET=1234567890abcdefabcdef
- OIDC_CLIENT_ID=client-id
- OIDC_CLIENT_SECRET=client-secret
- OIDC_ISSUER=http://localhost:7003
- POSTGRES_PORT=5432
- POSTGRES_HOST=db
- POSTGRES_PASSWORD=postgres
- POSTGRES_USER=postgres
- POSTGRES_DB=mydatabase
- PORT=5000
ports:
- "5000:5000"
configs:
- source: nginx.conf
target: /etc/nginx/nginx.conf
depends_on:
db:
condition: service_healthy
db:
image: postgres:15
container_name: postgres
restart: always
environment:
- POSTGRES_USER=postgres
- POSTGRES_HOST=localhost
- POSTGRES_PASSWORD=postgres
- POSTGRES_DB=mydatabase
ports:
- "5432:5432"
healthcheck:
test:
- "CMD-SHELL"
- "sh -c 'pg_isready -d postgres -U postgres'"
interval: 1s
timeout: 5s
retries: 5
start_period: 10s
nyckeln:
image: ghcr.io/datasektionen/nyckeln-under-dorrmattan
configs:
- source: nyckeln.yaml
target: /config.yaml
ports:
- 7001:7001
- 7002:7002
- 7003:7003
- 7004:7004
configs:
nginx.conf:
content: |
events {}
http {
server {
listen 7003;
location / {
proxy_pass http://nyckeln:7003;
}
}
}
nyckeln.yaml:
content: |
clients:
- id: "client-id"
secret: "client-secret"
redirect_uris:
- http://localhost:3000/auth/oidc-callback
users:
- ug_kth_id: some-id
kth_id: turetek
email: turetek@kth.se
first_name: Ture
family_name: Teknolog
- ug_kth_id: some-other-id
kth_id: diadat
email: diadat@kth.se
first_name: Diana
family_name: Datalog
hive:
tokens:
- secret: aaaaaaaa-aaaa-aaaa-aaaa-aaaaaaaa
permissions:
- id: admin
scope: null
groups:
- name: Systemansvarig
id: d-sys
domain: example.com
members:
- turetek
tags:
- id: link-manager
permissions:
- id: custom-links
- id: manage-all
- id: manage-blacklist
- name: Näringslivsgruppen
id: nlg
domain: example.com
members:
- diadat
tags:
- id: link-manager
permissions:
- id: custom-links