-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcompose.yaml
More file actions
68 lines (63 loc) · 1.61 KB
/
Copy pathcompose.yaml
File metadata and controls
68 lines (63 loc) · 1.61 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
name: pyndev-nso
secrets:
uv_index_username:
environment: UV_INDEX_PRIVATE_USERNAME
uv_index_password:
environment: UV_INDEX_PRIVATE_PASSWORD
volumes:
logs:
services:
# Run NSO with watch for interactive development and troubleshooting
nso:
build:
context: ./nso/init
additional_contexts:
packages: .venv/lib/python3.12/site-packages/pyndev-nso
args:
REGISTRY: ${REGISTRY}
NSO_VERSION: ${NSO_VERSION}
profiles:
- nso
volumes:
- logs:/log
ports:
- ${NSO_HTTP_PORT:-8080}:80
develop:
watch:
- action: sync+exec
path: ./.venv/lib/python3.12/site-packages/pyndev-nso
target: /nso/run/packages
exec:
command: chown -R 998:998 /nso/run/packages
user: root
# Run NSO with no watching and a health check, CI testing instance
auto-nso:
build:
context: ./nso/init
additional_contexts:
packages: .venv/lib/python3.12/site-packages/pyndev-nso
args:
REGISTRY: ${REGISTRY}
NSO_VERSION: ${NSO_VERSION}
profiles:
- auto-nso
healthcheck:
test: ncs_cmd -c "wait-start 2"
start_period: 60s
interval: 5s
timeout: 5s
retries: 2500
# Example will need update based on your environment
# test:
# build:
# context: ./nso/test
# additional_contexts:
# common: ./packages/esnet-common/src/python
# secrets:
# - uv_index_username
# - uv_index_password
# profiles:
# - test
# user: "${TEST_UID:-0}:${TEST_GID:-0}"
# volumes:
# - ./nso/test:/nso/test