You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+30-22Lines changed: 30 additions & 22 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -17,7 +17,8 @@ Any framework that can generate a build output in accordance with the App Hostin
17
17
18
18
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.
19
19
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.
21
22
22
23
## Output bundle Schema
23
24
@@ -50,14 +51,30 @@ The `runConfig` fields configures the Cloud Run service associated with the App
50
51
```typescript
51
52
interfaceRunConfig {
52
53
runCommand:string;
53
-
environmentVariables:EnvVarConfig[];
54
+
environmentVariables?:EnvVarConfig[];
54
55
concurrency?:number;
55
56
cpu?:number;
56
57
memoryMiB?:number;
57
58
minInstances?:number;
58
59
maxInstances?:number;
59
60
}
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.
60
74
75
+
### EnvVarConfig
76
+
77
+
```typescript
61
78
interfaceEnvVarConfig {
62
79
variable:string;
63
80
value:string;
@@ -66,20 +83,11 @@ interface EnvVarConfig {
66
83
67
84
```
68
85
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 |
83
91
84
92
### Metadata
85
93
@@ -93,12 +101,12 @@ interface Metadata {
93
101
94
102
```
95
103
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 |
102
110
103
111
Here is a sample `bundle.yaml` file putting all this together:
0 commit comments