# ry domains

> Attach your own domains to an app.

```text
ry domains [options] [command]
```

## Subcommands

### `ry domains add`

Claim a domain for an app and print the DNS records to set.

```text
ry domains add [options] <app> <domain>
```

Example:

```bash
ry domains add web www.example.com
```

### `ry domains list`

Show domains of an app with status and certificate expiry.

```text
ry domains list [options] [app]
```

Arguments:

- `[app]`: The app (default: "app" from rytiv.json in this directory or above).

Example:

```bash
ry domains list web
```

### `ry domains check`

Re-run verification now instead of waiting for the next scheduled check.

```text
ry domains check [options] <app> <domain>
```

Example:

```bash
ry domains check web www.example.com
```

### `ry domains zones`

Prove a whole zone once and get one wildcard certificate for every name below it.

```text
ry domains zones [options] [command]
```

#### `ry domains zones add`

Claim a zone and print the two DNS records to set.

```text
ry domains zones add [options] <zone>
```

Example:

```bash
ry domains zones add example.com
```

#### `ry domains zones list`

Show your zones with status and wildcard certificate expiry.

```text
ry domains zones list [options]
```

Example:

```bash
ry domains zones list
```

#### `ry domains zones check`

Re-run the zone proof or certificate order now.

```text
ry domains zones check [options] <zone>
```

Example:

```bash
ry domains zones check example.com
```

#### `ry domains zones remove`

Release a zone (refused while names below it are attached to apps).

```text
ry domains zones remove [options] <zone>
```

Options:

- `-y, --yes`: Skip confirmation (required for automation).

Example:

```bash
ry domains zones remove example.com
```

### `ry domains remove`

Detach a domain from an app.

```text
ry domains remove [options] <app> <domain>
```

Options:

- `-y, --yes`: Skip confirmation (required for automation).

Example:

```bash
ry domains remove web www.example.com --yes
```

### `ry domains redirect`

Answer 308 on `<domain>` and send visitors to `<to>` (another domain of the app); --off serves again.

```text
ry domains redirect [options] <app> <domain> [to]
```

Options:

- `--off`: Stop redirecting, serve the app on this domain again.

Example:

```bash
ry domains redirect web example.com www.example.com
ry domains redirect web example.com --off
```
