fix fe types

This commit is contained in:
Aiden McClelland
2025-08-05 17:14:17 -06:00
parent 0d227e62dc
commit 3835562200
7 changed files with 49 additions and 38 deletions

View File

@@ -34,7 +34,7 @@ export function getAddresses(
if (local) {
hostnames.unshift({
kind: 'ip',
networkInterfaceId: 'lo',
gatewayId: 'lo',
public: false,
hostname: {
kind: 'local',
@@ -82,7 +82,7 @@ export function getAddresses(
nid:
hostnameKind === 'local'
? 'Local'
: `${h.networkInterfaceId} (${hostnameKind})`,
: `${h.gatewayId} (${hostnameKind})`,
url,
})
}

View File

@@ -2059,7 +2059,8 @@ export namespace Mock {
net: {
assignedPort: 80,
assignedSslPort: 443,
public: false,
publicEnabled: [],
privateDisabled: [],
},
options: {
addSsl: null,
@@ -2074,7 +2075,7 @@ export namespace Mock {
80: [
{
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'local',
@@ -2085,7 +2086,7 @@ export namespace Mock {
},
{
kind: 'ip',
networkInterfaceId: 'wlan0',
gatewayId: 'wlan0',
public: false,
hostname: {
kind: 'local',
@@ -2096,7 +2097,7 @@ export namespace Mock {
},
{
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'ipv4',
@@ -2107,7 +2108,7 @@ export namespace Mock {
},
{
kind: 'ip',
networkInterfaceId: 'wlan0',
gatewayId: 'wlan0',
public: false,
hostname: {
kind: 'ipv4',
@@ -2118,7 +2119,7 @@ export namespace Mock {
},
{
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'ipv6',
@@ -2130,7 +2131,7 @@ export namespace Mock {
},
{
kind: 'ip',
networkInterfaceId: 'wlan0',
gatewayId: 'wlan0',
public: false,
hostname: {
kind: 'ipv6',
@@ -2158,7 +2159,8 @@ export namespace Mock {
net: {
assignedPort: 8332,
assignedSslPort: null,
public: false,
publicEnabled: [],
privateDisabled: [],
},
options: {
addSsl: null,
@@ -2180,7 +2182,8 @@ export namespace Mock {
net: {
assignedPort: 8333,
assignedSslPort: null,
public: false,
publicEnabled: [],
privateDisabled: [],
},
options: {
addSsl: null,

View File

@@ -626,7 +626,7 @@ export type DependencyErrorTransitive = {
// export namespace RR041 {
// // ** domains **
// export type ClaimStart9ToReq = { networkInterfaceId: string } // net.domain.me.claim
// export type ClaimStart9ToReq = { gatewayId: string } // net.domain.me.claim
// export type ClaimStart9ToRes = null
// export type DeleteStart9ToReq = {} // net.domain.me.delete
@@ -639,7 +639,7 @@ export type DependencyErrorTransitive = {
// username: string | null
// password: string | null
// }
// networkInterfaceId: string
// gatewayId: string
// } // net.domain.add
// export type AddDomainRes = null

View File

@@ -556,6 +556,7 @@ export class MockApiService extends ApiService {
path: `/serverInfo/network/networkInterfaces/${id}`,
value: {
public: params.public,
secure: false,
ipInfo: {
name: params.name,
scopeId: 3,
@@ -630,7 +631,7 @@ export class MockApiService extends ApiService {
// path: '/serverInfo/network/start9To',
// value: {
// subdomain: 'xyz',
// networkInterfaceId: params.networkInterfaceId,
// gatewayId: params.gatewayId,
// },
// },
// ]
@@ -664,7 +665,7 @@ export class MockApiService extends ApiService {
// path: `/serverInfo/network/domains`,
// value: {
// [params.hostname]: {
// networkInterfaceId: params.networkInterfaceId,
// gatewayId: params.gatewayId,
// provider: params.provider.name,
// },
// },
@@ -1511,7 +1512,7 @@ export class MockApiService extends ApiService {
path: `/serverInfo/host/hostnameInfo/80/0`,
value: {
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'domain',
@@ -1628,7 +1629,7 @@ export class MockApiService extends ApiService {
path: `/packageData/${params.package}/hosts/${params.host}/hostnameInfo/80/0`,
value: {
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'domain',

View File

@@ -39,7 +39,8 @@ export const mockPatchData: DataModel = {
net: {
assignedPort: null,
assignedSslPort: 443,
public: false,
publicEnabled: [],
privateDisabled: [],
},
options: {
preferredExternalPort: 80,
@@ -57,7 +58,7 @@ export const mockPatchData: DataModel = {
80: [
{
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'local',
@@ -68,7 +69,7 @@ export const mockPatchData: DataModel = {
},
{
kind: 'ip',
networkInterfaceId: 'wlan0',
gatewayId: 'wlan0',
public: false,
hostname: {
kind: 'local',
@@ -79,7 +80,7 @@ export const mockPatchData: DataModel = {
},
{
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'ipv4',
@@ -90,7 +91,7 @@ export const mockPatchData: DataModel = {
},
{
kind: 'ip',
networkInterfaceId: 'wlan0',
gatewayId: 'wlan0',
public: false,
hostname: {
kind: 'ipv4',
@@ -101,7 +102,7 @@ export const mockPatchData: DataModel = {
},
{
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'ipv6',
@@ -113,7 +114,7 @@ export const mockPatchData: DataModel = {
},
{
kind: 'ip',
networkInterfaceId: 'wlan0',
gatewayId: 'wlan0',
public: false,
hostname: {
kind: 'ipv6',
@@ -136,7 +137,8 @@ export const mockPatchData: DataModel = {
},
networkInterfaces: {
eth0: {
public: false,
public: null,
secure: null,
ipInfo: {
name: 'Wired Connection 1',
scopeId: 1,
@@ -147,7 +149,8 @@ export const mockPatchData: DataModel = {
},
},
wlan0: {
public: false,
public: null,
secure: null,
ipInfo: {
name: 'Wireless Connection 1',
scopeId: 2,
@@ -161,7 +164,8 @@ export const mockPatchData: DataModel = {
},
},
wireguard1: {
public: false,
public: null,
secure: null,
ipInfo: {
name: 'StartTunnel',
scopeId: 2,
@@ -321,7 +325,8 @@ export const mockPatchData: DataModel = {
net: {
assignedPort: 80,
assignedSslPort: 443,
public: false,
publicEnabled: [],
privateDisabled: [],
},
options: {
addSsl: null,
@@ -336,7 +341,7 @@ export const mockPatchData: DataModel = {
80: [
{
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'local',
@@ -347,7 +352,7 @@ export const mockPatchData: DataModel = {
},
{
kind: 'ip',
networkInterfaceId: 'wlan0',
gatewayId: 'wlan0',
public: false,
hostname: {
kind: 'local',
@@ -358,7 +363,7 @@ export const mockPatchData: DataModel = {
},
{
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'ipv4',
@@ -369,7 +374,7 @@ export const mockPatchData: DataModel = {
},
{
kind: 'ip',
networkInterfaceId: 'wlan0',
gatewayId: 'wlan0',
public: false,
hostname: {
kind: 'ipv4',
@@ -380,7 +385,7 @@ export const mockPatchData: DataModel = {
},
{
kind: 'ip',
networkInterfaceId: 'eth0',
gatewayId: 'eth0',
public: false,
hostname: {
kind: 'ipv6',
@@ -392,7 +397,7 @@ export const mockPatchData: DataModel = {
},
{
kind: 'ip',
networkInterfaceId: 'wlan0',
gatewayId: 'wlan0',
public: false,
hostname: {
kind: 'ipv6',
@@ -420,7 +425,8 @@ export const mockPatchData: DataModel = {
net: {
assignedPort: 8332,
assignedSslPort: null,
public: false,
publicEnabled: [],
privateDisabled: [],
},
options: {
addSsl: null,
@@ -442,7 +448,8 @@ export const mockPatchData: DataModel = {
net: {
assignedPort: 8333,
assignedSslPort: null,
public: false,
publicEnabled: [],
privateDisabled: [],
},
options: {
addSsl: null,

View File

@@ -120,7 +120,7 @@ export class ConfigService {
if (local) {
hostnameInfo.unshift({
kind: 'ip',
networkInterfaceId: 'lo',
gatewayId: 'lo',
public: false,
hostname: {
kind: 'local',

View File

@@ -15,7 +15,7 @@ export type NetworkInfo = T.NetworkInfo & {
// @TODO 041
// start9To: {
// subdomain: string
// networkInterfaceId: string
// gatewayId: string
// } | null
// domains: {
// [key: string]: Domain