Skip to content

Commit

Permalink
feat: self host minimal
Browse files Browse the repository at this point in the history
  • Loading branch information
rubenfiszel committed May 8, 2022
1 parent 7a51f84 commit 2c70a15
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 4 deletions.
1 change: 0 additions & 1 deletion .env
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
SITE_URL=localhost
DB_PASSWORD=changeme
POSTGRES_VERSION=13.3.0
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,12 @@ Windmill is <b>fully open-sourced</b>:

## How to self-host

Complete instructions coming soon
`docker-compose up` with the following docker-compose is sufficient:
<https://github.com/windmill-labs/windmill-server/blob/main/docker-compose.yml>

The default super-admin user is: admin@windmill.dev

From there, you can create other users.

## Copyright

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
-- Add down migration script here
24 changes: 24 additions & 0 deletions backend/migrations/20220508152326_create_role_if_not_exists.up.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
-- Add up migration script here
DO
$do$
BEGIN
IF NOT EXISTS (
SELECT
FROM pg_catalog.pg_roles
WHERE rolname = 'app') THEN
CREATE ROLE app LOGIN PASSWORD 'changeme';
END IF;
END
$do$;

DO
$do$
BEGIN
IF NOT EXISTS (
SELECT
FROM pg_catalog.pg_roles
WHERE rolname = 'admin') THEN
CREATE ROLE admin LOGIN PASSWORD 'changeme';
END IF;
END
$do$;
11 changes: 9 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,20 @@ services:
timeout: 5s
retries: 5
windmill:
image: windmill:main
image: ghcr.io/windmill-labs/windmill:main
privileged: true
restart: unless-stopped
ports:
- 8000:8000
environment:
- DATABASE_URL=postgres://postgres:${DB_PASSWORD}@db/windmill?sslmode=disable
- VARIABLES_KEY=changeme
- APP_USER_PASSWORD=changeme
- BASE_URL=https://localhost"
- BASE_INTERNAL_URL=http://localhost:8000"
- RUST_LOG=info
- NUM_WORKERS=3
- RUST_BACKTRACE=1

depends_on:
db:
condition: service_healthy
Expand Down

0 comments on commit 2c70a15

Please sign in to comment.