diff --git a/src/apps/auth/server/gql/cli-queries.ts b/src/apps/auth/server/gql/cli-queries.ts index 014eb3ce0..f56cee3cb 100644 --- a/src/apps/auth/server/gql/cli-queries.ts +++ b/src/apps/auth/server/gql/cli-queries.ts @@ -540,33 +540,40 @@ export const cliQueries = (executor: IExecutor) => ({ ), cli_listDevices: executor( gql` - query Core_listVPNDevicesForUser { - core_listVPNDevicesForUser { - displayName - environmentName - markedForDeletion - metadata { - name - namespace - } - projectName - spec { - cnameRecords { - host - target - } - deviceNamespace - disabled - ports { - port - targetPort + query Infra_listVPNDevices($pq: CursorPaginationIn) { + infra_listVPNDevices(pq: $pq) { + edges { + node { + displayName + metadata { + name + } + spec { + deviceNamespace + disabled + nodeSelector + ports { + port + targetPort + } + } + status { + isReady + message { + RawMessage + } + } + wireguardConfig { + encoding + value + } } } } } `, { - transformer: (data: any) => data.core_listVPNDevicesForUser, + transformer: (data: any) => data.infra_listVPNDevices, vars: (_: any) => {}, } ), diff --git a/src/apps/auth/server/gql/queries/infra-queries.ts b/src/apps/auth/server/gql/queries/infra-queries.ts index 7e77e903a..565cd03d8 100644 --- a/src/apps/auth/server/gql/queries/infra-queries.ts +++ b/src/apps/auth/server/gql/queries/infra-queries.ts @@ -21,31 +21,33 @@ export const infraQueries = (executor: IExecutor) => ({ ), cli_listCoreDevices: executor( gql` - query Core_listVPNDevices($pq: CursorPaginationIn) { - core_listVPNDevices(pq: $pq) { - edges { - cursor - node { - displayName - environmentName - metadata { - name - } - projectName - spec { - disabled - ports { - port - targetPort - } - } + query Core_listVPNDevicesForUser { + core_listVPNDevicesForUser { + displayName + environmentName + markedForDeletion + metadata { + name + namespace + } + projectName + spec { + cnameRecords { + host + target + } + deviceNamespace + disabled + ports { + port + targetPort } } } } `, { - transformer: (data: any) => data.core_listVPNDevices, + transformer: (data: any) => data.core_listVPNDevicesForUser, vars: (_: any) => {}, } ),