Skip to content

Commit f2e7442

Browse files
committed
docs(server): add detailed server configuration documentation
1 parent 8a721f8 commit f2e7442

File tree

2 files changed

+82
-1
lines changed

2 files changed

+82
-1
lines changed

www/docs/configuration/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ FTL supports environment variable substitution in your configuration:
5151
Each section of the configuration has its own detailed documentation:
5252

5353
- [Project Settings](./project-settings.md) - Core project configuration
54-
- [Server Configuration](./services.md) - Server and SSH settings
54+
- [Server Configuration](./server.md) - Server and SSH settings
5555
- [Services](./services.md) - Application service definitions
5656
- [Dependencies](./dependencies.md) - Supporting service configuration
5757
- [Volumes](./volumes.md) - Persistent storage management

www/docs/configuration/server.md

Lines changed: 81 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,81 @@
1+
---
2+
title: Server Configuration
3+
description: Configure deployment server settings in your FTL configuration
4+
---
5+
6+
# Server Configuration
7+
8+
The `server` section in your `ftl.yaml` defines the deployment target settings. All fields in this section are optional and come with smart defaults.
9+
10+
## Configuration Fields
11+
12+
```yaml
13+
server:
14+
host: my-project.example.com
15+
port: 22
16+
user: deployer
17+
ssh_key: ~/.ssh/id_rsa
18+
```
19+
20+
| Field | Description | Default Value |
21+
| --------- | ---------------------------------------------------------- | ------------- |
22+
| `host` | Hostname or IP address of the deployment server | Value from `project.domain` |
23+
| `port` | SSH port for connecting to the server | `22` |
24+
| `user` | SSH user for deployment | Current system user |
25+
| `ssh_key` | Path to SSH private key | Auto-detected from standard locations |
26+
27+
## Smart Defaults
28+
29+
FTL implements intelligent defaults to minimize configuration:
30+
31+
1. `host` defaults to your project's domain
32+
2. `user` defaults to your current system username
33+
3. `ssh_key` is auto-detected from standard SSH key locations
34+
4. `port` defaults to the standard SSH port 22
35+
36+
## Environment Variables
37+
38+
Server settings support environment variable substitution:
39+
40+
```yaml
41+
server:
42+
host: ${SERVER_HOST}
43+
user: ${SERVER_USER}
44+
ssh_key: ${SSH_KEY_PATH}
45+
```
46+
47+
All environment variables must be set in the environment before running FTL commands.
48+
49+
## Examples
50+
51+
### Minimal Configuration
52+
53+
When you're happy with the defaults, you can omit the entire `server` section:
54+
55+
```yaml
56+
project:
57+
name: my-project
58+
domain: my-project.example.com
59+
email: my-project@example.com
60+
```
61+
62+
### Custom Server Settings
63+
64+
When you need to customize server settings:
65+
66+
```yaml
67+
server:
68+
host: 192.168.1.100
69+
user: custom-user
70+
ssh_key: ~/.ssh/custom-key
71+
```
72+
73+
### Mixed Defaults and Custom Settings
74+
75+
You can specify only the fields you want to customize:
76+
77+
```yaml
78+
server:
79+
host: custom-host.example.com
80+
user: deployer
81+
```

0 commit comments

Comments
 (0)