mirror of
https://gitlab.com/veilid/veilid.git
synced 2024-10-01 01:26:08 -04:00
WIP, further docs
This commit is contained in:
parent
a7e9200c30
commit
b7e05ceea0
1
.gitignore
vendored
1
.gitignore
vendored
@ -61,4 +61,3 @@ $RECYCLE.BIN/
|
|||||||
### Rust
|
### Rust
|
||||||
target/
|
target/
|
||||||
logs/
|
logs/
|
||||||
|
|
||||||
|
31
README.md
31
README.md
@ -129,7 +129,9 @@ cd veilid-flutter
|
|||||||
|
|
||||||
**TODO**
|
**TODO**
|
||||||
|
|
||||||
## Veilid Server
|
## Running the Application(s)
|
||||||
|
|
||||||
|
### Veilid Server
|
||||||
|
|
||||||
In order to run the `veilid-server` locally:
|
In order to run the `veilid-server` locally:
|
||||||
|
|
||||||
@ -144,7 +146,7 @@ In order to see what options are available:
|
|||||||
cargo run -- --help
|
cargo run -- --help
|
||||||
```
|
```
|
||||||
|
|
||||||
## Veilid CLI
|
### Veilid CLI
|
||||||
|
|
||||||
In order to connect to your local `veilid-server`:
|
In order to connect to your local `veilid-server`:
|
||||||
|
|
||||||
@ -158,3 +160,28 @@ Similar to `veilid-server`, you may see CLI options by typing:
|
|||||||
```shell
|
```shell
|
||||||
cargo run -- --help
|
cargo run -- --help
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Building the Application
|
||||||
|
|
||||||
|
### Linux Packages
|
||||||
|
|
||||||
|
Veilid server and cli can be built locally using the
|
||||||
|
[Earthly](https://earthly.dev/) framework. After [installing earthly on your
|
||||||
|
local machine](https://earthly.dev/get-earthly), you may use the `earthly` cli
|
||||||
|
to initiate a build:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
earthly +package-linux
|
||||||
|
```
|
||||||
|
|
||||||
|
This will assemble all dependencies and build `.deb` packages for both amd64 and
|
||||||
|
arm64 platforms. Earthly, built on Docker, caches build layers, so after a
|
||||||
|
longer first build, subsequent builds should be much quicker.
|
||||||
|
|
||||||
|
During development, you may want to kick off specific build steps. To see a list
|
||||||
|
of the build steps configured, consult the `Earthfile`, or you may use the
|
||||||
|
`earthly` cli:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
earthly ls
|
||||||
|
```
|
||||||
|
@ -333,6 +333,9 @@ pub struct VeilidConfigInner {
|
|||||||
pub network: VeilidConfigNetwork,
|
pub network: VeilidConfigNetwork,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// The Veilid Configuration
|
||||||
|
///
|
||||||
|
/// Veilid is configured
|
||||||
#[derive(Clone)]
|
#[derive(Clone)]
|
||||||
pub struct VeilidConfig {
|
pub struct VeilidConfig {
|
||||||
inner: Arc<RwLock<VeilidConfigInner>>,
|
inner: Arc<RwLock<VeilidConfigInner>>,
|
||||||
|
127
veilid-server/sample.config
Normal file
127
veilid-server/sample.config
Normal file
@ -0,0 +1,127 @@
|
|||||||
|
daemon:
|
||||||
|
enabled: false
|
||||||
|
client_api:
|
||||||
|
enabled: true
|
||||||
|
listen_address: 'localhost:5959'
|
||||||
|
auto_attach: true
|
||||||
|
logging:
|
||||||
|
system:
|
||||||
|
enabled: false
|
||||||
|
level: 'info'
|
||||||
|
terminal:
|
||||||
|
enabled: true
|
||||||
|
level: 'info'
|
||||||
|
file:
|
||||||
|
enabled: false
|
||||||
|
path: ''
|
||||||
|
append: true
|
||||||
|
level: 'info'
|
||||||
|
api:
|
||||||
|
enabled: true
|
||||||
|
level: 'info'
|
||||||
|
otlp:
|
||||||
|
enabled: false
|
||||||
|
level: 'trace'
|
||||||
|
grpc_endpoint: 'localhost:4317'
|
||||||
|
testing:
|
||||||
|
subnode_index: 0
|
||||||
|
core:
|
||||||
|
protected_store:
|
||||||
|
allow_insecure_fallback: true
|
||||||
|
always_use_insecure_storage: true
|
||||||
|
insecure_fallback_directory: '%INSECURE_FALLBACK_DIRECTORY%'
|
||||||
|
delete: false
|
||||||
|
table_store:
|
||||||
|
directory: '%TABLE_STORE_DIRECTORY%'
|
||||||
|
delete: false
|
||||||
|
block_store:
|
||||||
|
directory: '%BLOCK_STORE_DIRECTORY%'
|
||||||
|
delete: false
|
||||||
|
network:
|
||||||
|
connection_initial_timeout_ms: 2000
|
||||||
|
connection_inactivity_timeout_ms: 60000
|
||||||
|
max_connections_per_ip4: 32
|
||||||
|
max_connections_per_ip6_prefix: 32
|
||||||
|
max_connections_per_ip6_prefix_size: 56
|
||||||
|
max_connection_frequency_per_min: 128
|
||||||
|
client_whitelist_timeout_ms: 300000
|
||||||
|
reverse_connection_receipt_time_ms: 5000
|
||||||
|
hole_punch_receipt_time_ms: 5000
|
||||||
|
node_id: ''
|
||||||
|
node_id_secret: ''
|
||||||
|
bootstrap: ['bootstrap.dev.veilid.net']
|
||||||
|
bootstrap_nodes: []
|
||||||
|
routing_table:
|
||||||
|
limit_over_attached: 64
|
||||||
|
limit_fully_attached: 32
|
||||||
|
limit_attached_strong: 16
|
||||||
|
limit_attached_good: 8
|
||||||
|
limit_attached_weak: 4
|
||||||
|
rpc:
|
||||||
|
concurrency: 0
|
||||||
|
queue_size: 1024
|
||||||
|
max_timestamp_behind_ms: 10000
|
||||||
|
max_timestamp_ahead_ms: 10000
|
||||||
|
timeout_ms: 10000
|
||||||
|
max_route_hop_count: 7
|
||||||
|
dht:
|
||||||
|
resolve_node_timeout:
|
||||||
|
resolve_node_count: 20
|
||||||
|
resolve_node_fanout: 3
|
||||||
|
max_find_node_count: 20
|
||||||
|
get_value_timeout:
|
||||||
|
get_value_count: 20
|
||||||
|
get_value_fanout: 3
|
||||||
|
set_value_timeout:
|
||||||
|
set_value_count: 20
|
||||||
|
set_value_fanout: 5
|
||||||
|
min_peer_count: 20
|
||||||
|
min_peer_refresh_time_ms: 2000
|
||||||
|
validate_dial_info_receipt_time_ms: 2000
|
||||||
|
upnp: true
|
||||||
|
natpmp: false
|
||||||
|
detect_address_changes: true
|
||||||
|
enable_local_peer_scope: false
|
||||||
|
restricted_nat_retries: 0
|
||||||
|
tls:
|
||||||
|
certificate_path: '%CERTIFICATE_PATH%'
|
||||||
|
private_key_path: '%PRIVATE_KEY_PATH%'
|
||||||
|
connection_initial_timeout_ms: 2000
|
||||||
|
application:
|
||||||
|
https:
|
||||||
|
enabled: false
|
||||||
|
listen_address: ':5150'
|
||||||
|
path: 'app'
|
||||||
|
# url: 'https://localhost:5150'
|
||||||
|
http:
|
||||||
|
enabled: false
|
||||||
|
listen_address: ':5150'
|
||||||
|
path: 'app'
|
||||||
|
# url: 'http://localhost:5150'
|
||||||
|
protocol:
|
||||||
|
udp:
|
||||||
|
enabled: true
|
||||||
|
socket_pool_size: 0
|
||||||
|
listen_address: ':5150'
|
||||||
|
# public_address: ''
|
||||||
|
tcp:
|
||||||
|
connect: true
|
||||||
|
listen: true
|
||||||
|
max_connections: 32
|
||||||
|
listen_address: ':5150'
|
||||||
|
#'public_address: ''
|
||||||
|
ws:
|
||||||
|
connect: true
|
||||||
|
listen: true
|
||||||
|
max_connections: 16
|
||||||
|
listen_address: ':5150'
|
||||||
|
path: 'ws'
|
||||||
|
# url: 'ws://localhost:5150/ws'
|
||||||
|
wss:
|
||||||
|
connect: true
|
||||||
|
listen: false
|
||||||
|
max_connections: 16
|
||||||
|
listen_address: ':5150'
|
||||||
|
path: 'ws'
|
||||||
|
# url: ''
|
||||||
|
|
@ -26,6 +26,7 @@ async fn handle_signals(mut signals: Signals) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[warn(missing_docs)]
|
||||||
#[instrument(err)]
|
#[instrument(err)]
|
||||||
pub fn run_daemon(settings: Settings, _matches: ArgMatches) -> EyreResult<()> {
|
pub fn run_daemon(settings: Settings, _matches: ArgMatches) -> EyreResult<()> {
|
||||||
let daemon = {
|
let daemon = {
|
||||||
|
Loading…
Reference in New Issue
Block a user