cal.com icon indicating copy to clipboard operation
cal.com copied to clipboard

.env for root URL behavior+plausible #6193

Open Hybes opened this issue 2 years ago • 3 comments

What does this PR do?

Adds 2 .env variables for Self Hosted Plausible URL, as well as root url to redirect users if they access the booking url without a session, this could be set to a particular users booking page, or to a landing page.

Fixes #6193

Environment: Staging(main branch) / Production

Type of change

  • [✓ ] New feature (non-breaking change which adds functionality)
  • [ ✓] This change requires a documentation update

How should this be tested?

Configure the two new .env variables:

PLAUSIBLE_URL ROOT_REDIR_URL

  • You can see that traffic now sends to the self hosted Plausible URL, though you must include the full URL address, including the .js file.
  • If you access the main WEBAPP_URL now without a session (incognito works), you should see you get redirected to the specified site.

Checklist

Hybes avatar Dec 28 '22 09:12 Hybes

@Hybes is attempting to deploy a commit to the cal Team on Vercel.

A member of the Team first needs to authorize it.

vercel[bot] avatar Dec 28 '22 09:12 vercel[bot]

updated to use env variables, not already in use, and to set default plausible URL

Hybes avatar Dec 28 '22 18:12 Hybes

@Hybes we're probably moving all the app settings into a database to not overload our .env

our goal is to have as little .env variables as possible and adding each app-settings into it doesn't seem like a good idea.

will keep this open but we're likely not merging it in this state -- instead we'll implement an "App Manager" where you can change the settings per instance

PeerRich avatar Jan 01 '23 13:01 PeerRich