-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patharchitect.yml
More file actions
56 lines (53 loc) · 1.47 KB
/
architect.yml
File metadata and controls
56 lines (53 loc) · 1.47 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
name: node-rest-api
description: A simple sign in REST API built with Node.js, Express, and a postgres database.
homepage: https://github.com/architect-team/architect-cli/tree/master/examples/stateful-component
keywords:
- architect
- examples
- stateful
- postgres
- nodejs
- reactjs
secrets:
db_user:
description: Root user to assign to the component's DB
default: architect
db_pass:
description: Root password to assign to the component's DB
default: secret
db_name:
description: Name of the DB the component will store content in
default: api-db
db_port:
description: Port for the db
default: 5432
api_port:
description: Port for api
default: 8080
services:
api-db:
image: postgres:12
interfaces:
postgres:
port: ${{ secrets.db_port }}
protocol: postgresql
environment:
POSTGRES_USER: ${{ secrets.db_user }}
POSTGRES_PASSWORD: ${{ secrets.db_pass }}
POSTGRES_DB: ${{ secrets.db_name }}
api:
build:
context: .
interfaces:
http: ${{ secrets.api_port }}
environment:
DB_ADDR: ${{ services.api-db.interfaces.postgres.url }}/${{ secrets.db_name }}
DB_USER: ${{ secrets.db_user }}
DB_PASS: ${{ secrets.db_pass }}
PORT: ${{ secrets.api_port }}
interfaces:
api:
description: A description
url: ${{ services.api.interfaces.http.url }}
ingress:
subdomain: api