Compare commits

..
Author SHA1 Message Date
Alex Auvolat
0e05b9bc77
cargo fmt 2021-04-17 20:30:43 +02:00
Alex Auvolat
163ee977a0
Small improvements to compression code 2021-04-14 23:37:41 +02:00
Alex
307858bf0a Merge pull request 'Compress with zstd' (#44) from trinity-1686a/garage:zstd-block into main
Reviewed-on: https://git.deuxfleurs.fr/Deuxfleurs/garage/pulls/44
2021-04-14 23:27:33 +02:00
Alex Auvolat
76efb4999d
re-disable drone caches 2021-04-08 20:13:28 +02:00
Alex Auvolat
6e28ea6bdc
Use pre-prepared Docker image in CI to speed things up 2021-04-08 20:06:48 +02:00
Alex Auvolat
7ba80b6108
Update drone CI signature 2021-04-08 19:55:20 +02:00
Alex
e2e8ea4df5 Merge pull request 'Make CI faster' (#57) from trinity-1686a/garage:improve-ci into main
Reviewed-on: https://git.deuxfleurs.fr/Deuxfleurs/garage/pulls/57
2021-04-08 19:55:07 +02:00
Trinity Pointard
992284d545 use volume for cargo home
so it gets preserved between steps, and registry download is done only once
2021-04-08 17:08:26 +02:00
Trinity Pointard
d4fd074000 use zstd checksumming 2021-04-08 15:44:08 +02:00
Trinity Pointard
aeadb071c6 delete plain block when getting a compressed one 2021-04-08 15:42:14 +02:00
Trinity Pointard
4d5263ccf3 change extention for compressed files
set_extension don't behave verywell with extensions containing multiple dots
2021-04-08 15:42:14 +02:00
Trinity Pointard
e4b66a9e28 add testing on compressible data in smoke test 2021-04-08 15:42:14 +02:00
Trinity Pointard
9215d63e3a add checksum to end of file instead of decompressing 2021-04-08 15:42:12 +02:00
Trinity Pointard
01c623e391 use BlockData instead of Vec+bool 2021-04-08 15:41:27 +02:00
Trinity Pointard
de8e47435f compress blocs with zstd 2021-04-08 15:38:31 +02:00
Alex Auvolat
7560a41ab1
fix drone CI signature 2021-04-08 15:30:07 +02:00
Alex Auvolat
898fd1dc81
Skip Drone CI caching 2021-04-08 15:29:22 +02:00
Alex Auvolat
af6774a511
change a few comments 2021-04-08 15:13:02 +02:00
Alex
c35c472dc9 Merge pull request 'add doc comments' (#53) from trinity-1686a/garage:doc-comments into main
Reviewed-on: https://git.deuxfleurs.fr/Deuxfleurs/garage/pulls/53
2021-04-08 15:01:13 +02:00
Trinity Pointard
718ae00548 change some more comments and revert changes on TableSchema 2021-04-07 13:39:34 +02:00
Alex Auvolat
c3bd672d58
Reorganize code in s3_put.rs 2021-04-07 10:00:47 +02:00
Alex Auvolat
93a9f96130
remove useless comment 2021-04-06 23:38:30 +02:00
Alex
7380f3855c Merge pull request 'Use content defined chunking' (#43) from trinity-1686a/garage:content-defined-chunking into main
Reviewed-on: https://git.deuxfleurs.fr/Deuxfleurs/garage/pulls/43
2021-04-06 22:18:41 +02:00
Trinity Pointard
6cbc8d6ec9 mark branch as unreachable 2021-04-06 16:53:39 +02:00
Trinity Pointard
c8906f200b make most requested changes 2021-04-06 05:28:47 +02:00
Trinity Pointard
653d3d588f document garage crate 2021-04-06 05:26:48 +02:00
Trinity Pointard
a74eccfd6e document api crate 2021-04-06 05:26:48 +02:00
Trinity Pointard
ee9b685994 document web crate 2021-04-06 05:26:48 +02:00
Trinity Pointard
92d54770bb attempt at documenting model crate 2021-04-06 05:26:48 +02:00
Trinity Pointard
30bec0758b attempt at documenting table crate 2021-04-06 05:26:48 +02:00
Trinity Pointard
b476b702c8 run cargo fmt on util and make missing doc warning 2021-04-06 05:26:47 +02:00
Trinity Pointard
7d3a951836 document rpc crate 2021-04-06 05:26:36 +02:00
Trinity Pointard
f4bf987627 document util crate 2021-04-06 05:25:35 +02:00
Trinity Pointard
b3b0b20d72 run fmt 2021-04-06 02:54:05 +02:00
Trinity Pointard
47d0aee9f8 change crate used for cdc
previous one seemed to output incorrect results
2021-04-06 02:50:07 +02:00
Trinity Pointard
6e0cb2dfb6 add content defined chuking 2021-04-06 02:50:07 +02:00
Alex Auvolat
c4c4b7dedc
Update documentation 2021-04-06 00:01:49 +02:00
Alex
8225fa2e4b Merge pull request 'Improved bootstraping procedure' (#56) from better_bootstrap into main
Reviewed-on: https://git.deuxfleurs.fr/Deuxfleurs/garage/pulls/56
2021-04-05 23:50:33 +02:00
Alex Auvolat
ab67bd88de
Try to fix Drone 2021-04-05 23:41:50 +02:00
Alex Auvolat
0f192a96b5
small simplify 2021-04-05 23:21:25 +02:00
Alex Auvolat
7b85056942
Merge discovery loop with consul 2021-04-05 23:04:08 +02:00
Alex Auvolat
7fd1f9a869
cargo fmt 2021-04-05 20:42:57 +02:00
Alex Auvolat
c5d8dc7d6d
Print stats 2021-04-05 20:42:46 +02:00
Alex Auvolat
fa11cb746a
Cargo fmt 2021-04-05 20:35:26 +02:00
Alex Auvolat
f11bd80d2a
Keep old data 2021-04-05 20:33:24 +02:00
Alex Auvolat
595dc0ed0d
Persist directly and not in background 2021-04-05 20:26:01 +02:00
Alex Auvolat
78eeaab5ed
Install rustfmt 2021-04-05 20:00:48 +02:00
Alex Auvolat
22fbb3b892
Fix Drone CI signature 2021-04-05 19:58:42 +02:00
Alex Auvolat
0eb5baea1a
Improve bootstraping: do it regularly; persist peer list 2021-04-05 19:55:53 +02:00
Alex Auvolat
7d772737a5 Add signature to Drone CI 2021-04-05 12:10:28 +02:00
Alex Auvolat
4c2d8f5a96 test2 2021-04-05 12:09:20 +02:00
Alex Auvolat
0325086dac test 2021-04-05 12:08:05 +02:00
Alex Auvolat
700925263f
Drone CI badge on branch main 2021-04-05 11:45:20 +02:00
Alex Auvolat
6c83f66700 fix command for adding node 2021-04-02 23:23:14 +02:00
Alex Auvolat
55e4a93bad Section on recovering from failures 2021-04-02 19:30:29 +02:00
LUXEY Adrien
9cb9945131 [doc] Added mention that GarageHQ is hosted with Garage 2021-03-22 16:19:58 +01:00
Alex Auvolat
7f9c1d5595 publish website only in correct repo 2021-03-22 12:49:21 +01:00
Alex Auvolat
991cf1b818 fix typos 2021-03-19 17:55:10 +01:00
Alex Auvolat
e26cb2640d Merge remote-tracking branch 'origin/feature/mdbook' 2021-03-19 17:49:57 +01:00
Alex
22041e924b Merge pull request 'intro.md: fix some typos, errors & dead links, plus some stylistic stuff' (#51) from adrien/garage:feature/mdbook into feature/mdbook
Reviewed-on: https://git.deuxfleurs.fr/Deuxfleurs/garage/pulls/51
2021-03-19 17:14:41 +01:00
LUXEY Adrien
b119e9d3c4 intro.md: fix some typos, errors & dead links, plus some stylistic stuff
modifié :         doc/book/src/intro.md
2021-03-19 16:51:05 +01:00
Quentin Dufour
3e6534d7a8 Fix garage_util description 2021-03-18 11:46:29 +01:00
Quentin Dufour
2dae4a25d6 Fix some typos 2021-03-18 11:35:50 +01:00
Quentin Dufour
fcd566e89d Fix a table in the doc 2021-03-18 11:26:02 +01:00
821 changed files with 10831 additions and 168728 deletions

134
.drone.yml Normal file
View file

@ -0,0 +1,134 @@
---
kind: pipeline
name: default
workspace:
base: /drone/garage
volumes:
- name: cargo_home
temp: {}
steps:
- name: restore-cache
image: meltwater/drone-cache:dev
volumes:
- name: cargo_home
path: /drone/cargo
environment:
AWS_ACCESS_KEY_ID:
from_secret: cache_aws_access_key_id
AWS_SECRET_ACCESS_KEY:
from_secret: cache_aws_secret_access_key
pull: true
settings:
restore: true
archive_format: "gzip"
bucket: drone-cache
cache_key: '{{ .Repo.Name }}_{{ checksum "Cargo.lock" }}_{{ arch }}_{{ os }}_gzip'
region: garage
mount:
- '/drone/cargo'
- 'target'
path_style: true
endpoint: https://garage.deuxfleurs.fr
when:
branch:
- nonexistent_skip_this_step
- name: build
image: lxpz/garage_builder_amd64:1
volumes:
- name: cargo_home
path: /drone/cargo
environment:
CARGO_HOME: /drone/cargo
commands:
- pwd
- cargo fmt -- --check
- cargo build
- name: cargo-test
image: lxpz/garage_builder_amd64:1
volumes:
- name: cargo_home
path: /drone/cargo
environment:
CARGO_HOME: /drone/cargo
commands:
- cargo test
- name: rebuild-cache
image: meltwater/drone-cache:dev
volumes:
- name: cargo_home
path: /drone/cargo
environment:
AWS_ACCESS_KEY_ID:
from_secret: cache_aws_access_key_id
AWS_SECRET_ACCESS_KEY:
from_secret: cache_aws_secret_access_key
pull: true
settings:
rebuild: true
archive_format: "gzip"
bucket: drone-cache
cache_key: '{{ .Repo.Name }}_{{ checksum "Cargo.lock" }}_{{ arch }}_{{ os }}_gzip'
region: garage
mount:
- '/drone/cargo'
- 'target'
path_style: true
endpoint: https://garage.deuxfleurs.fr
when:
branch:
- nonexistent_skip_this_step
- name: smoke-test
image: lxpz/garage_builder_amd64:1
volumes:
- name: cargo_home
path: /drone/cargo
environment:
CARGO_HOME: /drone/cargo
commands:
- ./script/test-smoke.sh || (cat /tmp/garage.log; false)
---
kind: pipeline
name: website
steps:
- name: build
image: hrektts/mdbook
commands:
- cd doc/book
- mdbook build
- name: upload
image: plugins/s3
settings:
bucket: garagehq.deuxfleurs.fr
access_key:
from_secret: garagehq_aws_access_key_id
secret_key:
from_secret: garagehq_aws_secret_access_key
source: doc/book/book/**/*
strip_prefix: doc/book/book/
target: /
path_style: true
endpoint: https://garage.deuxfleurs.fr
region: garage
when:
event:
- push
branch:
- main
repo:
- Deuxfleurs/garage
---
kind: signature
hmac: de82026387bd09e547dbc9cc5d232fd865204b4f393d32508c50b58f8e60611d
...

1
.envrc
View file

@ -1 +0,0 @@
use flake

1
.gitignore vendored
View file

@ -3,4 +3,3 @@
/pki /pki
**/*.rs.bk **/*.rs.bk
*.swp *.swp
/.direnv

View file

@ -1,44 +0,0 @@
labels:
nix: "enabled"
when:
event:
- push
- tag
- pull_request
- deployment
- cron
- manual
steps:
- name: check formatting
image: nixpkgs/nix:nixos-24.05
commands:
- nix-build -j4 --attr flakePackages.fmt
- name: build
image: nixpkgs/nix:nixos-24.05
commands:
- nix-build -j4 --attr flakePackages.dev
- name: unit + func tests (lmdb)
image: nixpkgs/nix:nixos-24.05
commands:
- nix-build -j4 --attr flakePackages.tests-lmdb
- name: unit + func tests (sqlite)
image: nixpkgs/nix:nixos-24.05
commands:
- nix-build -j4 --attr flakePackages.tests-sqlite
- name: unit + func tests (fjall)
image: nixpkgs/nix:nixos-24.05
commands:
- nix-build -j4 --attr flakePackages.tests-fjall
- name: integration tests
image: nixpkgs/nix:nixos-24.05
commands:
- nix-build -j4 --attr flakePackages.dev
- nix-shell --attr ci --run ./script/test-smoke.sh || (cat /tmp/garage.log; false)
depends_on: [ build ]

View file

@ -1,33 +0,0 @@
labels:
nix: "enabled"
when:
event:
- deployment
- cron
depends_on:
- release
steps:
- name: refresh-index
image: nixpkgs/nix:nixos-24.05
environment:
AWS_ACCESS_KEY_ID:
from_secret: garagehq_aws_access_key_id
AWS_SECRET_ACCESS_KEY:
from_secret: garagehq_aws_secret_access_key
commands:
- mkdir -p /etc/nix && cp nix/nix.conf /etc/nix/nix.conf
- nix-shell --attr ci --run "refresh_index"
- name: multiarch-docker
image: nixpkgs/nix:nixos-24.05
environment:
DOCKER_AUTH:
from_secret: docker_auth
commands:
- mkdir -p /root/.docker
- echo $DOCKER_AUTH > /root/.docker/config.json
- export CONTAINER_TAG=${CI_COMMIT_TAG:-$CI_COMMIT_SHA}
- nix-shell --attr ci --run "multiarch_docker"

View file

@ -1,71 +0,0 @@
labels:
nix: "enabled"
when:
event:
- deployment
- cron
matrix:
include:
- ARCH: amd64
TARGET: x86_64-unknown-linux-musl
- ARCH: i386
TARGET: i686-unknown-linux-musl
- ARCH: arm64
TARGET: aarch64-unknown-linux-musl
- ARCH: arm
TARGET: armv6l-unknown-linux-musleabihf
steps:
- name: build
image: nixpkgs/nix:nixos-24.05
commands:
- nix-build --attr releasePackages.${ARCH} --argstr git_version ${CI_COMMIT_TAG:-$CI_COMMIT_SHA}
- name: check is static binary
image: nixpkgs/nix:nixos-24.05
commands:
- nix-shell --attr ci --run "./script/not-dynamic.sh result/bin/garage"
- name: integration tests
image: nixpkgs/nix:nixos-24.05
commands:
- nix-shell --attr ci --run ./script/test-smoke.sh || (cat /tmp/garage.log; false)
when:
- matrix:
ARCH: amd64
- matrix:
ARCH: i386
- name: upgrade tests
image: nixpkgs/nix:nixos-24.05
commands:
- nix-shell --attr ci --run "./script/test-upgrade.sh v0.8.4 x86_64-unknown-linux-musl" || (cat /tmp/garage.log; false)
when:
- matrix:
ARCH: amd64
- name: push static binary
image: nixpkgs/nix:nixos-24.05
environment:
TARGET: "${TARGET}"
AWS_ACCESS_KEY_ID:
from_secret: garagehq_aws_access_key_id
AWS_SECRET_ACCESS_KEY:
from_secret: garagehq_aws_secret_access_key
commands:
- nix-shell --attr ci --run "to_s3"
- name: docker build and publish
image: nixpkgs/nix:nixos-24.05
environment:
DOCKER_PLATFORM: "linux/${ARCH}"
CONTAINER_NAME: "dxflrs/${ARCH}_garage"
DOCKER_AUTH:
from_secret: docker_auth
commands:
- mkdir -p /root/.docker
- echo $DOCKER_AUTH > /root/.docker/config.json
- export CONTAINER_TAG=${CI_COMMIT_TAG:-$CI_COMMIT_SHA}
- nix-shell --attr ci --run "to_docker"

5020
Cargo.lock generated

File diff suppressed because it is too large Load diff

View file

@ -1,154 +1,16 @@
[workspace] [workspace]
resolver = "2"
members = [ members = [
"src/db",
"src/util", "src/util",
"src/net",
"src/rpc", "src/rpc",
"src/table", "src/table",
"src/block",
"src/model", "src/model",
"src/api/common", "src/api",
"src/api/s3",
"src/api/k2v",
"src/api/admin",
"src/web", "src/web",
"src/garage", "src/garage",
"src/k2v-client",
"src/format-table",
] ]
default-members = ["src/garage"] [profile.dev]
lto = "off"
[workspace.dependencies]
# Internal Garage crates
format_table = { version = "0.1.1", path = "src/format-table" }
garage_api_common = { version = "1.3.1", path = "src/api/common" }
garage_api_admin = { version = "1.3.1", path = "src/api/admin" }
garage_api_s3 = { version = "1.3.1", path = "src/api/s3" }
garage_api_k2v = { version = "1.3.1", path = "src/api/k2v" }
garage_block = { version = "1.3.1", path = "src/block" }
garage_db = { version = "1.3.1", path = "src/db", default-features = false }
garage_model = { version = "1.3.1", path = "src/model", default-features = false }
garage_net = { version = "1.3.1", path = "src/net" }
garage_rpc = { version = "1.3.1", path = "src/rpc" }
garage_table = { version = "1.3.1", path = "src/table" }
garage_util = { version = "1.3.1", path = "src/util" }
garage_web = { version = "1.3.1", path = "src/web" }
k2v-client = { version = "0.0.4", path = "src/k2v-client" }
# External crates from crates.io
arc-swap = "1.0"
argon2 = "0.5"
async-trait = "0.1.7"
backtrace = "0.3"
base64 = "0.21"
blake2 = "0.10"
bytes = "1.0"
bytesize = "1.1"
cfg-if = "1.0"
chrono = "0.4"
crc32fast = "1.4"
crc32c = "0.6"
crypto-common = "0.1"
gethostname = "0.4"
git-version = "0.3.4"
hex = "0.4"
hexdump = "0.1"
html-escape = "0.2.13"
hmac = "0.12"
itertools = "0.12"
ipnet = "2.9.0"
lazy_static = "1.4"
md-5 = "0.10"
mktemp = "0.5"
nix = { version = "0.29", default-features = false, features = ["fs"] }
nom = "7.1"
parking_lot = "0.12"
parse_duration = "2.1"
pin-project = "1.0.12"
pnet_datalink = "0.34"
rand = "0.8"
sha1 = "0.10"
sha2 = "0.10"
timeago = { version = "0.4", default-features = false }
xxhash-rust = { version = "0.8", default-features = false, features = ["xxh3"] }
aes-gcm = { version = "0.10", features = ["aes", "stream"] }
sodiumoxide = { version = "0.2.5-0", package = "kuska-sodiumoxide" }
kuska-handshake = { version = "0.2.0", features = ["default", "async_std"] }
clap = { version = "4.1", features = ["derive", "env"] }
pretty_env_logger = "0.5"
structopt = { version = "0.3", default-features = false }
syslog-tracing = "0.3"
tracing = "0.1"
tracing-journald = "0.3.1"
tracing-subscriber = { version = "0.3", features = ["env-filter"] }
heed = { version = "0.11", default-features = false, features = ["lmdb"] }
rusqlite = "0.37"
r2d2 = "0.8"
r2d2_sqlite = "0.31"
fjall = "2.4"
async-compression = { version = "0.4", features = ["tokio", "zstd"] }
zstd = { version = "0.13", default-features = false }
quick-xml = { version = "0.26", features = [ "serialize" ] }
rmp-serde = "1.1.2"
serde = { version = "1.0", default-features = false, features = ["derive", "rc"] }
serde_bytes = "0.11"
serde_json = "1.0"
toml = { version = "0.8", default-features = false, features = ["parse"] }
# newer version requires rust edition 2021
k8s-openapi = { version = "0.21", features = ["v1_24"] }
kube = { version = "0.88", default-features = false, features = ["runtime", "derive", "client", "rustls-tls"] }
schemars = "0.8"
reqwest = { version = "0.11", default-features = false, features = ["rustls-tls-manual-roots", "json"] }
form_urlencoded = "1.0.0"
http = "1.0"
httpdate = "1.0"
http-range = "0.1"
http-body-util = "0.1"
hyper = { version = "1.0", default-features = false }
hyper-util = { version = "0.1", features = [ "full" ] }
multer = "3.0"
percent-encoding = "2.2"
roxmltree = "0.19"
url = "2.3"
futures = "0.3"
futures-util = "0.3"
tokio = { version = "1.0", default-features = false, features = ["net", "rt", "rt-multi-thread", "io-util", "net", "time", "macros", "sync", "signal", "fs"] }
tokio-util = { version = "0.7", features = ["compat", "io"] }
tokio-stream = { version = "0.1", features = ["net"] }
opentelemetry = { version = "0.17", features = [ "rt-tokio", "metrics", "trace" ] }
opentelemetry-prometheus = "0.10"
opentelemetry-otlp = "0.10"
opentelemetry-contrib = "0.9"
prometheus = "0.13"
# used by the k2v-client crate only
aws-sigv4 = { version = "1.1", default-features = false }
hyper-rustls = { version = "0.26", default-features = false, features = ["http1", "http2", "ring", "rustls-native-certs"] }
log = "0.4"
thiserror = "2.0"
# ---- used only as build / dev dependencies ----
assert-json-diff = "2.0"
rustc_version = "0.4.0"
static_init = "1.0"
aws-smithy-runtime = { version = "1.8", default-features = false, features = ["tls-rustls"] }
aws-sdk-config = { version = "1.62", default-features = false }
aws-sdk-s3 = { version = "1.79", default-features = false, features = ["rt-tokio"] }
[profile.release] [profile.release]
lto = "thin" debug = true
codegen-units = 16
opt-level = 3
strip = "debuginfo"

View file

@ -1,7 +1,10 @@
FROM scratch FROM archlinux:latest
RUN mkdir -p /garage/meta
RUN mkdir -p /garage/data
ENV RUST_BACKTRACE=1 ENV RUST_BACKTRACE=1
ENV RUST_LOG=garage=info ENV RUST_LOG=garage=info
COPY result/bin/garage / COPY target/release/garage.stripped /garage/garage
CMD [ "/garage", "server"]
CMD /garage/garage server -c /garage/config.toml

View file

@ -1,22 +1,20 @@
.PHONY: doc all run1 run2 run3 BIN=target/release/garage
DOCKER=lxpz/garage_amd64
all: all:
clear clear; cargo build
cargo build
# ---- $(BIN):
RUSTFLAGS="-C link-arg=-fuse-ld=lld -C target-cpu=x86-64 -C target-feature=+sse2" cargo build --release --no-default-features
run1: $(BIN).stripped: $(BIN)
RUST_LOG=garage=debug ./target/debug/garage -c tmp/config1.toml server cp $^ $@
run1rel: strip $@
RUST_LOG=garage=debug ./target/release/garage -c tmp/config1.toml server
run2: docker: $(BIN).stripped
RUST_LOG=garage=debug ./target/debug/garage -c tmp/config2.toml server docker pull archlinux:latest
run2rel: docker build -t $(DOCKER):$(TAG) .
RUST_LOG=garage=debug ./target/release/garage -c tmp/config2.toml server docker push $(DOCKER):$(TAG)
docker tag $(DOCKER):$(TAG) $(DOCKER):latest
docker push $(DOCKER):latest
run3:
RUST_LOG=garage=debug ./target/debug/garage -c tmp/config3.toml server
run3rel:
RUST_LOG=garage=debug ./target/release/garage -c tmp/config3.toml server

View file

@ -1,38 +1,26 @@
Garage [![status-badge](https://woodpecker.deuxfleurs.fr/api/badges/1/status.svg)](https://woodpecker.deuxfleurs.fr/repos/1) Garage [![Build Status](https://drone.deuxfleurs.fr/api/badges/Deuxfleurs/garage/status.svg?ref=refs/heads/main)](https://drone.deuxfleurs.fr/Deuxfleurs/garage)
=== ===
<p align="center" style="text-align:center;"> <p align="center" style="text-align:center;">
<a href="https://garagehq.deuxfleurs.fr"> <a href="https://garagehq.deuxfleurs.fr">
<img alt="Garage logo" src="https://garagehq.deuxfleurs.fr/img/logo.svg" height="200" /> <img alt="Garage logo" src="doc/logo/garage.png" height="200" />
</a> </a>
</p> </p>
<p align="center" style="text-align:center;"> Garage is a lightweight S3-compatible distributed object store, with the following goals:
[ <strong><a href="https://garagehq.deuxfleurs.fr/">Website and documentation</a></strong>
| <a href="https://garagehq.deuxfleurs.fr/_releases.html">Binary releases</a>
| <a href="https://git.deuxfleurs.fr/Deuxfleurs/garage">Git repository</a>
| <a href="https://matrix.to/#/%23garage:deuxfleurs.fr">Matrix channel</a>
]
</p>
Garage is an S3-compatible distributed object storage service - As self-contained as possible
designed for self-hosting at a small-to-medium scale. - Easy to set up
- Highly resilient to network failures, network latency, disk failures, sysadmin failures
- Relatively simple
- Made for multi-datacenter deployments
Garage is designed for storage clusters composed of nodes running Non-goals include:
at different physical locations,
in order to easily provide a storage service that replicates data at these different
locations and stays available even when some servers are unreachable.
Garage also focuses on being lightweight, easy to operate, and highly resilient to
machine failures.
Garage is built by [Deuxfleurs](https://deuxfleurs.fr), - Extremely high performance
an experimental small-scale self hosted service provider, - Complete implementation of the S3 API
which has been using it in production since its first release in 2020. - Erasure coding (our replication model is simply to copy the data as is on several nodes, in different datacenters if possible)
Learn more on our dedicated documentation pages: Our main use case is to provide a distributed storage layer for small-scale self hosted services such as [Deuxfleurs](https://deuxfleurs.fr).
- [Goals and use cases](https://garagehq.deuxfleurs.fr/documentation/design/goals/) **[Go to the documentation](https://garagehq.deuxfleurs.fr)**
- [Features](https://garagehq.deuxfleurs.fr/documentation/reference-manual/features/)
- [Quick start](https://garagehq.deuxfleurs.fr/documentation/quick-start/)
Garage is entirely free software released under the terms of the AGPLv3.

27
TODO Normal file
View file

@ -0,0 +1,27 @@
Testing
-------
How are we going to test that our replication method works correctly?
We will have to introduce lots of dummy data and then add/remove nodes many times.
Attaining S3 compatibility
--------------------------
- test multipart uploads
- get ranges
- fix sync not working in some cases ? (when starting from empty?)
- api_server following the S3 semantics for head/get/put/list/delete: verify more that it works as intended
- PUT requests: verify content-md5 if provided
- possibly other necessary endpoints ?
Lower priority
--------------
- less a priority: hinted handoff
- repair: re-propagate block ref table to rc
- FIXME in rpc_server when garage shuts down and futures can be interrupted
(tokio::spawn should be replaced by a new function background::spawn_joinable)

22
config.dev.toml Normal file
View file

@ -0,0 +1,22 @@
block_size = 1048576 # objects are split in blocks of maximum this number of bytes
metadata_dir = "/tmp/garage-meta"
data_dir = "/tmp/garage-data"
rpc_bind_addr = "[::]:3901" # the port other Garage nodes will use to talk to this node
bootstrap_peers = []
max_concurrent_rpc_requests = 12
data_replication_factor = 3
meta_replication_factor = 3
meta_epidemic_fanout = 3
[s3_api]
api_bind_addr = "[::1]:3900" # the S3 API port, HTTP without TLS. Add a reverse proxy for the TLS part.
s3_region = "garage" # set this to anything. S3 API calls will fail if they are not made against the region set here.
[s3_web]
bind_addr = "[::1]:3902"
root_domain = ".garage.tld"
index = "index.html"

View file

@ -1,24 +0,0 @@
{ system ? builtins.currentSystem, git_version ? null, }:
with import ./nix/common.nix;
let
pkgs = import nixpkgs { };
compile = import ./nix/compile.nix;
build_release = target: (compile {
inherit target system git_version nixpkgs;
crane = flake.inputs.crane;
rust-overlay = flake.inputs.rust-overlay;
release = true;
}).garage;
in {
releasePackages = {
amd64 = build_release "x86_64-unknown-linux-musl";
i386 = build_release "i686-unknown-linux-musl";
arm64 = build_release "aarch64-unknown-linux-musl";
arm = build_release "armv6l-unknown-linux-musleabihf";
};
flakePackages = flake.packages.${system};
}

12
doc/20201202_talk/.gitignore vendored Normal file
View file

@ -0,0 +1,12 @@
*
!img
!.gitignore
!*.svg
!*.png
!*.jpg
!*.tex
!Makefile
!.gitignore
!talk.pdf

View file

@ -0,0 +1,6 @@
talk.pdf: talk.tex img/garage_distributed.pdf img/consistent_hashing_1.pdf img/consistent_hashing_2.pdf img/consistent_hashing_3.pdf img/consistent_hashing_4.pdf img/garage_tables.pdf
pdflatex talk.tex
img/%.pdf: img/%.svg
inkscape -D -z --file=$^ --export-pdf=$@

Binary file not shown.

After

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 53 KiB

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 54 KiB

Some files were not shown because too many files have changed in this diff Show more