Skip to content

Commit

Permalink
refactor(nx-mesh): use localhost as the default host
Browse files Browse the repository at this point in the history
  • Loading branch information
domjtalbot committed Apr 2, 2023
1 parent eef0fd6 commit 5f01c58
Show file tree
Hide file tree
Showing 5 changed files with 48 additions and 43 deletions.
5 changes: 5 additions & 0 deletions .changeset/great-bulldogs-pretend.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'nx-mesh': patch
---

Use `localhost` as the default host
80 changes: 40 additions & 40 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -418,19 +418,19 @@ This is the equivalent of using `graphql-mesh dev`.
<details>
<summary>`dev` executor options</summary>

| Name | Type | Required | Default | Description |
| ----------------- | -------------- | :------: | --------- | -------------------------------------------------------------------------------------------------- |
| `debug` | `boolean` | - | `false` | Display debugging info by applying the `DEBUG` env variable. |
| `dir` | `string` || - | The path of the directory containing the GraphQL Mesh config. |
| `port` | `object` | - | - | Port selection settings |
| `port.auto` | `boolean` | - | `true` | Use the first available port |
| `port.number` | `number` | - | `4200` | Define the preferred port to use when `auto` is set to `false` |
| `port.range` | `object` | - | - | The range of ports to select from. |
| `port.range.from` | `number` | - | - | The first port of the range. Must be in the range `1024`...`65535` |
| `port.range.to` | `number` | - | - | The last port of the range. Must be in the range `1024`...`65535` and must be greater than `from`. |
| `port.fallback` | `auto`, `none` | - | `auto` | The fallback strategy to use when the preferred port is unavailable. |
| `port.host` | `string` | - | `0.0.0.0` | The host to listen on (only used for port number lookup). |
| `require` | `string[]` | - | `[]` | Loads specific require.extensions before running the codegen and reading the configuration. |
| Name | Type | Required | Default | Description |
| ----------------- | -------------- | :------: | ----------- | -------------------------------------------------------------------------------------------------- |
| `debug` | `boolean` | - | `false` | Display debugging info by applying the `DEBUG` env variable. |
| `dir` | `string` || - | The path of the directory containing the GraphQL Mesh config. |
| `port` | `object` | - | - | Port selection settings |
| `port.auto` | `boolean` | - | `true` | Use the first available port |
| `port.number` | `number` | - | `4200` | Define the preferred port to use when `auto` is set to `false` |
| `port.range` | `object` | - | - | The range of ports to select from. |
| `port.range.from` | `number` | - | - | The first port of the range. Must be in the range `1024`...`65535` |
| `port.range.to` | `number` | - | - | The last port of the range. Must be in the range `1024`...`65535` and must be greater than `from`. |
| `port.fallback` | `auto`, `none` | - | `auto` | The fallback strategy to use when the preferred port is unavailable. |
| `port.host` | `string` | - | `localhost` | The host to listen on (only used for port number lookup). |
| `require` | `string[]` | - | `[]` | Loads specific require.extensions before running the codegen and reading the configuration. |

</details>

Expand All @@ -456,19 +456,19 @@ This is the equivalent of using `graphql-mesh start`.
<details>
<summary>`start` executor options</summary>

| Name | Type | Required | Default | Description |
| ----------------- | -------------- | :------: | --------- | -------------------------------------------------------------------------------------------------- |
| `debug` | `boolean` | - | `false` | Display debugging info by applying the `DEBUG` env variable. |
| `dir` | `string` || - | The path of the directory containing the GraphQL Mesh config. |
| `port` | `object` | - | - | Port selection settings |
| `port.auto` | `boolean` | - | `true` | Use the first available port |
| `port.number` | `number` | - | `4200` | Define the preferred port to use when `auto` is set to `false` |
| `port.range` | `object` | - | - | The range of ports to select from. |
| `port.range.from` | `number` | - | - | The first port of the range. Must be in the range `1024`...`65535` |
| `port.range.to` | `number` | - | - | The last port of the range. Must be in the range `1024`...`65535` and must be greater than `from`. |
| `port.fallback` | `auto`, `none` | - | `auto` | The fallback strategy to use when the preferred port is unavailable. |
| `port.host` | `string` | - | `0.0.0.0` | The host to listen on (only used for port number lookup). |
| `require` | `string[]` | - | `[]` | Loads specific require.extensions before running the codegen and reading the configuration. |
| Name | Type | Required | Default | Description |
| ----------------- | -------------- | :------: | ----------- | -------------------------------------------------------------------------------------------------- |
| `debug` | `boolean` | - | `false` | Display debugging info by applying the `DEBUG` env variable. |
| `dir` | `string` || - | The path of the directory containing the GraphQL Mesh config. |
| `port` | `object` | - | - | Port selection settings |
| `port.auto` | `boolean` | - | `true` | Use the first available port |
| `port.number` | `number` | - | `4200` | Define the preferred port to use when `auto` is set to `false` |
| `port.range` | `object` | - | - | The range of ports to select from. |
| `port.range.from` | `number` | - | - | The first port of the range. Must be in the range `1024`...`65535` |
| `port.range.to` | `number` | - | - | The last port of the range. Must be in the range `1024`...`65535` and must be greater than `from`. |
| `port.fallback` | `auto`, `none` | - | `auto` | The fallback strategy to use when the preferred port is unavailable. |
| `port.host` | `string` | - | `localhost` | The host to listen on (only used for port number lookup). |
| `require` | `string[]` | - | `[]` | Loads specific require.extensions before running the codegen and reading the configuration. |

