SmythOS Studio: Open-Source Visual AI Agent Builder and deployable runtime stack from SmythOS. Start with an intuitive drag-and-drop workspace, extend with custom code, and deploy your agents anywhere — local, cloud, or edge — with full governance and control.
JavaScript a2aagentic-aiai-agentsdevtoolsmcp-clientn8n-alternativeno-codeopen-sourceorchestrationsmythosvisual-builder
config changes & .env example full
Ahmed Essam45b50b47fde7
diff --git a/packages/app/.cursorignore b/.cursorignoresimilarity index 100%rename from packages/app/.cursorignorerename to .cursorignorediff --git a/packages/app/.cursorrules b/.cursorrulessimilarity index 100%rename from packages/app/.cursorrulesrename to .cursorrulesdiff --git a/.env.full.example b/.env.full.examplenew file mode 100644index 00000000..3378c0f2--- /dev/null+++ b/.env.full.example@@ -0,0 +1,87 @@+# ------------------------------+# Environment Variables for SmythOS services+# ------------------------------++# domain for UI server+# example: http://localhost:4000+APP_DOMAIN=+# port for UI server+APP_PORT=+# vite dev server (react hot reload)+# example: 4001+APP_DEV_SERVER_PORT=+# local mode indicator for the server to proxy some requests to the dev server (auto configured)+# options: true, false+LOCAL_MODE=+# environment the app is running in+# options: development, production+NODE_ENV=+# OpenAI api key used for some auto generation features (e.g. component title auto generation)+OPENAI_API_KEY=+# FALAI api key used for Avatar image generation+FALAI_API_KEY=+# path to the data directory+# example: /root/smythos-data+# default: ~/smythos-data+DATA_PATH=+# session secret for both runtime and UI servers+# defaults to a hardcoded secret for dev environment+SESSION_SECRET=++# Redis config: (XOR redis1 and redis2)++## [redis1]single redis instance mode+REDIS_PORT=+REDIS_HOST=+REDIS_PASSWORD=++## [redis2] redis sentinel mode (recommended for scalability)+# example: redis1domain:6379,redis2domain:6379,redis3domain:6379+REDIS_SENTINEL_HOSTS=+REDIS_MASTER_NAME=+REDIS_PASSWORD=++++# AWS config:+# if empty, we use local storage for some features+AWS_ACCESS_KEY_ID=+AWS_SECRET_ACCESS_KEY=+AWS_S3_BUCKET_NAME=+AWS_S3_REGION=+AWS_S3_PUB_REGION=+AWS_S3_PUB_BUCKET_NAME=+++# Maintenance mode+# options: ON, OFF+MAINTENANCE=+++# Runtime server port+RUNTIME_PORT=+# Runtime admin port for admin operations (e.g. stopping server, requests, halt etc)+RUNTIME_ADMIN_PORT=+# Runtime domain+# default to http://localhost:${RUNTIME_PORT}+RUNTIME_DOMAIN=++# domain that hosts development agents. aka the agent state that is visible in canvas (see https://smythos.com/docs/agent-deployments/overview/)+DEFAULT_AGENT_DOMAIN=+# port of DEFAULT_AGENT_DOMAIN+# default to 80 or 443 depending on if the domain is secured using tls or not+AGENT_DOMAIN_PORT=+# domain that hosts DEPLOYED / producation agents (see https://smythos.com/docs/agent-deployments/overview/)+PROD_AGENT_DOMAIN=+# request limit per minute for runtime server+# default to 300+REQ_LIMIT_PER_MINUTE=+# maximum concurrent requests for runtime server+# default to 50+MAX_CONCURRENT_REQUESTS=+# Middleware API port+MIDDLEWARE_API_PORT=+# Database URL+# Format: mysql://<username>:<password>@<host>:<port>/<database>+# Example: mysql://user:password@mysql:3306/smythos_db+DATABASE_URL=diff --git a/Dockerfile b/Dockerfileindex db84a3b9..480918e3 100644--- a/Dockerfile+++ b/Dockerfile@@ -40,7 +40,7 @@ RUN sed -i 's/listen(PORT, "localhost",/listen(PORT, process.env.HOST || "0.0.0.WORKDIR /app/packages/middlewareRUN PRISMA_CLI_BINARY_TARGETS="linux-musl-openssl-3.0.x" pnpm run prisma:generate-RUN mkdir -p /root && mkdir -p /root/smyth-ui-data && echo '{}' > /root/smyth-ui-data/vault.json+RUN mkdir -p /root && mkdir -p /root/smythos-data && echo '{}' > /root/smythos-data/vault.jsonCOPY docker-endpoint.sh /app/start.shdiff --git a/docker-compose.yml b/docker-compose.ymlindex 7e6a4d76..20e887ce 100644--- a/docker-compose.yml+++ b/docker-compose.yml@@ -61,9 +61,7 @@ services:RUNTIME_DOMAIN: ${RUNTIME_DOMAIN:-http://localhost:5053}volumes:- - smythos_data:/app/data- - smythos_middleware_data:/app/packages/middleware/data- - smythos_runtime_data:/app/packages/runtime/data+ - smythos_data:/root/smythos-datanetworks:- smythos-networkdepends_on:@@ -87,7 +85,4 @@ volumes:driver: localsmythos_data:driver: local- smythos_middleware_data:- driver: local- smythos_runtime_data:- driver: local+diff --git a/packages/app/.env.sample b/packages/app/.env.sampledeleted file mode 100644index d80b3ce7..00000000--- a/packages/app/.env.sample+++ /dev/null@@ -1,11 +0,0 @@-GOOGLE_CLIENT_ID=-GOOGLE_CLIENT_SECRET=-UI_SERVER=--API_SERVER=-SMYTH_API_SERVER=--# TODO: remove data path-DATA_PATH=--SMYTH_VAULT_API_BASE_URL= #vault server urldiff --git a/packages/app/src/backend/config.ts b/packages/app/src/backend/config.tsindex a9ccc127..f62d67ab 100644--- a/packages/app/src/backend/config.ts+++ b/packages/app/src/backend/config.ts@@ -10,7 +10,7 @@ dotenvFlow.config({const getDefaultDataPath = () => {const homeDir = os.homedir();- return path.join(homeDir, 'smyth-ui-data');+ return path.join(homeDir, 'smythos-data');};const transformEnv = (env: string) => {diff --git a/packages/runtime/.env.example b/packages/runtime/.env.exampledeleted file mode 100644index effc9fa0..00000000--- a/packages/runtime/.env.example+++ /dev/null@@ -1,22 +0,0 @@-# Required Environment for both Production and Development-LOGTO_M2M_APP_SECRET="logto-m2m-app-secret"-LOGTO_M2M_APP_ID="logto-m2m-app-id"-LOGTO_SERVER="logto-server"-LOGTO_API_RESOURCE="logto-api-resource"-MIDDLEWARE_API_BASE_URL="middleware-api-base-url"--# Optional Environment in development-PORT="5053"-ADMIN_PORT="5054"-NODE_ENV="development"-BASE_URL="http://localhost:5053"-UI_SERVER="http://localhost:4000"-SESSION_SECRET="session-secret"-DATA_PATH="path/to/store/data"--# DEFAULT_AGENT_DOMAIN serves as the staging/development wildcard domain (e.g., agentid.staging.smythos.dev) where non-deployed agents are automatically accessible for testing and development purposes. To run the agent locally, the domain name must contain `localagent`-DEFAULT_AGENT_DOMAIN="localagent.stage.smyth.ai"-AGENT_DOMAIN_PORT="5053"--# PROD_AGENT_DOMAIN is the production wildcard domain (e.g., agentid.smythos.ai) where deployed agents are served to end users, with the system automatically routing agents to this domain once they are marked as deployed.-PROD_AGENT_DOMAIN="agentid.smythos.com"diff --git a/packages/runtime/src/core/config.ts b/packages/runtime/src/core/config.tsindex d5a7e6d1..68c5732e 100644--- a/packages/runtime/src/core/config.ts+++ b/packages/runtime/src/core/config.ts@@ -1,4 +1,5 @@import dotenvFlow from 'dotenv-flow';+import os from 'os';import path from 'path';import { fileURLToPath } from 'url';@@ -9,6 +10,11 @@ dotenvFlow.config({const __filename = fileURLToPath(import.meta.url);const __dirname = path.dirname(__filename);+const getDefaultDataPath = () => {+ const homeDir = os.homedir();+ return path.join(homeDir, 'smythos-data');+};+const config = {env: {PORT: parseInt(process.env.RUNTIME_PORT || '5053', 10),@@ -19,7 +25,7 @@ const config = {MIDDLEWARE_API_BASE_URL: `http://localhost:${process.env.MIDDLEWARE_API_PORT}`,NODE_ENV: process.env?.NODE_ENV || 'development',- ADMIN_PORT: process.env.ADMIN_PORT || 5054,+ ADMIN_PORT: process.env.RUNTIME_ADMIN_PORT || process.env.ADMIN_PORT || 5054,BASE_URL: process.env.RUNTIME_DOMAIN || `http://localhost:${process.env.RUNTIME_PORT}`,@@ -36,7 +42,7 @@ const config = {UI_SERVER: process.env.APP_DOMAIN || `http://localhost:${process.env.APP_PORT}` || 'http://localhost:5053',SESSION_SECRET: process.env.SESSION_SECRET,- DATA_PATH: process.env.DATA_PATH || path.resolve(__dirname, '../../../data'),+ DATA_PATH: process.env.DATA_PATH || getDefaultDataPath(),SMYTHOS_SERVER_TYPE: process.env.SMYTHOS_SERVER_TYPE || 'combined',},diff --git a/packages/runtime/src/index.ts b/packages/runtime/src/index.tsindex 04d7cf27..89035c9f 100644--- a/packages/runtime/src/index.ts+++ b/packages/runtime/src/index.ts@@ -36,7 +36,7 @@ const port = config.env.PORT;const getDefaultDataPath = () => {const homeDir = os.homedir();- return path.join(homeDir, 'smyth-ui-data');+ return path.join(homeDir, 'smythos-data');};const ensureVaultFileExists = () => {