Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fast follows on 0.34 #9034

Merged
merged 6 commits into from
Dec 12, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions packages/twenty-docker/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ PG_DATABASE_HOST=db:5432
REDIS_URL=redis://redis:6379

SERVER_URL=http://localhost:3000
FRONT_DOMAIN=localhost
FRONT_PORT=3000
FRONT_PROTOCOL=http

# Use openssl rand -base64 32 for each secret
# APP_SECRET=replace_me_with_a_random_string
Expand Down
9 changes: 6 additions & 3 deletions packages/twenty-docker/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,9 @@ services:
PORT: 3000
PG_DATABASE_URL: postgres://${PGUSER_SUPERUSER:-postgres}:${PGPASSWORD_SUPERUSER:-postgres}@${PG_DATABASE_HOST:-db:5432}/default
SERVER_URL: ${SERVER_URL}
FRONT_BASE_URL: ${FRONT_BASE_URL:-$SERVER_URL}
FRONT_DOMAIN: ${FRONT_DOMAIN}
Weiko marked this conversation as resolved.
Show resolved Hide resolved
FRONT_PORT: ${FRONT_PORT}
FRONT_PROTOCOL: ${FRONT_PROTOCOL}
Weiko marked this conversation as resolved.
Show resolved Hide resolved
REDIS_URL: ${REDIS_URL:-redis://redis:6379}

ENABLE_DB_MIGRATIONS: "true"
Expand Down Expand Up @@ -54,9 +56,10 @@ services:
environment:
PG_DATABASE_URL: postgres://${PGUSER_SUPERUSER:-postgres}:${PGPASSWORD_SUPERUSER:-postgres}@${PG_DATABASE_HOST:-db:5432}/default
SERVER_URL: ${SERVER_URL}
FRONT_BASE_URL: ${FRONT_BASE_URL:-$SERVER_URL}
FRONT_DOMAIN: ${FRONT_DOMAIN}
Weiko marked this conversation as resolved.
Show resolved Hide resolved
FRONT_PORT: ${FRONT_PORT}
FRONT_PROTOCOL: ${FRONT_PROTOCOL}
Weiko marked this conversation as resolved.
Show resolved Hide resolved
REDIS_URL: ${REDIS_URL:-redis://redis:6379}

ENABLE_DB_MIGRATIONS: "false" # it already runs on the server

STORAGE_TYPE: ${STORAGE_TYPE}
Expand Down
8 changes: 6 additions & 2 deletions packages/twenty-docker/k8s/manifests/deployment-server.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,12 @@ spec:
value: 3000
- name: SERVER_URL
value: "https://crm.example.com:443"
Weiko marked this conversation as resolved.
Show resolved Hide resolved
- name: FRONT_BASE_URL
value: "https://crm.example.com:443"
- name: FRONT_DOMAIN
Weiko marked this conversation as resolved.
Show resolved Hide resolved
value: "crm.example.com"
- name: FRONT_PORT
value: "443"
Weiko marked this conversation as resolved.
Show resolved Hide resolved
- name: FRONT_PROTOCOL
value: "https"
- name: "PG_DATABASE_URL"
value: "postgres://postgres:[email protected]/default"
- name: "REDIS_URL"
Expand Down
8 changes: 6 additions & 2 deletions packages/twenty-docker/k8s/manifests/deployment-worker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,12 @@ spec:
env:
- name: SERVER_URL
value: "https://crm.example.com:443"
- name: FRONT_BASE_URL
value: "https://crm.example.com:443"
- name: FRONT_DOMAIN
value: "crm.example.com"
- name: FRONT_PORT
value: "443"
- name: FRONT_PROTOCOL
value: "https"
- name: PG_DATABASE_URL
value: "postgres://postgres:[email protected]/default"
Weiko marked this conversation as resolved.
Show resolved Hide resolved
- name: ENABLE_DB_MIGRATIONS
Expand Down
2 changes: 1 addition & 1 deletion packages/twenty-docker/k8s/terraform/deployment-server.tf
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ resource "kubernetes_deployment" "twentycrm_server" {
}

env {
name = "FRONT_BASE_URL"
name = "FRONT_DOMAIN"
value = var.twentycrm_app_hostname
Weiko marked this conversation as resolved.
Show resolved Hide resolved
}
Weiko marked this conversation as resolved.
Show resolved Hide resolved

Expand Down
2 changes: 1 addition & 1 deletion packages/twenty-docker/k8s/terraform/deployment-worker.tf
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ resource "kubernetes_deployment" "twentycrm_worker" {
}

env {
name = "FRONT_BASE_URL"
name = "FRONT_DOMAIN"
value = var.twentycrm_app_hostname
}

Expand Down
5 changes: 5 additions & 0 deletions packages/twenty-docker/k8s/terraform/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ variable "twentycrm_app_hostname" {
description = "The protocol, DNS fully qualified hostname, and port used to access TwentyCRM in your environment. Ex: https://crm.example.com:443"
}

variable "front_domain" {
Weiko marked this conversation as resolved.
Show resolved Hide resolved
type = string
description = "The protocol, DNS fully qualified hostname, and port used to access TwentyCRM in your environment. Ex: https://crm.example.com:443"
}
Weiko marked this conversation as resolved.
Show resolved Hide resolved

######################
# Optional Variables #
######################
Expand Down
2 changes: 0 additions & 2 deletions packages/twenty-server/.env.example
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
PG_DATABASE_URL=postgres://postgres:postgres@localhost:5432/default
REDIS_URL=redis://localhost:6379

FRONT_BASE_URL=http://localhost:3001

APP_SECRET=replace_me_with_a_random_string
SIGN_IN_PREFILLED=true

Expand Down
1 change: 0 additions & 1 deletion packages/twenty-server/.env.test
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ REDIS_URL=redis://localhost:6379

DEBUG_MODE=true
DEBUG_PORT=9000
FRONT_BASE_URL=http://localhost:3001
APP_SECRET=replace_me_with_a_random_string
Weiko marked this conversation as resolved.
Show resolved Hide resolved
SIGN_IN_PREFILLED=true
EXCEPTION_HANDLER_DRIVER=console
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,12 @@ yarn command:prod upgrade-0.34
The `yarn database:migrate:prod` command will apply the migrations to the database structure (core and metadata schemas)
The `yarn command:prod upgrade-0.34` takes care of the data migration of all workspaces.

**Environment Variables**

We have updated the way we handle the Redis connection.
Weiko marked this conversation as resolved.
Show resolved Hide resolved

- Removed: `FRONT_BASE_URL`
- Added: `FRONT_DOMAIN`, `FRONT_PROTOCOL`, `FRONT_PORT`

### v0.32.0 to v0.33.0

Expand Down
Loading