aboutsummaryrefslogtreecommitdiffstats
path: root/docs/content/doc/installation
diff options
context:
space:
mode:
authorXinyu Zhou <i@sourcehut.net>2022-11-24 02:01:38 +0800
committerGitHub <noreply@github.com>2022-11-23 13:01:38 -0500
commita3c09fb36d7820076687e683c7dd6cbc6bf8cfb5 (patch)
tree6130d5d543a2e22c57b8d72a169ecfdf860bd7d0 /docs/content/doc/installation
parent787f6c32278f1fb814ce405e960dd7c50a7d2b3b (diff)
downloadgitea-a3c09fb36d7820076687e683c7dd6cbc6bf8cfb5.tar.gz
gitea-a3c09fb36d7820076687e683c7dd6cbc6bf8cfb5.zip
Improve docker rootless documentation (#21913)
Emphasize folder creation/permission granting Signed-off-by: Xinyu Zhou <i@sourcehut.net> Signed-off-by: Xinyu Zhou <i@sourcehut.net> Co-authored-by: techknowlogick <techknowlogick@gitea.io>
Diffstat (limited to 'docs/content/doc/installation')
-rw-r--r--docs/content/doc/installation/with-docker-rootless.en-us.md24
1 files changed, 20 insertions, 4 deletions
diff --git a/docs/content/doc/installation/with-docker-rootless.en-us.md b/docs/content/doc/installation/with-docker-rootless.en-us.md
index 3cae65c2b2..8af3e5b8b6 100644
--- a/docs/content/doc/installation/with-docker-rootless.en-us.md
+++ b/docs/content/doc/installation/with-docker-rootless.en-us.md
@@ -29,10 +29,16 @@ the official [install instructions](https://docs.docker.com/compose/install/).
The most simple setup just creates a volume and a network and starts the `gitea/gitea:latest-rootless`
image as a service. Since there is no database available, one can be initialized using SQLite3.
-Create a directory for `data` and `config` then paste the following content into a file named `docker-compose.yml`.
-Note that the volume should be owned by the user/group with the UID/GID specified in the config file. By default Gitea in docker will use uid:1000 gid:1000. If needed you can set ownership on those folders with the command: `sudo chown 1000:1000 config/ data/`
-If you don't give the volume correct permissions, the container may not start.
-For a stable release you could use `:latest-rootless`, `:1-rootless` or specify a certain release like `:{{< version >}}-rootless`, but if you'd like to use the latest development version then `:dev-rootless` would be an appropriate tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-dev-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-dev-rootless`)
+
+Create a directory for `data` and `config`:
+
+```sh
+mkdir -p gitea/{data,config}
+cd gitea
+touch docker-compose.yml
+```
+
+Then paste the following content into a file named `docker-compose.yml`:
```yaml
version: "2"
@@ -51,6 +57,16 @@ services:
- "2222:2222"
```
+Note that the volume should be owned by the user/group with the UID/GID specified in the config file. By default Gitea in docker will use uid:1000 gid:1000. If needed you can set ownership on those folders with the command:
+
+```sh
+sudo chown 1000:1000 config/ data/
+```
+
+> If you don't give the volume correct permissions, the container may not start.
+
+For a stable release you could use `:latest-rootless`, `:1-rootless` or specify a certain release like `:{{< version >}}-rootless`, but if you'd like to use the latest development version then `:dev-rootless` would be an appropriate tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-dev-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-dev-rootless`)
+
## Custom port
To bind the integrated ssh and the webserver on a different port, adjust