Files
scripts/unraid-1/garage.template.xml

64 lines
4.4 KiB
XML

<?xml version="1.0"?>
<!--
Unraid Community Apps template for Garage (single-node S3 server).
Source of truth: pq/scripts on Gitea (https://git.docker.pq.io/pq/scripts).
Served via gitea raw URL: https://git.docker.pq.io/pq/scripts/raw/branch/main/unraid-1/garage.template.xml
This file is NOT installed directly. install.sh fetches this, substitutes
the three __PLACEHOLDER__ secrets it just generated, and writes the result
to /boot/config/plugins/dockerMan/templates-user/my-garage.xml.
Unraid then surfaces it in the "Template" dropdown on the Add Container page.
-->
<Container version="2">
<Name>garage</Name>
<Repository>dxflrs/garage:v1.0.1</Repository>
<Registry>https://hub.docker.com/r/dxflrs/garage</Registry>
<Network>bridge</Network>
<MyIP/>
<Shell>sh</Shell>
<Privileged>false</Privileged>
<Support/>
<Project>https://garagehq.deuxfleurs.fr/</Project>
<Overview>Single-node Garage S3 server. Caddy on classe terminates TLS for s3.pq.io and reverse-proxies to this container's port 3900.</Overview>
<Category>Backup: Cloud: Network:Other</Category>
<WebUI/>
<TemplateURL/>
<Icon>https://garagehq.deuxfleurs.fr/img/logo.svg</Icon>
<ExtraParams>--restart=unless-stopped --label com.centurylinklabs.watchtower.enable=true</ExtraParams>
<PostArgs/>
<CPUset/>
<DateInstalled/>
<DonateText/>
<DonateLink/>
<Description>
Single-node Garage S3 (lmdb engine, replication_factor=1). Path-style endpoint: https://s3.pq.io/&lt;bucket&gt;/&lt;key&gt;.
After the container starts the FIRST time only, initialise the cluster layout from the unraid console:
docker exec garage /garage status
# copy the node-id from the output
docker exec garage /garage layout assign -z dc1 -c 30T &lt;node-id&gt;
docker exec garage /garage layout apply --version 1
Then create a bucket and an access key:
docker exec garage /garage bucket create my-bucket
docker exec garage /garage key create my-key
docker exec garage /garage bucket allow --read --write --owner my-bucket --key my-key
docker exec garage /garage key info --show-secret my-key
</Description>
<Config Name="S3 API" Target="3900" Default="3900" Mode="tcp" Description="S3-compatible API. Caddy on classe proxies s3.pq.io here." Type="Port" Display="always" Required="true" Mask="false">3900</Config>
<Config Name="S3 Static Web" Target="3902" Default="3902" Mode="tcp" Description="Static site hosting (optional, not currently exposed via Caddy)." Type="Port" Display="advanced" Required="false" Mask="false">3902</Config>
<Config Name="Admin / Metrics" Target="3903" Default="3903" Mode="tcp" Description="Admin API + Prometheus metrics. Caddy proxies /-/health to this port." Type="Port" Display="always" Required="true" Mask="false">3903</Config>
<Config Name="Metadata (SSD)" Target="/var/lib/garage/meta" Default="/mnt/user/appdata/garage/meta" Mode="rw" Description="LMDB metadata. MUST live on SSD (appdata is cache-only by default — good)." Type="Path" Display="always" Required="true" Mask="false">/mnt/user/appdata/garage/meta</Config>
<Config Name="Data (parity)" Target="/var/lib/garage/data" Default="/mnt/user/s3/data" Mode="rw" Description="Object data chunks. Use a parity-protected share with cache:yes for SSD-fast writes + array durability." Type="Path" Display="always" Required="true" Mask="false">/mnt/user/s3/data</Config>
<Config Name="garage.toml" Target="/etc/garage.toml" Default="/mnt/user/appdata/garage/garage.toml" Mode="ro" Description="Garage config file. install.sh placed this for you." Type="Path" Display="always" Required="true" Mask="false">/mnt/user/appdata/garage/garage.toml</Config>
<Config Name="GARAGE_RPC_SECRET" Target="GARAGE_RPC_SECRET" Default="" Mode="" Description="32-byte hex inter-node secret. Pre-filled by install.sh." Type="Variable" Display="always" Required="true" Mask="true">__GARAGE_RPC_SECRET__</Config>
<Config Name="GARAGE_ADMIN_TOKEN" Target="GARAGE_ADMIN_TOKEN" Default="" Mode="" Description="32-byte hex bearer token for admin API. Pre-filled by install.sh." Type="Variable" Display="always" Required="true" Mask="true">__GARAGE_ADMIN_TOKEN__</Config>
<Config Name="GARAGE_METRICS_TOKEN" Target="GARAGE_METRICS_TOKEN" Default="" Mode="" Description="32-byte hex bearer token for Prometheus /metrics. Pre-filled by install.sh." Type="Variable" Display="always" Required="true" Mask="true">__GARAGE_METRICS_TOKEN__</Config>
</Container>