Skip to content

Commit

Permalink
fix(vm_config): add hostSshPort and vmSshPort to Nox's vmConfig (#1016)
Browse files Browse the repository at this point in the history
* fix(vm_config): add hostSshPort and vmSshPort to Nox's vmConfig

* Apply automatic changes

* Apply suggestions from code review

* Apply automatic changes

---------

Co-authored-by: folex <[email protected]>
  • Loading branch information
folex and folex committed Sep 2, 2024
1 parent 971e60e commit 38a281b
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 12 deletions.
28 changes: 16 additions & 12 deletions cli/docs/configs/provider.md
Original file line number Diff line number Diff line change
Expand Up @@ -345,12 +345,14 @@ VM Network Configuration

**Properties**

| Property | Type | Required | Description |
|--------------|----------------------|----------|------------------------------------------------------------------|
| `publicIp` | string | **Yes** | Public IP address to assign the VM. Must be publicly accessible. |
| `bridgeName` | string | No | Name of the network bridge device |
| `portRange` | [object](#portrange) | No | iptables-mapped port range from Host to VM |
| `vmIp` | string | No | Internal IP address to assign the VM |
| Property | Type | Required | Description |
|---------------|----------------------|----------|------------------------------------------------------------------|
| `publicIp` | string | **Yes** | Public IP address to assign the VM. Must be publicly accessible. |
| `bridgeName` | string | No | Name of the network bridge device |
| `hostSshPort` | integer | No | Host SSH port, default is 922 |
| `portRange` | [object](#portrange) | No | iptables-mapped port range from Host to VM |
| `vmIp` | string | No | Internal IP address to assign the VM |
| `vmSshPort` | integer | No | VM SSH port, default is 22 |

**portRange**

Expand Down Expand Up @@ -534,12 +536,14 @@ VM Network Configuration

##### Properties

| Property | Type | Required | Description |
|--------------|----------------------|----------|------------------------------------------------------------------|
| `publicIp` | string | **Yes** | Public IP address to assign the VM. Must be publicly accessible. |
| `bridgeName` | string | No | Name of the network bridge device |
| `portRange` | [object](#portrange) | No | iptables-mapped port range from Host to VM |
| `vmIp` | string | No | Internal IP address to assign the VM |
| Property | Type | Required | Description |
|---------------|----------------------|----------|------------------------------------------------------------------|
| `publicIp` | string | **Yes** | Public IP address to assign the VM. Must be publicly accessible. |
| `bridgeName` | string | No | Name of the network bridge device |
| `hostSshPort` | integer | No | Host SSH port, default is 922 |
| `portRange` | [object](#portrange) | No | iptables-mapped port range from Host to VM |
| `vmIp` | string | No | Internal IP address to assign the VM |
| `vmSshPort` | integer | No | VM SSH port, default is 22 |

##### portRange

Expand Down
12 changes: 12 additions & 0 deletions cli/src/lib/configs/project/provider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -429,6 +429,8 @@ type NoxConfigYAMLV1 = Omit<NoxConfigYAMLV0, "chainConfig"> & {
start?: number;
end?: number;
};
hostSshPort?: number;
vmSshPort?: number;
};
};
};
Expand Down Expand Up @@ -795,6 +797,16 @@ const noxConfigYAMLSchemaV1 = {
},
},
},
hostSshPort: {
nullable: true,
type: "integer",
description: `Host SSH port, default is 922`,
},
vmSshPort: {
nullable: true,
type: "integer",
description: `VM SSH port, default is 22`,
},
},
},
},
Expand Down

0 comments on commit 38a281b

Please sign in to comment.