mirror of
https://gitlab.com/famedly/conduit.git
synced 2024-12-27 04:53:50 +03:00
Merge branch conduit:next into next
This commit is contained in:
commit
bd771b6fa5
5 changed files with 10 additions and 11 deletions
2
Cargo.lock
generated
2
Cargo.lock
generated
|
@ -487,7 +487,7 @@ checksum = "3d7b894f5411737b7867f4827955924d7c254fc9f4d91a6aad6b097804b1018b"
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "conduit"
|
name = "conduit"
|
||||||
version = "0.9.0-alpha"
|
version = "0.10.0-alpha"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"async-trait",
|
"async-trait",
|
||||||
"axum 0.7.5",
|
"axum 0.7.5",
|
||||||
|
|
|
@ -16,7 +16,7 @@ license = "Apache-2.0"
|
||||||
name = "conduit"
|
name = "conduit"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
repository = "https://gitlab.com/famedly/conduit"
|
repository = "https://gitlab.com/famedly/conduit"
|
||||||
version = "0.9.0-alpha"
|
version = "0.10.0-alpha"
|
||||||
|
|
||||||
# See also `rust-toolchain.toml`
|
# See also `rust-toolchain.toml`
|
||||||
rust-version = "1.79.0"
|
rust-version = "1.79.0"
|
||||||
|
|
|
@ -58,7 +58,8 @@ The `global` section contains the following fields:
|
||||||
| `turn_secret` | `string` | The TURN secret | `""` |
|
| `turn_secret` | `string` | The TURN secret | `""` |
|
||||||
| `turn_ttl` | `integer` | The TURN TTL in seconds | `86400` |
|
| `turn_ttl` | `integer` | The TURN TTL in seconds | `86400` |
|
||||||
| `emergency_password` | `string` | Set a password to login as the `conduit` user in case of emergency | N/A |
|
| `emergency_password` | `string` | Set a password to login as the `conduit` user in case of emergency | N/A |
|
||||||
| `well_known` | `table` | Used for [delegation](delegation.md) | See [delegation](delegation.md) |
|
| `well_known_client` | `string` | Used for [delegation](delegation.md) | See [delegation](delegation.md) |
|
||||||
|
| `well_known_server` | `string` | Used for [delegation](delegation.md) | See [delegation](delegation.md) |
|
||||||
|
|
||||||
|
|
||||||
### TLS
|
### TLS
|
||||||
|
|
|
@ -16,18 +16,18 @@ are connected to the server running Conduit using something like a VPN.
|
||||||
|
|
||||||
> **Note**: this will automatically allow you to use [sliding sync][0] without any extra configuration
|
> **Note**: this will automatically allow you to use [sliding sync][0] without any extra configuration
|
||||||
|
|
||||||
To configure it, use the following options in the `global.well_known` table:
|
To configure it, use the following options:
|
||||||
| Field | Type | Description | Default |
|
| Field | Type | Description | Default |
|
||||||
| --- | --- | --- | --- |
|
| --- | --- | --- | --- |
|
||||||
| `client` | `String` | The URL that clients should use to connect to Conduit | `https://<server_name>` |
|
| `well_known_client` | `String` | The URL that clients should use to connect to Conduit | `https://<server_name>` |
|
||||||
| `server` | `String` | The hostname and port servers should use to connect to Conduit | `<server_name>:443` |
|
| `well_known_server` | `String` | The hostname and port servers should use to connect to Conduit | `<server_name>:443` |
|
||||||
|
|
||||||
### Example
|
### Example
|
||||||
|
|
||||||
```toml
|
```toml
|
||||||
[global.well_known]
|
[global]
|
||||||
client = "https://matrix.example.org"
|
well_known_client = "https://matrix.example.org"
|
||||||
server = "matrix.example.org:443"
|
well_known_server = "matrix.example.org:443"
|
||||||
```
|
```
|
||||||
|
|
||||||
## Manual
|
## Manual
|
||||||
|
|
|
@ -972,11 +972,9 @@ impl KeyValueDatabase {
|
||||||
if content_disposition.contains("filename=")
|
if content_disposition.contains("filename=")
|
||||||
&& !content_disposition.contains("filename=\"")
|
&& !content_disposition.contains("filename=\"")
|
||||||
{
|
{
|
||||||
println!("{}", &content_disposition);
|
|
||||||
content_disposition =
|
content_disposition =
|
||||||
content_disposition.replacen("filename=", "filename=\"", 1);
|
content_disposition.replacen("filename=", "filename=\"", 1);
|
||||||
content_disposition.push('"');
|
content_disposition.push('"');
|
||||||
println!("{}", &content_disposition);
|
|
||||||
|
|
||||||
let mut new_key = mediaid[..(mediaid.len() - removed_bytes)].to_vec();
|
let mut new_key = mediaid[..(mediaid.len() - removed_bytes)].to_vec();
|
||||||
assert!(*new_key.last().unwrap() == 0xff);
|
assert!(*new_key.last().unwrap() == 0xff);
|
||||||
|
|
Loading…
Reference in a new issue