diff --git a/local-docker-testing/local-docker-compose-fips/README.md b/local-docker-testing/local-docker-compose-fips/README.md index d62a2cce..e899a5c2 100644 --- a/local-docker-testing/local-docker-compose-fips/README.md +++ b/local-docker-testing/local-docker-compose-fips/README.md @@ -5,7 +5,8 @@ Identical in every respect except: - `image: local-monolith-fips` instead of `local-monolith` - Compose project names are prefixed `local-monolith-fips-`, so a FIPS stack and a - normal stack can run side by side without sharing containers, volumes or networks + normal stack keep separate volumes. Both join the shared `semoss-net` network + (see [Shared network](../local-docker-compose/README.md#shared-network)) - `init.sql` and `init-bucket.sh` are referenced from `../local-docker-compose/` rather than duplicated diff --git a/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio-redis.yml b/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio-redis.yml index ff292e9e..ae24b4d3 100644 --- a/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio-redis.yml +++ b/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio-redis.yml @@ -28,6 +28,15 @@ x-semoss-env: &semoss-env CHROOT_SYMLINK_PATHS: /usr/lib/python FAKECHROOT_EXCLUDE_PATH: /dev + # node agent execution environment (ExecuteNodeCode agent tool) + NODE_HOME: /opt/node + AGENT_DEFAULT_TOOLS_ENABLE_NODE: 'true' + + # semoss-maintained services, run from + # Semoss/docker-compose-examples/engines/semoss-maintained/ + UNOSERVER: 'http://semoss-unoserver:8080' + NODE_SERVER_ENDPOINT: 'http://semoss-node-builder:3000' + # local master CUSTOM_LM_RDBMS_TYPE: "postgres" CUSTOM_LM_DRIVER: "org.postgresql.Driver" @@ -237,4 +246,8 @@ volumes: redis_data: networks: + # the same network as Semoss/docker-compose-examples, so this stack reaches the + # engines/ and engines/semoss-maintained/ services there by container name mynetwork: + external: true + name: semoss-net diff --git a/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio-zk.yml b/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio-zk.yml index ab7c40fe..3007a615 100644 --- a/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio-zk.yml +++ b/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio-zk.yml @@ -28,6 +28,15 @@ x-semoss-env: &semoss-env CHROOT_SYMLINK_PATHS: /usr/lib/python FAKECHROOT_EXCLUDE_PATH: /dev + # node agent execution environment (ExecuteNodeCode agent tool) + NODE_HOME: /opt/node + AGENT_DEFAULT_TOOLS_ENABLE_NODE: 'true' + + # semoss-maintained services, run from + # Semoss/docker-compose-examples/engines/semoss-maintained/ + UNOSERVER: 'http://semoss-unoserver:8080' + NODE_SERVER_ENDPOINT: 'http://semoss-node-builder:3000' + # local master CUSTOM_LM_RDBMS_TYPE: "postgres" CUSTOM_LM_DRIVER: "org.postgresql.Driver" @@ -226,4 +235,8 @@ volumes: zk_datalog: networks: + # the same network as Semoss/docker-compose-examples, so this stack reaches the + # engines/ and engines/semoss-maintained/ services there by container name mynetwork: + external: true + name: semoss-net diff --git a/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio.yml b/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio.yml index 33b2a595..357bf4c4 100644 --- a/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio.yml +++ b/local-docker-testing/local-docker-compose-fips/semoss-with-postgres-minio.yml @@ -36,6 +36,15 @@ services: CHROOT_SYMLINK_PATHS: /usr/lib/python FAKECHROOT_EXCLUDE_PATH: /dev + # node agent execution environment (ExecuteNodeCode agent tool) + NODE_HOME: /opt/node + AGENT_DEFAULT_TOOLS_ENABLE_NODE: 'true' + + # semoss-maintained services, run from + # Semoss/docker-compose-examples/engines/semoss-maintained/ + UNOSERVER: 'http://semoss-unoserver:8080' + NODE_SERVER_ENDPOINT: 'http://semoss-node-builder:3000' + # local master CUSTOM_LM_RDBMS_TYPE : "postgres" CUSTOM_LM_DRIVER: "org.postgresql.Driver" @@ -170,4 +179,8 @@ volumes: minio_data: networks: + # the same network as Semoss/docker-compose-examples, so this stack reaches the + # engines/ and engines/semoss-maintained/ services there by container name mynetwork: + external: true + name: semoss-net diff --git a/local-docker-testing/local-docker-compose-fips/semoss-with-postgres.yml b/local-docker-testing/local-docker-compose-fips/semoss-with-postgres.yml index f188bf36..e90826dd 100644 --- a/local-docker-testing/local-docker-compose-fips/semoss-with-postgres.yml +++ b/local-docker-testing/local-docker-compose-fips/semoss-with-postgres.yml @@ -36,6 +36,15 @@ services: CHROOT_SYMLINK_PATHS: /usr/lib/python FAKECHROOT_EXCLUDE_PATH: /dev + # node agent execution environment (ExecuteNodeCode agent tool) + NODE_HOME: /opt/node + AGENT_DEFAULT_TOOLS_ENABLE_NODE: 'true' + + # semoss-maintained services, run from + # Semoss/docker-compose-examples/engines/semoss-maintained/ + UNOSERVER: 'http://semoss-unoserver:8080' + NODE_SERVER_ENDPOINT: 'http://semoss-node-builder:3000' + # local master CUSTOM_LM_RDBMS_TYPE : "postgres" CUSTOM_LM_DRIVER: "org.postgresql.Driver" @@ -147,4 +156,8 @@ volumes: pgdata: networks: + # the same network as Semoss/docker-compose-examples, so this stack reaches the + # engines/ and engines/semoss-maintained/ services there by container name mynetwork: + external: true + name: semoss-net diff --git a/local-docker-testing/local-docker-compose/README.md b/local-docker-testing/local-docker-compose/README.md index 33a599ba..4fb11f5b 100644 --- a/local-docker-testing/local-docker-compose/README.md +++ b/local-docker-testing/local-docker-compose/README.md @@ -44,6 +44,30 @@ All four use `image: local-monolith` and the Postgres credentials client (`mc`) to create the `semoss` bucket. Used by every variant except the basic one. +## Shared network + +Every variant joins the external Docker network `semoss-net`, the same one the +[SEMOSS compose examples](../../../Semoss/docker-compose-examples/) use. A +`local-monolith` stack and a stack on the published image therefore reach the +same supporting containers by name: + +- the engines in `Semoss/docker-compose-examples/engines/` (Weaviate, Chroma, + pgvector, ClickHouse, MinIO, SFTP, mail, ...) +- the services in `Semoss/docker-compose-examples/engines/semoss-maintained/`. + Every variant sets `UNOSERVER: 'http://semoss-unoserver:8080'` and + `NODE_SERVER_ENDPOINT: 'http://semoss-node-builder:3000'`, so bringing those + up turns on document conversion and app builds. + +Create the network once (it persists until you delete it): + +```bash +docker network create semoss-net +``` + +Both sets of stacks use the same container names (`semoss`, `postgres`, +`minio`, ...), so run one SEMOSS stack at a time, local or published. The +supporting containers can stay up across the switch. + ## Usage After building `local-monolith`, from this directory choose one variant with `-f`: @@ -101,3 +125,6 @@ ZooKeeper, `echo ruok | nc localhost 2181` should return `imok`. only - change the credentials and integrate an external SSO before exposing any of this. - Python is enabled (`NETTY_PYTHON` / `NATIVE_PY_SERVER`); R is off (`R_ON: 'false'`). +- The node agent execution environment is on (`AGENT_DEFAULT_TOOLS_ENABLE_NODE: 'true'`), + which registers the `ExecuteNodeCode` agent tool. The image already sets + `NODE_HOME=/opt/node`; the compose files set it as well so the path is visible. diff --git a/local-docker-testing/local-docker-compose/semoss-with-postgres-minio-redis.yml b/local-docker-testing/local-docker-compose/semoss-with-postgres-minio-redis.yml index ec7816ca..2a9eeebf 100644 --- a/local-docker-testing/local-docker-compose/semoss-with-postgres-minio-redis.yml +++ b/local-docker-testing/local-docker-compose/semoss-with-postgres-minio-redis.yml @@ -24,6 +24,15 @@ x-semoss-env: &semoss-env CHROOT_SYMLINK_PATHS: /usr/lib/python FAKECHROOT_EXCLUDE_PATH: /dev + # node agent execution environment (ExecuteNodeCode agent tool) + NODE_HOME: /opt/node + AGENT_DEFAULT_TOOLS_ENABLE_NODE: 'true' + + # semoss-maintained services, run from + # Semoss/docker-compose-examples/engines/semoss-maintained/ + UNOSERVER: 'http://semoss-unoserver:8080' + NODE_SERVER_ENDPOINT: 'http://semoss-node-builder:3000' + # local master CUSTOM_LM_RDBMS_TYPE: "postgres" CUSTOM_LM_DRIVER: "org.postgresql.Driver" @@ -233,4 +242,8 @@ volumes: redis_data: networks: + # the same network as Semoss/docker-compose-examples, so this stack reaches the + # engines/ and engines/semoss-maintained/ services there by container name mynetwork: + external: true + name: semoss-net diff --git a/local-docker-testing/local-docker-compose/semoss-with-postgres-minio-zk.yml b/local-docker-testing/local-docker-compose/semoss-with-postgres-minio-zk.yml index 2d23bbc6..459040d4 100644 --- a/local-docker-testing/local-docker-compose/semoss-with-postgres-minio-zk.yml +++ b/local-docker-testing/local-docker-compose/semoss-with-postgres-minio-zk.yml @@ -24,6 +24,15 @@ x-semoss-env: &semoss-env CHROOT_SYMLINK_PATHS: /usr/lib/python FAKECHROOT_EXCLUDE_PATH: /dev + # node agent execution environment (ExecuteNodeCode agent tool) + NODE_HOME: /opt/node + AGENT_DEFAULT_TOOLS_ENABLE_NODE: 'true' + + # semoss-maintained services, run from + # Semoss/docker-compose-examples/engines/semoss-maintained/ + UNOSERVER: 'http://semoss-unoserver:8080' + NODE_SERVER_ENDPOINT: 'http://semoss-node-builder:3000' + # local master CUSTOM_LM_RDBMS_TYPE: "postgres" CUSTOM_LM_DRIVER: "org.postgresql.Driver" @@ -222,4 +231,8 @@ volumes: zk_datalog: networks: + # the same network as Semoss/docker-compose-examples, so this stack reaches the + # engines/ and engines/semoss-maintained/ services there by container name mynetwork: + external: true + name: semoss-net diff --git a/local-docker-testing/local-docker-compose/semoss-with-postgres-minio.yml b/local-docker-testing/local-docker-compose/semoss-with-postgres-minio.yml index a08f69fe..139c57c5 100644 --- a/local-docker-testing/local-docker-compose/semoss-with-postgres-minio.yml +++ b/local-docker-testing/local-docker-compose/semoss-with-postgres-minio.yml @@ -32,6 +32,15 @@ services: CHROOT_SYMLINK_PATHS: /usr/lib/python FAKECHROOT_EXCLUDE_PATH: /dev + # node agent execution environment (ExecuteNodeCode agent tool) + NODE_HOME: /opt/node + AGENT_DEFAULT_TOOLS_ENABLE_NODE: 'true' + + # semoss-maintained services, run from + # Semoss/docker-compose-examples/engines/semoss-maintained/ + UNOSERVER: 'http://semoss-unoserver:8080' + NODE_SERVER_ENDPOINT: 'http://semoss-node-builder:3000' + # local master CUSTOM_LM_RDBMS_TYPE : "postgres" CUSTOM_LM_DRIVER: "org.postgresql.Driver" @@ -166,4 +175,8 @@ volumes: minio_data: networks: + # the same network as Semoss/docker-compose-examples, so this stack reaches the + # engines/ and engines/semoss-maintained/ services there by container name mynetwork: + external: true + name: semoss-net diff --git a/local-docker-testing/local-docker-compose/semoss-with-postgres.yml b/local-docker-testing/local-docker-compose/semoss-with-postgres.yml index f02133f2..6b283e08 100644 --- a/local-docker-testing/local-docker-compose/semoss-with-postgres.yml +++ b/local-docker-testing/local-docker-compose/semoss-with-postgres.yml @@ -20,9 +20,6 @@ services: NETTY_PYTHON: 'true' NATIVE_PY_SERVER: 'true' SMSS_PYTHONHOME: /usr/lib/python/semossvenv - - NODE_HOME: /opt/node - AGENT_DEFAULT_TOOLS_ENABLE_NODE: 'true' R_ON: 'false' MODEL_INFERENCE_LOGS_ENABLED: 'true' USER_TRACKING_ENABLED: 'true' @@ -35,6 +32,15 @@ services: CHROOT_SYMLINK_PATHS: /usr/lib/python FAKECHROOT_EXCLUDE_PATH: /dev + # node agent execution environment (ExecuteNodeCode agent tool) + NODE_HOME: /opt/node + AGENT_DEFAULT_TOOLS_ENABLE_NODE: 'true' + + # semoss-maintained services, run from + # Semoss/docker-compose-examples/engines/semoss-maintained/ + UNOSERVER: 'http://semoss-unoserver:8080' + NODE_SERVER_ENDPOINT: 'http://semoss-node-builder:3000' + # local master CUSTOM_LM_RDBMS_TYPE : "postgres" CUSTOM_LM_DRIVER: "org.postgresql.Driver" @@ -100,7 +106,7 @@ services: CUSTOM_AUDITLOGS_PASSWORD: "mypassword" CUSTOM_AUDITLOGS_CONNECTION_URL: "jdbc:postgresql://db:5432/semoss_audit?currentSchema=public" - command: /bin/bash -c "sed -i 's@^AGENT_DEFAULT_TOOLS_ENABLE_NODE.*@AGENT_DEFAULT_TOOLS_ENABLE_NODE\ttrue@' /opt/semosshome/RDF_Map.prop && runCS.sh" + command: /bin/bash -c "runCS.sh" depends_on: db: condition: service_healthy @@ -147,4 +153,8 @@ volumes: pgdata: networks: + # the same network as Semoss/docker-compose-examples, so this stack reaches the + # engines/ and engines/semoss-maintained/ services there by container name mynetwork: + external: true + name: semoss-net