Skip to content

The open alternative to Salesforce, designed for AI.

Migrate database to default locally

Charles Bochet6fa71e12b5c5
diff --git a/infra/dev/docker-compose.yml b/infra/dev/docker-compose.yml
index f6d8fe0fc99..bd49883d47a 100644
--- a/infra/dev/docker-compose.yml
+++ b/infra/dev/docker-compose.yml
@@ -26,7 +26,7 @@ services:
restart: always
environment:
HASURA_GRAPHQL_METADATA_DATABASE_URL: postgres://postgres:postgrespassword@postgres:5432/hasura
- HASURA_GRAPHQL_PG_DATABASE_URL: postgres://postgres:postgrespassword@postgres:5432/twenty
+ HASURA_GRAPHQL_PG_DATABASE_URL: postgres://postgres:postgrespassword@postgres:5432/default
HASURA_GRAPHQL_ENABLE_CONSOLE: "false"
HASURA_GRAPHQL_DEV_MODE: "true"
HASURA_GRAPHQL_ENABLED_LOG_TYPES: startup, http-log, webhook-log, websocket-log, query-log
@@ -38,7 +38,7 @@ services:
- "4000:4000"
environment:
HASURA_GRAPHQL_JWT_SECRET: '{"type":"HS256", "key": "jwt-very-long-hard-to-guess-secret"}'
- HASURA_GRAPHQL_DATABASE_URL: postgres://postgres:postgrespassword@postgres:5432/twenty
+ HASURA_GRAPHQL_DATABASE_URL: postgres://postgres:postgrespassword@postgres:5432/default
HASURA_GRAPHQL_GRAPHQL_URL: http://twenty-hasura:8080/v1/graphql
HASURA_GRAPHQL_ADMIN_SECRET: secret
npm_package_version: '0'
diff --git a/infra/dev/postgres/init.sql b/infra/dev/postgres/init.sql
index b53c8220af0..6d5be3420fe 100644
--- a/infra/dev/postgres/init.sql
+++ b/infra/dev/postgres/init.sql
@@ -1,8 +1,8 @@
-CREATE DATABASE twenty;
+CREATE DATABASE "default";
CREATE DATABASE hasura;
-- From: https://raw.githubusercontent.com/nhost/hasura-auth/main/docker/initdb.d/0001-create-schema.sql
-\c twenty;
+\c default;
-- auth schema
CREATE SCHEMA IF NOT EXISTS auth;
-- https://github.com/hasura/graphql-engine/issues/3657