From 318ef40c4effed290eb8fb6d1c1bb15d7580ffea Mon Sep 17 00:00:00 2001 From: Thomas Date: Fri, 24 May 2024 08:51:07 +0200 Subject: [PATCH 1/3] Adding ente documentation --- doc/book/connect/apps/index.md | 73 +++++++++++++++++++++++++++++++++- 1 file changed, 72 insertions(+), 1 deletion(-) diff --git a/doc/book/connect/apps/index.md b/doc/book/connect/apps/index.md index f52d434b..9bb13cf8 100644 --- a/doc/book/connect/apps/index.md +++ b/doc/book/connect/apps/index.md @@ -12,7 +12,9 @@ In this section, we cover the following web applications: | [Mastodon](#mastodon) | ✅ | Natively supported | | [Matrix](#matrix) | ✅ | Tested with `synapse-s3-storage-provider` | | [ejabberd](#ejabberd) | ✅ | `mod_s3_upload` | -| [Pixelfed](#pixelfed) | ✅ | Natively supported | +| [Ente](#ente) | ✅ | Natively supported | +| [Pixelfed](#pixelfed) | ❓ | Natively supported | +>>>>>>> b98c90f0 (Adding ente documentation) | [Pleroma](#pleroma) | ❓ | Not yet tested | | [Lemmy](#lemmy) | ✅ | Supported with pict-rs | | [Funkwhale](#funkwhale) | ❓ | Not yet tested | @@ -567,6 +569,75 @@ The module can then be configured with: Other configuration options can be found in the [configuration YAML file](https://github.com/processone/ejabberd-contrib/blob/master/mod_s3_upload/conf/mod_s3_upload.yml). + +## Ente + +Ente is an alternative for Google Photos and Apple Photos. It can be selfhosted and is working fine with Garage. +As a first step we need to create a bucket and a key for Ente: + +```bash +garage bucket create ente +garage key create ente-key +garage bucket allow ente --read --write --key ente-key +``` + +We also need to setup some CORS rules to allow the Ente frontend to access the bucket: + +```bash +export CORS='{"CORSRules":[{"AllowedHeaders":["*"],"AllowedMethods":["GET"],"AllowedOrigins":["*"]}]}' +aws s3api put-bucket-cors --bucket ente --cors-configuration $CORS +``` + +Now we need to configure ente-server to use our bucket. +Prepare a configuration file for ente `museum.yaml` + +```yaml +credentials-file: /credentials.yaml +apps: + public-albums: https://albums.example.tld # If you want to use the share album feature + internal: +hardcoded-ott: + local-domain-suffix: "@example.com" # Your domain + local-domain-value: 123456 # Custom OTP since not sending mail by default +key: + encryption: yvmG/RnzKrbCb9L3mgsmoxXr9H7i2Z4qlbT0mL3ln4w= # You might want to change those next 3 which are the default one + hash: KXYiG07wC7GIgvCSdg+WmyWdXDAn6XKYJtp/wkEU7x573+byBRAYtpTP0wwvi8i/4l37uicX1dVTUzwH3sLZyw== # Someone has made an image that can do it for you : https://github.com/EdyTheCow/ente-selfhost/blob/main/images/ente-server-tools/Dockerfile +jwt: + secret: i2DecQmfGreG6q1vBj5tCokhlN41gcfS2cjOs9Po-u8= # Simply build it yourself or run docker run --rm ghcr.io/edythecow/ente-server-tools go run tools/gen-random-keys/main.go +``` + +Full configuration file can be found [here](https://github.com/ente-io/ente/blob/main/server/configurations/local.yaml) + +Prepare a credentials file for ente `credentials.yaml` + +```yaml +db: + host: postgres + port: 5432 + name: ente_db + user: pguser + password: pgpass + +s3: + are_local_buckets: true ## Put that to false if you want to use https + b2-eu-cen: ## Don't change this key it seems to be hardcoded + key: keyID + secret: keySecret + endpoint: garage:3900 + region: region + bucket: bucketName + use_path_style: true +``` + +Finally you can run it with Docker : + +```bash +docker run -d --name ente-server --restart unless-stopped -v /path/to/museum.yaml:/museum.yaml -v /path/to/credentials.yaml:/credentials.yaml -p 8080:8080 ghcr.io/ente-io/ente-server +``` + +For more information on deployment you can check the [ente documentation](https://help.ente.io/self-hosting/) + + ## Pixelfed [Pixelfed Technical Documentation > Configuration](https://docs.pixelfed.org/technical-documentation/env.html#filesystem) From d211c1e2914582b74dcb593b429223df27257990 Mon Sep 17 00:00:00 2001 From: maximilien Date: Sun, 26 May 2024 06:18:20 +0000 Subject: [PATCH 2/3] ente: add more details on bucket configuration add more configuration with details for options Signed-off-by: maximilien --- doc/book/connect/apps/index.md | 70 ++++++++++++++++++++++++---------- 1 file changed, 50 insertions(+), 20 deletions(-) diff --git a/doc/book/connect/apps/index.md b/doc/book/connect/apps/index.md index 9bb13cf8..f40c1bfb 100644 --- a/doc/book/connect/apps/index.md +++ b/doc/book/connect/apps/index.md @@ -572,7 +572,7 @@ Other configuration options can be found in the ## Ente -Ente is an alternative for Google Photos and Apple Photos. It can be selfhosted and is working fine with Garage. +Ente is an alternative for Google Photos and Apple Photos. It [can be selfhosted](https://help.ente.io/self-hosting/) and is working fine with Garage as of May 2024. As a first step we need to create a bucket and a key for Ente: ```bash @@ -588,8 +588,8 @@ export CORS='{"CORSRules":[{"AllowedHeaders":["*"],"AllowedMethods":["GET"],"All aws s3api put-bucket-cors --bucket ente --cors-configuration $CORS ``` -Now we need to configure ente-server to use our bucket. -Prepare a configuration file for ente `museum.yaml` +Now we need to configure ente-server to use our bucket. This is explained [in the Ente S3 documentation](https://help.ente.io/self-hosting/guides/external-s3). +Prepare a configuration file for ente's backend as `museum.yaml`: ```yaml credentials-file: /credentials.yaml @@ -598,35 +598,66 @@ apps: internal: hardcoded-ott: local-domain-suffix: "@example.com" # Your domain - local-domain-value: 123456 # Custom OTP since not sending mail by default + local-domain-value: 123456 # Custom One-Time Password since we are not sending mail by default key: - encryption: yvmG/RnzKrbCb9L3mgsmoxXr9H7i2Z4qlbT0mL3ln4w= # You might want to change those next 3 which are the default one - hash: KXYiG07wC7GIgvCSdg+WmyWdXDAn6XKYJtp/wkEU7x573+byBRAYtpTP0wwvi8i/4l37uicX1dVTUzwH3sLZyw== # Someone has made an image that can do it for you : https://github.com/EdyTheCow/ente-selfhost/blob/main/images/ente-server-tools/Dockerfile + # You might want to change those next 3 which are the default one + encryption: yvmG/RnzKrbCb9L3mgsmoxXr9H7i2Z4qlbT0mL3ln4w= + # Someone has made an image that can do it for you : https://github.com/EdyTheCow/ente-selfhost/blob/main/images/ente-server-tools/Dockerfile + hash: KXYiG07wC7GIgvCSdg+WmyWdXDAn6XKYJtp/wkEU7x573+byBRAYtpTP0wwvi8i/4l37uicX1dVTUzwH3sLZyw== jwt: - secret: i2DecQmfGreG6q1vBj5tCokhlN41gcfS2cjOs9Po-u8= # Simply build it yourself or run docker run --rm ghcr.io/edythecow/ente-server-tools go run tools/gen-random-keys/main.go + # Simply build it yourself or run docker run --rm ghcr.io/edythecow/ente-server-tools go run tools/gen-random-keys/main.go + secret: i2DecQmfGreG6q1vBj5tCokhlN41gcfS2cjOs9Po-u8= ``` -Full configuration file can be found [here](https://github.com/ente-io/ente/blob/main/server/configurations/local.yaml) - -Prepare a credentials file for ente `credentials.yaml` +The full configuration file can be found [here](https://github.com/ente-io/ente/blob/main/server/configurations/local.yaml) +Then prepare a credentials file as `credentials.yaml` ```yaml db: host: postgres port: 5432 - name: ente_db - user: pguser - password: pgpass + name: + user: + password: s3: - are_local_buckets: true ## Put that to false if you want to use https - b2-eu-cen: ## Don't change this key it seems to be hardcoded - key: keyID - secret: keySecret + # Override the primary and secondary hot storage. The commented out values + # are the defaults. + # + hot_storage: + primary: b2-eu-cen + # secondary: wasabi-eu-central-2-v3 + + # If true, enable some workarounds to allow us to use a local minio instance + # for object storage. + # + # 1. Disable SSL. + # 2. Use "path" style S3 URLs (see `use_path_style_urls` below). + # 3. Directly download the file during replication instead of going via the + # Cloudflare worker. + # 4. Do not specify storage classes when uploading objects (since minio does + # not support them, specifically it doesn't support GLACIER). + are_local_buckets: true + + # To use "path" style S3 URLs instead of DNS-based bucket access + # default to true if you set "are_local_buckets: true" + # use_path_style_urls: true + + b2-eu-cen: # Don't change this key, it seems to be hardcoded + key: + secret: endpoint: garage:3900 - region: region - bucket: bucketName + region: garage + bucket: use_path_style: true + # you can specify secondary locations, names are hardcoded as well + # wasabi-eu-central-2-v3: + # scw-eu-fr-v3: + + # and you can also specify a bucket to be used for embeddings, preview etc.. + # default to the first bucket + # derived-storage: wasabi-eu-central-2-derived + ``` Finally you can run it with Docker : @@ -637,7 +668,6 @@ docker run -d --name ente-server --restart unless-stopped -v /path/to/museum.yam For more information on deployment you can check the [ente documentation](https://help.ente.io/self-hosting/) - ## Pixelfed [Pixelfed Technical Documentation > Configuration](https://docs.pixelfed.org/technical-documentation/env.html#filesystem) From fced78c28383bd5d9c34675462ff0747f559137c Mon Sep 17 00:00:00 2001 From: maximilien Date: Mon, 22 Dec 2025 02:13:37 +0100 Subject: [PATCH 3/3] doc: ente doc fixes from comments --- doc/book/connect/apps/index.md | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/doc/book/connect/apps/index.md b/doc/book/connect/apps/index.md index f40c1bfb..6aadc36e 100644 --- a/doc/book/connect/apps/index.md +++ b/doc/book/connect/apps/index.md @@ -578,13 +578,14 @@ As a first step we need to create a bucket and a key for Ente: ```bash garage bucket create ente garage key create ente-key -garage bucket allow ente --read --write --key ente-key +# For the CORS setup to work, the key needs to be --owner as well, at least temporarily. +garage bucket allow ente --read --write --owner --key ente-key ``` We also need to setup some CORS rules to allow the Ente frontend to access the bucket: ```bash -export CORS='{"CORSRules":[{"AllowedHeaders":["*"],"AllowedMethods":["GET"],"AllowedOrigins":["*"]}]}' +export CORS='{"CORSRules":[{"AllowedHeaders":["*"],"AllowedMethods":["GET", "PUT", "POST", "DELETE"],"AllowedOrigins":["*"], "ExposeHeaders":["ETag"]}]}' aws s3api put-bucket-cors --bucket ente --cors-configuration $CORS ``` @@ -600,13 +601,13 @@ hardcoded-ott: local-domain-suffix: "@example.com" # Your domain local-domain-value: 123456 # Custom One-Time Password since we are not sending mail by default key: - # You might want to change those next 3 which are the default one - encryption: yvmG/RnzKrbCb9L3mgsmoxXr9H7i2Z4qlbT0mL3ln4w= + # WARNING -- You MUST CHANGE the values below # Someone has made an image that can do it for you : https://github.com/EdyTheCow/ente-selfhost/blob/main/images/ente-server-tools/Dockerfile - hash: KXYiG07wC7GIgvCSdg+WmyWdXDAn6XKYJtp/wkEU7x573+byBRAYtpTP0wwvi8i/4l37uicX1dVTUzwH3sLZyw== -jwt: # Simply build it yourself or run docker run --rm ghcr.io/edythecow/ente-server-tools go run tools/gen-random-keys/main.go - secret: i2DecQmfGreG6q1vBj5tCokhlN41gcfS2cjOs9Po-u8= + encryption: yvmG/RnzKrbCb9L3mgsmoxXr9H7i2Z4qlbT0mL3ln4w= # CHANGE THIS VALUE + hash: KXYiG07wC7GIgvCSdg+WmyWdXDAn6XKYJtp/wkEU7x573+byBRAYtpTP0wwvi8i/4l37uicX1dVTUzwH3sLZyw== # CHANGE THIS VALUE +jwt: + secret: i2DecQmfGreG6q1vBj5tCokhlN41gcfS2cjOs9Po-u8= # CHANGE THIS VALUE ``` The full configuration file can be found [here](https://github.com/ente-io/ente/blob/main/server/configurations/local.yaml) @@ -643,11 +644,11 @@ s3: # default to true if you set "are_local_buckets: true" # use_path_style_urls: true - b2-eu-cen: # Don't change this key, it seems to be hardcoded + b2-eu-cen: # Don't change this key, it is hardcoded key: secret: - endpoint: garage:3900 - region: garage + endpoint: garage:3900 # publically accessible endpoint of your garage instance + region: garage bucket: use_path_style: true # you can specify secondary locations, names are hardcoded as well @@ -657,7 +658,6 @@ s3: # and you can also specify a bucket to be used for embeddings, preview etc.. # default to the first bucket # derived-storage: wasabi-eu-central-2-derived - ``` Finally you can run it with Docker :