#Help with Reverse Proxy Setup and Multiworkspace

1 messages · Page 1 of 1 (latest)

fickle dock
#

Help with Reverse Proxy Setup and Multiworkspace

stoic abyss
#

same issue here

fickle dock
#

apparently activating multiworkspace needs a whole lot of dependencies inside of the workspace container, try docker exec -it twenty-server-1 yarn and docker exec -it twenty-server-1 npx nx database:reset --configuration=no-seed afterwards but make sure to have a backup 🙂

#

explains a whole lot why the application wasnt loading after this

#

but the dns wildcard setup is pretty messy 😦

tame saffron
#

Also I would not recommend installing dev dependencies in your production container

#

Meaning you should not run NX command in prod but rather use shiped in available yarn scripts

#

Are you still facing issue with your reverse proxy ?

fickle dock
#

hi @tame saffron - thanks for the quick question.. i would try a fresh reinstallation today without any dev/nx commands.

fickle dock
tame saffron
#

That's why we need a wildcard

fickle dock
#

is there any possibility to set the multiworkspace urls beforehead? that would save some time because we aren't doing wildcard le certificates.

#

or at least make them "guessable"

tame saffron
#

Unfortunately I don't think so 🤔

#

We're currently working on workspace import export as code

#

Such a behavior might be available by the end of Q3

fickle dock
#

yeah, that would be super cool

tame saffron
#

Even though the first import/export feature will be very workspace scoped

#

Until now what I would do is programmatically call the api setting a custom domain

#

Within a script

fickle dock
#

oh this would totally work for me

tame saffron
#

With a deterministic payload

fickle dock
#

Late catchup, solved it like this without Wildcard Subdomains:

#0 Create DNS Records of Reverse Proxy beforehead (app.crm, crm.)
#1 Fresh Install of TwentyCRM without Multiworkspace enabled
#2 Create a first User
#3 Reconfigure for Multiworkspace, Restart Containers
#4 Try opening app.crm.. now - You'll be redirected to a non-existent Subdomain
#5 Add the newly spawned url (email-uid.app.crm.) to Reverse Proxy URL
#6 Login to your new CRM with the new URL
#7 Change the domain in Settings -> Generic -> Change Domain to your liking and add to your Reverse Proxy
#8 Repeat steps 5-7 for each new Multi-Workspace
#9 ???
#10 profit 🙂

#

Thus, predictable Subdomain URLs for new Workspaces would be a great great thing

sage narwhal
#

Hi @fickle dock , I think I'm running into the same problem when hosting on AWS ECS with the Twenty docker image. Before enabling IS_MULTIWORKSPACE_ENABLED in the environment variables, I had no issue. After, I'm getting the "app.<aws load balancer string>" url popping up. I found the subdomain for the workspace in DB -> "radiant-bronze-peacock".

What should the url from step #5 look like? "radiant-bronze-peacock.app.<aws load balancer string>" isn't working, neither is removing "app" from the url string.

sage narwhal
#

It seems like I may need to set up subdomain access in my load balancer as well