diff --git a/.env b/.env index ef5ce85cc8..8b4cfd0852 100644 --- a/.env +++ b/.env @@ -1,4 +1,3 @@ -DB_PASSWORD=changeme DATABASE_URL=postgres://postgres:changeme@db/windmill?sslmode=disable WM_IMAGE=ghcr.io/windmill-labs/windmill:main @@ -9,11 +8,5 @@ WM_LICENSE_KEY="" # WM_LICENSE_KEY=".." -# this is the url that your instance is publicly exposed to -WM_BASE_URL=http://localhost - # To use another port than :80, setup the Caddyfile and the caddy section of the docker-compose to your needs: https://caddyserver.com/docs/getting-started # To have caddy take care of automatic TLS - - -WM_REQUEST_SIZE_LIMIT=50097152 # 50MB (The size limit for any requests, including script/flow args inputs) diff --git a/README.md b/README.md index a7349c0cd2..eee63e130b 100644 --- a/README.md +++ b/README.md @@ -211,7 +211,6 @@ compiling from source or using without a postgres super user, see curl https://raw.githubusercontent.com/windmill-labs/windmill/main/docker-compose.yml -o docker-compose.yml curl https://raw.githubusercontent.com/windmill-labs/windmill/main/Caddyfile -o Caddyfile curl https://raw.githubusercontent.com/windmill-labs/windmill/main/.env -o .env -curl https://raw.githubusercontent.com/windmill-labs/windmill/main/oauth.json -o oauth.json docker compose up -d ``` @@ -377,7 +376,7 @@ it being synced automatically everyday. | INSTANCE_EVENTS_WEBHOOK | None | Webhook to notify of events such as new user added, signup/invite. Can hook back to windmill to send emails | | GLOBAL_CACHE_INTERVAL | 10\*60 | (Enterprise Edition only) Interval in seconds in between bucket sync of the cache. This interval \* 2 is the time at which you're guaranteed all the worker's caches are synced together. | Worker | | WORKER_TAGS | 'deno,go,python3,bash,flow,hub,dependency' | The worker groups assigned to that workers | Worker | -| DEDICATED_WORKER | None | Unique script to run on that worker. Has to be in the form of : | Worker | +| DEDICATED_WORKER | None | Unique script to run on that worker. Has to be in the form of : | Worker | | CUSTOM_TAGS | None | The custom tags assignable to scripts. | Server | | JOB_RETENTION_SECS | 60*60*24\*60 //60 days | The time in seconds after which jobs get deleted. Set to 0 or -1 to never delete | | WAIT_RESULT_FAST_POLL_INTERVAL_MS | 50 | The time in between polling for the run_wait_result endpoints in fast poll mode | Server | diff --git a/backend/migrations/20230921084441_add_default_worker_groups.down.sql b/backend/migrations/20230921084441_add_default_worker_groups.down.sql new file mode 100644 index 0000000000..d2f607c5b8 --- /dev/null +++ b/backend/migrations/20230921084441_add_default_worker_groups.down.sql @@ -0,0 +1 @@ +-- Add down migration script here diff --git a/backend/migrations/20230921084441_add_default_worker_groups.up.sql b/backend/migrations/20230921084441_add_default_worker_groups.up.sql new file mode 100644 index 0000000000..e6d2d70a6b --- /dev/null +++ b/backend/migrations/20230921084441_add_default_worker_groups.up.sql @@ -0,0 +1,4 @@ +-- Add up migration script here +INSERT INTO config (name, config) VALUES + ('worker__default', '{"worker_tags": ["deno", "python3", "go", "bash", "powershell", "dependency", "flow", "hub", "other", "bun"]}'), + ('worker__native', '{"worker_tags": ["nativets", "postgresql", "mysql", "graphql", "snowflake"]}') ON CONFLICT DO NOTHING; \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 7156ea1b94..4f236ee163 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -12,7 +12,7 @@ services: expose: - 5432 environment: - POSTGRES_PASSWORD: ${DB_PASSWORD} + POSTGRES_PASSWORD: changeme POSTGRES_DB: windmill healthcheck: test: ["CMD-SHELL", "pg_isready -U postgres"] @@ -30,21 +30,17 @@ services: - 8000 environment: - DATABASE_URL=${DATABASE_URL} - - BASE_URL=${WM_BASE_URL} - RUST_LOG=info ## You can set the number of workers to 1 and not need any separate worker service but not recommended - NUM_WORKERS=0 - DISABLE_SERVER=false - METRICS_ADDR=false # (ee only, if set to true, metrics will be exposed on port 8001) - - REQUEST_SIZE_LIMIT=${WM_REQUEST_SIZE_LIMIT} # LICENSE_KEY is only needed for the enterprise edition - LICENSE_KEY=${WM_LICENSE_KEY} depends_on: db: condition: service_healthy - volumes: - # See Oauth (https://docs.windmill.dev/docs/misc/setup_oauth) - - ./oauth.json:/usr/src/app/oauth.json + windmill_worker: image: ${WM_IMAGE} @@ -54,13 +50,11 @@ services: restart: unless-stopped environment: - DATABASE_URL=${DATABASE_URL} - - BASE_URL=${WM_BASE_URL} - RUST_LOG=info - DISABLE_SERVER=true - KEEP_JOB_DIR=false - METRICS_ADDR=false - # To handle all tags, remove the env variable altogether. If you do so, you can remove the windmill_worker_native containers. - - WORKER_TAGS=deno,python3,go,bash,powershell,dependency,flow,hub,other,bun + - WORKER_GROUP=default # LICENSE_KEY is only needed for the enterprise edition - LICENSE_KEY=${WM_LICENSE_KEY} depends_on: @@ -70,8 +64,6 @@ services: volumes: # mount the docker socket to allow to run docker containers from within the workers - /var/run/docker.sock:/var/run/docker.sock - # See Oauth (https://docs.windmill.dev/docs/misc/setup_oauth) - - ./oauth.json:/usr/src/app/oauth.json - worker_dependency_cache:/tmp/windmill/cache ## This worker is specialized for "native" jobs. They run in-process and can thus be parallelized to more than 1 at a time on a given worker which is why NUM_WORKERS is set to 4 @@ -88,22 +80,14 @@ services: restart: unless-stopped environment: - DATABASE_URL=${DATABASE_URL} - - BASE_URL=${WM_BASE_URL} - RUST_LOG=info - DISABLE_SERVER=true - - KEEP_JOB_DIR=false - METRICS_ADDR=false # (ee only, if set to true, metrics will be exposed on port 8001) - NUM_WORKERS=4 - - WORKER_TAGS=nativets,postgresql,mysql,graphql,snowflake - WORKER_GROUP=native - # LICENSE_KEY is only needed for the enterprise edition - # - LICENSE_KEY=${WM_LICENSE_KEY} depends_on: db: condition: service_healthy - volumes: - # See Oauth (https://docs.windmill.dev/docs/misc/setup_oauth) - - ./oauth.json:/usr/src/app/oauth.json lsp: diff --git a/frontend/src/lib/components/InstanceSettings.svelte b/frontend/src/lib/components/InstanceSettings.svelte index fb34131b02..7e5c76f8b6 100644 --- a/frontend/src/lib/components/InstanceSettings.svelte +++ b/frontend/src/lib/components/InstanceSettings.svelte @@ -42,12 +42,12 @@ fieldType: 'seconds', placeholder: '60', storage: 'setting', - cloudonly: true + cloudonly: false }, { label: 'Max Timeout for sync endpoints', key: 'timeout_wait_result', - cloudonly: false, + cloudonly: true, fieldType: 'seconds', placeholder: '60', storage: 'config' @@ -133,6 +133,9 @@ if (values['retention_period_secs'] == undefined) { values['retention_period_secs'] = 60 * 60 * 24 * 60 } + if (values['base_url'] == undefined) { + values['base_url'] = 'http://localhost' + } } async function saveSettings() { @@ -366,7 +369,6 @@ on:click={async () => { await saveSettings() sendUserToast('Settings updated') - dispatch('save') }}>Save
diff --git a/frontend/src/lib/components/WorkspaceGroup.svelte b/frontend/src/lib/components/WorkspaceGroup.svelte index f0be0cdd2a..7249be2244 100644 --- a/frontend/src/lib/components/WorkspaceGroup.svelte +++ b/frontend/src/lib/components/WorkspaceGroup.svelte @@ -175,7 +175,7 @@ size="xs" on:click={() => { if (nconfig != undefined) { - nconfig.worker_tags = nativeTags + nconfig.worker_tags = defaultTags dirty = true } }} diff --git a/frontend/src/routes/(root)/(logged)/user/(user)/instance_settings/+page.svelte b/frontend/src/routes/(root)/(logged)/user/(user)/instance_settings/+page.svelte index 627496666d..397f307a1b 100644 --- a/frontend/src/routes/(root)/(logged)/user/(user)/instance_settings/+page.svelte +++ b/frontend/src/routes/(root)/(logged)/user/(user)/instance_settings/+page.svelte @@ -2,8 +2,18 @@ import { goto } from '$app/navigation' import CenteredModal from '$lib/components/CenteredModal.svelte' import InstanceSettings from '$lib/components/InstanceSettings.svelte' + import { Button } from '$lib/components/common' - goto('/apps/get/g/all/setup_app')} /> + +

+ You can change these settings later in the superadmins settings but finishing setup will leave + this page. +

+
diff --git a/oauth.json b/oauth.json deleted file mode 100644 index 0967ef424b..0000000000 --- a/oauth.json +++ /dev/null @@ -1 +0,0 @@ -{}