feat(custom-domains): allow to register a custom domain (without UI) (#9879)
# In this PR - Allow to register a custom domain - Refacto subdomain generation # In other PRs - Add UI to deal with a custom domain - Add logic to work with custom domain
This commit is contained in:
@ -10,6 +10,7 @@ export const CHECK_USER_EXISTS = gql`
|
||||
id
|
||||
displayName
|
||||
subdomain
|
||||
hostname
|
||||
logo
|
||||
sso {
|
||||
type
|
||||
|
||||
@ -7,6 +7,7 @@ export const GET_PUBLIC_WORKSPACE_DATA_BY_SUBDOMAIN = gql`
|
||||
logo
|
||||
displayName
|
||||
subdomain
|
||||
hostname
|
||||
authProviders {
|
||||
sso {
|
||||
id
|
||||
|
||||
@ -20,6 +20,7 @@ export type CurrentWorkspace = Pick<
|
||||
| 'isPasswordAuthEnabled'
|
||||
| 'hasValidEnterpriseKey'
|
||||
| 'subdomain'
|
||||
| 'hostname'
|
||||
| 'metadataVersion'
|
||||
>;
|
||||
|
||||
|
||||
@ -158,6 +158,7 @@ export const queries = {
|
||||
isPasswordAuthEnabled
|
||||
subdomain
|
||||
hasValidEnterpriseKey
|
||||
hostname
|
||||
featureFlags {
|
||||
id
|
||||
key
|
||||
@ -307,6 +308,7 @@ export const responseData = {
|
||||
isMicrosoftAuthEnabled: false,
|
||||
isPasswordAuthEnabled: true,
|
||||
subdomain: 'test',
|
||||
hostname: null,
|
||||
featureFlags: [],
|
||||
metadataVersion: 1,
|
||||
currentBillingSubscription: null,
|
||||
|
||||
@ -37,6 +37,7 @@ export const USER_QUERY_FRAGMENT = gql`
|
||||
isPasswordAuthEnabled
|
||||
subdomain
|
||||
hasValidEnterpriseKey
|
||||
hostname
|
||||
featureFlags {
|
||||
id
|
||||
key
|
||||
|
||||
@ -4,6 +4,7 @@ export const UPDATE_WORKSPACE = gql`
|
||||
mutation UpdateWorkspace($input: UpdateWorkspaceInput!) {
|
||||
updateWorkspace(data: $input) {
|
||||
id
|
||||
hostname
|
||||
subdomain
|
||||
displayName
|
||||
logo
|
||||
|
||||
@ -0,0 +1,22 @@
|
||||
import { gql } from '@apollo/client';
|
||||
|
||||
export const GET_HOSTNAME_DETAILS = gql`
|
||||
query GetHostnameDetails {
|
||||
getHostnameDetails {
|
||||
hostname
|
||||
ownershipVerifications {
|
||||
... on CustomHostnameOwnershipVerificationTxt {
|
||||
type
|
||||
name
|
||||
value
|
||||
}
|
||||
... on CustomHostnameOwnershipVerificationHttp {
|
||||
type
|
||||
body
|
||||
url
|
||||
}
|
||||
}
|
||||
status
|
||||
}
|
||||
}
|
||||
`;
|
||||
Reference in New Issue
Block a user