Skip to content

Commit 77c7dbe

Browse files
committed
Revert "docs(portal): strip unreleased domain config keys from B16"
This reverts commit cb06161.
1 parent cb06161 commit 77c7dbe

2 files changed

Lines changed: 36 additions & 6 deletions

File tree

portal/install/custom-domain.mdx

Lines changed: 26 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: "Custom Domain Configuration"
33
description: "Configure a custom domain for the Tyk Developer Portal, with DNS records, TLS certificates, and nginx reverse proxy setup for a branded HTTPS URL."
44
sidebarTitle: "Custom Domain"
5-
keywords: "Developer Portal, custom domain, HTTPS, TLS, DNS, CNAME, A record, nginx, reverse proxy"
5+
keywords: "Developer Portal, custom domain, HTTPS, TLS, DNS, CNAME, A record, nginx, reverse proxy, PORTAL_DOMAIN_DEFAULT, PORTAL_DOMAIN_ENABLE_CUSTOM"
66
---
77

88
| Edition | Deployment Type |
@@ -15,8 +15,9 @@ keywords: "Developer Portal, custom domain, HTTPS, TLS, DNS, CNAME, A record, ng
1515

1616
By default, the Developer Portal is accessible on the hostname or IP address of the server it runs on. A custom domain lets you expose the Live Portal on a URL you control, such as `developers.mycompany.com`, so API consumers see a branded, professional address.
1717

18-
Configuring a custom domain involves two steps:
18+
Configuring a custom domain involves three steps:
1919

20+
- Setting the domain in the Portal configuration
2021
- Creating a DNS record that points your domain to the Portal
2122
- Configuring TLS so the Portal is accessible over HTTPS
2223

@@ -27,6 +28,24 @@ Configuring a custom domain involves two steps:
2728
- Access to your DNS provider to create records
2829
- A valid TLS certificate and private key for your domain
2930

31+
## Configure the Portal Domain
32+
33+
Two configuration keys control custom domain behavior:
34+
35+
| Config Key | Description |
36+
| :--------- | :---------- |
37+
| [`Domain.EnableCustomDomains`](/product-stack/tyk-enterprise-developer-portal/deploy/configuration#portal-domain-enable-custom) | Enables custom domain support. Set to `true`. Env var: `PORTAL_DOMAIN_ENABLE_CUSTOM`. |
38+
| [`Domain.DefaultDomain`](/product-stack/tyk-enterprise-developer-portal/deploy/configuration#portal-domain-default) | The domain consumers use to access the Live Portal, for example `developers.mycompany.com`. Env var: `PORTAL_DOMAIN_DEFAULT`. |
39+
40+
Add these to your Portal configuration. For how to pass environment variables in your deployment type, see the install guide for [Docker](/portal/install/docker), [Kubernetes](/portal/install/kubernetes), or [Linux](/portal/install/linux).
41+
42+
```ini
43+
PORTAL_DOMAIN_ENABLE_CUSTOM=true
44+
PORTAL_DOMAIN_DEFAULT=developers.mycompany.com
45+
```
46+
47+
Restart the Portal after making this change.
48+
3049
## Configure DNS
3150

3251
Create a DNS record at your DNS provider that points your custom domain to the Portal:
@@ -132,9 +151,10 @@ After restarting the Portal with the updated configuration:
132151

133152
To change the custom domain after the initial setup:
134153

135-
1. **Create a DNS record** pointing the new domain to the Portal (A record or CNAME, as described above).
136-
2. **Update your TLS certificate** to cover the new domain, either in `PORTAL_TLS_CERTIFICATES` or on your reverse proxy.
137-
3. **Restart the Portal** to apply the changes.
154+
1. **Update `PORTAL_DOMAIN_DEFAULT`** to the new domain value.
155+
2. **Create a DNS record** pointing the new domain to the Portal (A record or CNAME, as described above).
156+
3. **Update your TLS certificate** to cover the new domain, either in `PORTAL_TLS_CERTIFICATES` or on your reverse proxy.
157+
4. **Restart the Portal** to apply the changes.
138158

139159
## Troubleshooting
140160

@@ -143,7 +163,7 @@ To change the custom domain after the initial setup:
143163
Check that the `Name` field in `PORTAL_TLS_CERTIFICATES` matches the domain exactly, including the subdomain. If you are using a reverse proxy, confirm the proxy certificate covers your custom domain and has not expired.
144164
</Accordion>
145165
<Accordion title="The Portal still serves on the old hostname">
146-
Confirm that your DNS record is pointing to the correct IP address or hostname and that DNS propagation has completed. If you are using a reverse proxy, verify that `X-Forwarded-Host` is set to your custom domain on every request.
166+
Confirm that `PORTAL_DOMAIN_ENABLE_CUSTOM` is set to `true` and that `PORTAL_DOMAIN_DEFAULT` is set to your custom domain. Restart the Portal after making any changes to environment variables.
147167
</Accordion>
148168
<Accordion title="SSO callbacks or email links use the wrong host or scheme">
149169
The Portal constructs base URLs from the `X-Forwarded-Host` and `X-Forwarded-Proto` headers. If these headers are missing or set incorrectly, callbacks and links will use the wrong host or scheme. Check that your reverse proxy sets both headers on every request. See [Single Sign On](/tyk-stack/tyk-developer-portal/enterprise-developer-portal/managing-access/enable-sso) for SSO configuration details.

product-stack/tyk-enterprise-developer-portal/deploy/configuration.mdx

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -285,6 +285,16 @@ You can specify any string value in this setting. Omit this setting if you don't
285285
**Type:** `string` <br/>
286286
**Description**: Redirects the portal login page to a custom SSO login URL. When set, GET requests to `/auth/password/login` are automatically redirected to this URL, and the portal's "Log in" button points to it. This is useful when using an Identity Provider (IDP) based login/SSO profile, as it allows you to bypass the default portal password login page and direct users to your external IDP login page instead. This setting only affects the login page redirect; user registration and password reset pages remain unchanged.
287287

288+
### PORTAL_DOMAIN_ENABLE_CUSTOM
289+
**Config file:** Domain.EnableCustomDomains <br/>
290+
**Type:** `boolean` <br/>
291+
**Description**: Enables custom domain support for the Developer Portal. When set to `true`, the portal uses the domain specified in `PORTAL_DOMAIN_DEFAULT` as the public-facing URL for the Live Portal instead of inferring it from incoming request headers. The default value is `false`.
292+
293+
### PORTAL_DOMAIN_DEFAULT
294+
**Config file:** Domain.DefaultDomain <br/>
295+
**Type:** `string` <br/>
296+
**Description**: The custom domain that API consumers use to access the Live Portal, for example `developers.mycompany.com`. This setting takes effect only when `PORTAL_DOMAIN_ENABLE_CUSTOM` is set to `true`.
297+
288298
## Response Headers Configuration
289299
This section explains how to configure custom HTTP response headers that will be added to all responses from the Portal.
290300

0 commit comments

Comments
 (0)