init
This commit is contained in:
parent
b7722a7aa4
commit
6389c948af
@ -1,8 +1,11 @@
|
|||||||
TYPE=nocodb
|
TYPE=nocodb
|
||||||
|
|
||||||
DOMAIN=nocodb.example.com
|
DOMAIN={{ .Domain }}
|
||||||
|
|
||||||
## Domain aliases
|
## Domain aliases
|
||||||
#EXTRA_DOMAINS=', `www.nocodb.example.com`'
|
#EXTRA_DOMAINS=', `www.nocodb.example.com`'
|
||||||
|
|
||||||
LETS_ENCRYPT_ENV=production
|
LETS_ENCRYPT_ENV=production
|
||||||
|
|
||||||
|
SECRET_DB_PASSWORD_VERSION=v1
|
||||||
|
SECRET_NC_DB_URL_VERSION=v1
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
# nocodb
|
# nocodb
|
||||||
|
|
||||||
> One line description of the recipe
|
> NocoDB is a no-code database platform that allows teams to collaborate and build applications with ease of a familiar and intuitive spreadsheet interface. This allows even non-developers or business users to become software creators.
|
||||||
|
|
||||||
<!-- metadata -->
|
<!-- metadata -->
|
||||||
|
|
||||||
@ -17,8 +17,11 @@
|
|||||||
|
|
||||||
## Quick start
|
## Quick start
|
||||||
|
|
||||||
* `abra app new nocodb --secrets`
|
* `abra app new nocodb`
|
||||||
* `abra app config <app-name>`
|
* `abra app config <app-name>`
|
||||||
|
* `export DATABASE_PW=$(pwgen 20)`
|
||||||
|
* `abra app secret insert <app-name> db_password v1 ${DATABASE_PW}`
|
||||||
|
* `abra app secret insert <app-name> nc_db_url v1 pg://db:5432?u=nocodb&p=${DATABASE_PW}&d=nocodb`
|
||||||
* `abra app deploy <app-name>`
|
* `abra app deploy <app-name>`
|
||||||
|
|
||||||
For more, see [`docs.coopcloud.tech`](https://docs.coopcloud.tech).
|
For more, see [`docs.coopcloud.tech`](https://docs.coopcloud.tech).
|
||||||
|
47
compose.yml
47
compose.yml
@ -3,15 +3,24 @@ version: "3.8"
|
|||||||
|
|
||||||
services:
|
services:
|
||||||
app:
|
app:
|
||||||
image: nginx:1.20.0
|
image: nocodb/nocodb:latest
|
||||||
|
secrets:
|
||||||
|
- nc_db_url
|
||||||
networks:
|
networks:
|
||||||
- proxy
|
- proxy
|
||||||
|
- internal
|
||||||
|
environment:
|
||||||
|
DATABASE_URL_FILE: /run/secrets/nc_db_url
|
||||||
|
NC_PUBLIC_URL: https://${DOMAIN}
|
||||||
|
NC_DISABLE_TELE: "true"
|
||||||
|
volumes:
|
||||||
|
- data:/usr/app/data
|
||||||
deploy:
|
deploy:
|
||||||
restart_policy:
|
restart_policy:
|
||||||
condition: on-failure
|
condition: on-failure
|
||||||
labels:
|
labels:
|
||||||
- "traefik.enable=true"
|
- "traefik.enable=true"
|
||||||
- "traefik.http.services.${STACK_NAME}.loadbalancer.server.port=80"
|
- "traefik.http.services.${STACK_NAME}.loadbalancer.server.port=8080"
|
||||||
- "traefik.http.routers.${STACK_NAME}.rule=Host(`${DOMAIN}`${EXTRA_DOMAINS})"
|
- "traefik.http.routers.${STACK_NAME}.rule=Host(`${DOMAIN}`${EXTRA_DOMAINS})"
|
||||||
- "traefik.http.routers.${STACK_NAME}.entrypoints=web-secure"
|
- "traefik.http.routers.${STACK_NAME}.entrypoints=web-secure"
|
||||||
- "traefik.http.routers.${STACK_NAME}.tls.certresolver=${LETS_ENCRYPT_ENV}"
|
- "traefik.http.routers.${STACK_NAME}.tls.certresolver=${LETS_ENCRYPT_ENV}"
|
||||||
@ -20,13 +29,39 @@ services:
|
|||||||
#- "traefik.http.middlewares.${STACK_NAME}-redirect.headers.SSLForceHost=true"
|
#- "traefik.http.middlewares.${STACK_NAME}-redirect.headers.SSLForceHost=true"
|
||||||
#- "traefik.http.middlewares.${STACK_NAME}-redirect.headers.SSLHost=${DOMAIN}"
|
#- "traefik.http.middlewares.${STACK_NAME}-redirect.headers.SSLHost=${DOMAIN}"
|
||||||
- "coop-cloud.${STACK_NAME}.version="
|
- "coop-cloud.${STACK_NAME}.version="
|
||||||
|
|
||||||
|
db:
|
||||||
|
image: postgres:12.1-alpine
|
||||||
|
secrets:
|
||||||
|
- db_password
|
||||||
|
networks:
|
||||||
|
- internal
|
||||||
|
environment:
|
||||||
|
POSTGRES_USER: nocodb
|
||||||
|
POSTGRES_PASSWORD_FILE: /run/secrets/db_password
|
||||||
|
POSTGRES_DB: nocodb
|
||||||
|
volumes:
|
||||||
|
- db:/var/lib/postgresql/data
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD", "curl", "-f", "http://localhost"]
|
test: pg_isready -U ${DATABASE_USER} -d ${DATABASE_NAME}
|
||||||
interval: 30s
|
interval: 10s
|
||||||
timeout: 10s
|
timeout: 2s
|
||||||
retries: 10
|
retries: 10
|
||||||
start_period: 1m
|
|
||||||
|
volumes:
|
||||||
|
data:
|
||||||
|
db:
|
||||||
|
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
proxy:
|
proxy:
|
||||||
external: true
|
external: true
|
||||||
|
internal:
|
||||||
|
|
||||||
|
secrets:
|
||||||
|
db_password:
|
||||||
|
external: true
|
||||||
|
name: ${STACK_NAME}_db_password_${SECRET_DB_PASSWORD_VERSION}
|
||||||
|
nc_db_url:
|
||||||
|
external: true
|
||||||
|
name: ${STACK_NAME}_nc_db_url_${SECRET_NC_DB_URL_VERSION}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user