Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,9 @@ cargo build --release --target x86_64-unknown-linux-musl

for docker

To build for other platforms, modify the TARGET_ARCH variable in ./docker/make.sh.

For example, with Raspbarry Pi 4, use TARGET_ARCH=aarch64-unknown-linux-gnu
```bash
./docker/make.sh
```
Expand Down
5 changes: 3 additions & 2 deletions docker/make.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
#!/bin/bash

TARGET_ARCH="aarch64-unknown-linux-gnu"
SCRIPT=$(readlink -f "$0")
DIR=$(dirname "$SCRIPT")
VERSION=$(awk -F '"' '/^version/ {print $2}' "$DIR/../Cargo.toml")

# build
cd "$DIR/.."
cargo build --release --target x86_64-unknown-linux-musl
cp "$DIR/../target/x86_64-unknown-linux-musl/release/kosync" "$DIR/kosync"
cargo build --release --target "$TARGET_ARCH"
cp "$DIR/../target/$TARGET_ARCH/release/kosync" "$DIR/kosync"

# build docker
cd "$DIR"
Expand Down
2 changes: 1 addition & 1 deletion src/defs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use serde_json::json;

pub const DEFAULT_ADDR: &str = "0.0.0.0:3000";
pub const DEFAULT_TREE_NAME: &str = "kosync";
pub const DEFAULT_DB_PATH: &str = "data/kosync";
pub const DEFAULT_DB_PATH: &str = "/volume1/homes/cusanity/oneDrive/RESET/NAS/docker_data/kosync";
pub const FIELD_LEN_LIMIT: usize = 4096;

#[derive(Debug, Deserialize, Serialize)]
Expand Down