Skip to content

Commit 3cef3dd

Browse files
byrronbarbettini
andauthored
Document api.public_host in the engine.yaml (#458)
* document api.public_host in the engine.yaml * fix order and identation * adjust wording explaining when to use api.public_host; fix wrong references to api.http.{prop} * Update app/en/home/local-deployment/configure/configuration-templates/page.mdx Co-authored-by: Nate Barbettini <[email protected]> * Update app/en/home/local-deployment/configure/engine/page.mdx Co-authored-by: Nate Barbettini <[email protected]> * Update app/en/home/local-deployment/configure/engine/page.mdx Co-authored-by: Nate Barbettini <[email protected]> --------- Co-authored-by: Nate Barbettini <[email protected]>
1 parent 4a240e1 commit 3cef3dd

File tree

2 files changed

+37
-28
lines changed
  • app/en/home/local-deployment/configure

2 files changed

+37
-28
lines changed

app/en/home/local-deployment/configure/configuration-templates/page.mdx

Lines changed: 17 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ title: "Configuration Templates"
33
description: "Arcade Engine Configuration Templates"
44
---
55

6-
76
# Engine Config Templates
87

98
### engine.yaml
9+
1010
```yaml
1111
# yaml-language-server: $schema=https://raw.githubusercontent.com/ArcadeAI/schemas/main/engine/config/1.0/schema.json
1212
$schema: https://raw.githubusercontent.com/ArcadeAI/schemas/main/engine/config/1.0/schema.json
@@ -15,115 +15,115 @@ api:
1515
development: ${env:API_DEVELOPMENT}
1616
host: ${env:ARCADE_API_HOST}
1717
port: ${env:ARCADE_API_PORT}
18-
18+
# Optionally set public_host, in case the Arcade Engine is hosted in a container or behind a reverse proxy
19+
#public_host: ${env:ARCADE_API_PUBLIC_HOST}
1920

2021
auth:
2122
providers:
2223
- id: default-atlassian
23-
description: 'The default Atlassian provider'
24+
description: "The default Atlassian provider"
2425
enabled: false
2526
type: oauth2
2627
provider_id: atlassian
2728
client_id: ${env:ATLASSIAN_CLIENT_ID}
2829
client_secret: ${env:ATLASSIAN_CLIENT_SECRET}
2930

3031
- id: default-discord
31-
description: 'The default Discord provider'
32+
description: "The default Discord provider"
3233
enabled: false
3334
type: oauth2
3435
provider_id: discord
3536
client_id: ${env:DISCORD_CLIENT_ID}
3637
client_secret: ${env:DISCORD_CLIENT_SECRET}
3738

3839
- id: default-dropbox
39-
description: 'The default Dropbox provider'
40+
description: "The default Dropbox provider"
4041
enabled: false
4142
type: oauth2
4243
provider_id: dropbox
4344
client_id: ${env:DROPBOX_CLIENT_ID}
4445
client_secret: ${env:DROPBOX_CLIENT_SECRET}
4546

4647
- id: default-github
47-
description: 'The default GitHub provider'
48+
description: "The default GitHub provider"
4849
enabled: false
4950
type: oauth2
5051
provider_id: github
5152
client_id: ${env:GITHUB_CLIENT_ID}
5253
client_secret: ${env:GITHUB_CLIENT_SECRET}
5354

5455
- id: default-google
55-
description: 'The default Google provider'
56+
description: "The default Google provider"
5657
enabled: false
5758
type: oauth2
5859
provider_id: google
5960
client_id: ${env:GOOGLE_CLIENT_ID}
6061
client_secret: ${env:GOOGLE_CLIENT_SECRET}
6162

6263
- id: default-linkedin
63-
description: 'The default LinkedIn provider'
64+
description: "The default LinkedIn provider"
6465
enabled: false
6566
type: oauth2
6667
provider_id: linkedin
6768
client_id: ${env:LINKEDIN_CLIENT_ID}
6869
client_secret: ${env:LINKEDIN_CLIENT_SECRET}
6970

7071
- id: default-microsoft
71-
description: 'The default Microsoft provider'
72+
description: "The default Microsoft provider"
7273
enabled: false
7374
type: oauth2
7475
provider_id: microsoft
7576
client_id: ${env:MICROSOFT_CLIENT_ID}
7677
client_secret: ${env:MICROSOFT_CLIENT_SECRET}
7778

7879
- id: default-reddit
79-
description: 'The default Reddit provider'
80+
description: "The default Reddit provider"
8081
enabled: false
8182
type: oauth2
8283
provider_id: reddit
8384
client_id: ${env:REDDIT_CLIENT_ID}
8485
client_secret: ${env:REDDIT_CLIENT_SECRET}
8586

8687
- id: default-slack
87-
description: 'The default Slack provider'
88+
description: "The default Slack provider"
8889
enabled: false
8990
type: oauth2
9091
provider_id: slack
9192
client_id: ${env:SLACK_CLIENT_ID}
9293
client_secret: ${env:SLACK_CLIENT_SECRET}
9394

9495
- id: default-spotify
95-
description: 'The default Spotify provider'
96+
description: "The default Spotify provider"
9697
enabled: false
9798
type: oauth2
9899
provider_id: spotify
99100
client_id: ${env:SPOTIFY_CLIENT_ID}
100101
client_secret: ${env:SPOTIFY_CLIENT_SECRET}
101102

102103
- id: default-twitch
103-
description: 'The default Twitch provider'
104+
description: "The default Twitch provider"
104105
enabled: false
105106
type: oauth2
106107
provider_id: twitch
107108
client_id: ${env:TWITCH_CLIENT_ID}
108109
client_secret: ${env:TWITCH_CLIENT_SECRET}
109110

110111
- id: default-x
111-
description: 'The default X provider'
112+
description: "The default X provider"
112113
enabled: false
113114
type: oauth2
114115
provider_id: x
115116
client_id: ${env:X_CLIENT_ID}
116117
client_secret: ${env:X_CLIENT_SECRET}
117118

118119
- id: default-zoom
119-
description: 'The default Zoom provider'
120+
description: "The default Zoom provider"
120121
enabled: false
121122
type: oauth2
122123
provider_id: zoom
123124
client_id: ${env:ZOOM_CLIENT_ID}
124125
client_secret: ${env:ZOOM_CLIENT_SECRET}
125126

126-
127127
llm:
128128
models:
129129
- id: my-openai-model-provider
@@ -143,14 +143,12 @@ llm:
143143
# base_url: 'https://api.groq.com/openai/v1'
144144
# api_key: ${env:GROQ_API_KEY}
145145

146-
147146
security:
148147
root_keys:
149148
- id: key1
150149
default: true
151150
value: ${env:ROOT_KEY_1}
152151

153-
154152
storage:
155153
postgres:
156154
user: ${env:POSTGRES_USER}
@@ -160,15 +158,13 @@ storage:
160158
db: ${env:POSTGRES_DB}
161159
sslmode: require
162160

163-
164161
telemetry:
165162
environment: ${env:TELEMETRY_ENVIRONMENT}
166163
logging:
167164
# debug, info, warn, error
168165
level: ${env:TELEMETRY_LOGGING_LEVEL}
169166
encoding: ${env:TELEMETRY_LOGGING_ENCODING}
170167

171-
172168
tools:
173169
directors:
174170
- id: default
@@ -185,6 +181,7 @@ tools:
185181
```
186182
187183
### engine.env
184+
188185
```bash
189186
### Engine configuration ###
190187
API_DEVELOPMENT=true

app/en/home/local-deployment/configure/engine/page.mdx

Lines changed: 20 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -80,11 +80,13 @@ topic:
8080
HTTP is the supported protocol for Arcade Engine's API. The following configuration options are available:
8181
8282
- `api.development` _(optional, default: `false`)_ - Enable development mode, with more logging and simple [worker authentication](/home/local-deployment/configure/engine#http-worker-configuration)
83-
- `api.http.host` _(default: `localhost`)_ - Address to which Arcade Engine binds its server (e.g., `localhost` or `0.0.0.0`)
84-
- `api.http.read_timeout` _(optional, default: `30s`)_ - Timeout for reading data from clients
85-
- `api.http.write_timeout` _(optional, default: `1m`)_ - Timeout for writing data to clients
86-
- `api.http.idle_timeout` _(optional, default: `30s`)_ - Timeout for idle connections
87-
- `api.http.max_request_body_size` _(optional, default: `4Mb`)_ - Maximum request body size
83+
- `api.host` _(default: `localhost`)_ - Address to which Arcade Engine binds its server (e.g., `localhost` or `0.0.0.0`)
84+
- `api.port` _(default: `9099`)_ - Port to which Arcade Engine binds its server (e.g., `9099` or `8080`)
85+
- `api.public_host` _(optional)_ - External hostname of the API (e.g., `my-public-host.com`), if it differs from `api.host` (for example, when Arcade Engine is behind a reverse proxy)
86+
- `api.read_timeout` _(optional, default: `30s`)_ - Timeout for reading data from clients
87+
- `api.write_timeout` _(optional, default: `1m`)_ - Timeout for writing data to clients
88+
- `api.idle_timeout` _(optional, default: `30s`)_ - Timeout for idle connections
89+
- `api.max_request_body_size` _(optional, default: `4Mb`)_ - Maximum request body size
8890

8991
A typical configuration for production looks like:
9092

@@ -95,6 +97,16 @@ api:
9597
port: 9099
9698
```
9799

100+
When the Arcade Engine is hosted in a container or behind a reverse proxy, set `api.public_host` to the external hostname of the API:
101+
102+
```yaml
103+
api:
104+
development: false
105+
host: localhost
106+
port: 9099
107+
public_host: my-public-host.com
108+
```
109+
98110
For local development, set `api.development = true`. In development mode, Arcade Engine does not require [worker authentication](/home/local-deployment/configure/engine#http-worker-configuration).
99111

100112
## Auth configuration
@@ -144,8 +156,8 @@ Two cache implementations are available:
144156
cache:
145157
api_key_ttl: 10s
146158
redis:
147-
addr: 'localhost:6379'
148-
password: ''
159+
addr: "localhost:6379"
160+
password: ""
149161
db: 0
150162
```
151163

@@ -263,7 +275,7 @@ tools:
263275
- id: local_worker
264276
enabled: true
265277
http:
266-
uri: 'http://localhost:8002'
278+
uri: "http://localhost:8002"
267279
timeout: 30
268280
retry: 3
269281
secret: ${env:ARCADE_WORKER_SECRET}

0 commit comments

Comments
 (0)