Skip to content

Commit 4ee5080

Browse files
committed
Address comments
1 parent a26138f commit 4ee5080

File tree

1 file changed

+30
-22
lines changed

1 file changed

+30
-22
lines changed

README.md

Lines changed: 30 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,8 @@ Any framework that can generate a build output in accordance with the App Hostin
1717

1818
The output bundle primarily consists of a `bundle.yaml` file that sits inside of the `.apphosting` directory. This bundle.yaml contains all the ways that frameworks can configure App Hosting when users deploy their applications.
1919

20-
NOTE: App Hosting technically supports all all node applications, but no custom framework features will be enabled without the output bundle.
20+
> [!NOTE]
21+
> App Hosting technically supports all all node applications, but no custom framework features will be enabled without the output bundle.
2122
2223
## Output bundle Schema
2324

@@ -50,14 +51,30 @@ The `runConfig` fields configures the Cloud Run service associated with the App
5051
```typescript
5152
interface RunConfig {
5253
runCommand: string;
53-
environmentVariables: EnvVarConfig[];
54+
environmentVariables?: EnvVarConfig[];
5455
concurrency?: number;
5556
cpu?: number;
5657
memoryMiB?: number;
5758
minInstances?: number;
5859
maxInstances?: number;
5960
}
61+
```
62+
63+
| Field | Type | Description | Required? |
64+
| ---------- | ------- | - | - |
65+
| `runCommand` | `string` |Command to start the server (e.g. `node dist/index.js`). Assume this command is run from the root dir of the workspace. This should be the productionized version of the server start command. | y |
66+
| `environmentVariables`| `EnvVarConfig[]` | Environment variables present in the server execution environment.| n |
67+
| `concurrency` | `number` | The maximum number of concurrent requests that each server instance can receive.| n |
68+
| `cpu` | `number` |The number of CPUs used in a single server instance. | n |
69+
| `memoryMiB` | `number` | The amount of memory available for a server instance.| n |
70+
| `minInstance` | `number` |The limit on the minimum number of function instances that may coexist at a given time. | n |
71+
| `MaxInstance` | `number` | The limit on the maximum number of function instances that may coexist at a given time.| n |
72+
73+
Many of these fields are shared with `apphosting.yaml`. See the [runConfig reference documentation](https://firebase.google.com/docs/reference/apphosting/rest/v1beta/projects.locations.backends.builds#runconfig) for additional context and default values.
6074

75+
### EnvVarConfig
76+
77+
```typescript
6178
interface EnvVarConfig {
6279
variable: string;
6380
value: string;
@@ -66,20 +83,11 @@ interface EnvVarConfig {
6683

6784
```
6885

69-
| Field | Type | Description |
70-
| ---------- | ------- | - |
71-
| `runCommand` | `string` |Command to start the server (e.g. `node dist/index.js`). Assume this command is run from the root dir of the workspace. This should be the productionized version of the server start command. |
72-
| `environmentVariables`| `EnvVarConfig[]` | Environment variables present in the server execution environment.|
73-
| `concurrency` | `number` | The maximum number of concurrent requests that each server instance can receive.|
74-
| `cpu` | `number` |The number of CPUs used in a single server instance. |
75-
| `memoryMiB` | `number` | The amount of memory available for a server instance.|
76-
| `minInstance` | `number` |The limit on the minimum number of function instances that may coexist at a given time. |
77-
| `MaxInstance` | `number` | The limit on the maximum number of function instances that may coexist at a given time.|
78-
| `EnvVarConfig.variable` | `string` |Name of the environment variable |
79-
| `EnvVarConfig.value` | `string` |Value associated with the environment variable |
80-
| `EnvVarConfig.availability` | `RUNTIME` | Where the variable will be available. For now this will always be `RUNTIME` |
81-
82-
Many of these fields are shared with `apphosting.yaml`. See the [runConfig reference documentation](https://firebase.google.com/docs/reference/apphosting/rest/v1beta/projects.locations.backends.builds#runconfig) for additional context.
86+
| Field | Type | Description | Required? |
87+
| ---------- | ------- | - | - |
88+
| `variable` | `string` |Name of the environment variable | y |
89+
| `value` | `string` |Value associated with the environment variable | y |
90+
| `availability` | `RUNTIME` | Where the variable will be available. For now this will always be `RUNTIME` | y |
8391

8492
### Metadata
8593

@@ -93,12 +101,12 @@ interface Metadata {
93101

94102
```
95103

96-
| Field | Type | Description |
97-
| ---------- | ------- | - |
98-
| `adapterPackageName` | `string` |Name of the adapter (this should be the npm package name) |
99-
| `adapterVersion`| `string` | Version of the adapter|
100-
| `framework` | `string` | Name of the framework that is being supported|
101-
| `frameworkVersion` | `string` |Version of the framework that is being supported |
104+
| Field | Type | Description | Required? |
105+
| ---------- | ------- | - | - |
106+
| `adapterPackageName` | `string` |Name of the adapter (this should be the npm package name) | y |
107+
| `adapterVersion`| `string` | Version of the adapter | y |
108+
| `framework` | `string` | Name of the framework that is being supported | y |
109+
| `frameworkVersion` | `string` |Version of the framework that is being supported | n |
102110

103111
Here is a sample `bundle.yaml` file putting all this together:
104112

0 commit comments

Comments
 (0)