</details>

Expand Down Expand Up @@ -500,20 +500,20 @@ This combines `dev` & `start` via a `dev` option toggle.
<details>
<summary>`serve` executor options</summary>

| Name | Type | Required | Default | Description |
| ----------------- | -------------- | :------: | --------- | -------------------------------------------------------------------------------------------------- |
| `debug` | `boolean` | - | `false` | Display debugging info by applying the `DEBUG` env variable. |
| `dev` | `string` | - | `false` | Run the server in dev or production mode. |
| `dir` | `string` || - | The path of the directory containing the GraphQL Mesh config. |
| `port` | `object` | - | - | Port selection settings |
| `port.auto` | `boolean` | - | `true` | Use the first available port |
| `port.number` | `number` | - | `4200` | Define the preferred port to use when `auto` is set to `false` |
| `port.range` | `object` | - | - | The range of ports to select from. |
| `port.range.from` | `number` | - | - | The first port of the range. Must be in the range `1024`...`65535` |
| `port.range.to` | `number` | - | - | The last port of the range. Must be in the range `1024`...`65535` and must be greater than `from`. |
| `port.fallback` | `auto`, `none` | - | `auto` | The fallback strategy to use when the preferred port is unavailable. |
| `port.host` | `string` | - | `0.0.0.0` | The host to listen on (only used for port number lookup). |
| `require` | `string[]` | - | `[]` | Loads specific require.extensions before running the codegen and reading the configuration. |
| Name | Type | Required | Default | Description |
| ----------------- | -------------- | :------: | ----------- | -------------------------------------------------------------------------------------------------- |
| `debug` | `boolean` | - | `false` | Display debugging info by applying the `DEBUG` env variable. |
| `dev` | `string` | - | `false` | Run the server in dev or production mode. |
| `dir` | `string` || - | The path of the directory containing the GraphQL Mesh config. |
| `port` | `object` | - | - | Port selection settings |
| `port.auto` | `boolean` | - | `true` | Use the first available port |
| `port.number` | `number` | - | `4200` | Define the preferred port to use when `auto` is set to `false` |
| `port.range` | `object` | - | - | The range of ports to select from. |
| `port.range.from` | `number` | - | - | The first port of the range. Must be in the range `1024`...`65535` |
| `port.range.to` | `number` | - | - | The last port of the range. Must be in the range `1024`...`65535` and must be greater than `from`. |
| `port.fallback` | `auto`, `none` | - | `auto` | The fallback strategy to use when the preferred port is unavailable. |
| `port.host` | `string` | - | `localhost` | The host to listen on (only used for port number lookup). |
| `require` | `string[]` | - | `[]` | Loads specific require.extensions before running the codegen and reading the configuration. |

</details>

Expand Down
2 changes: 1 addition & 1 deletion packages/nx-mesh/src/executors/dev/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"host": {
"type": "string",
"description": "The host to listern on.",
"default": "0.0.0.0"
"default": "localhost"
}
}
},
Expand Down
2 changes: 1 addition & 1 deletion packages/nx-mesh/src/executors/serve/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
"host": {
"type": "string",
"description": "The host to listern on.",
"default": "0.0.0.0"
"default": "localhost"
}
}
},
Expand Down
2 changes: 1 addition & 1 deletion packages/nx-mesh/src/executors/start/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
"host": {
"type": "string",
"description": "The host to listern on.",
"default": "0.0.0.0"
"default": "localhost"
}
}
},
Expand Down

0 comments on commit 5f01c58

Please sign in to comment.