diff --git a/docs/administration/external-renderers.md b/docs/administration/external-renderers.md index e25ff369..60313b69 100644 --- a/docs/administration/external-renderers.md +++ b/docs/administration/external-renderers.md @@ -23,7 +23,7 @@ In order to get file rendering through external binaries, their associated packa If you're using a Docker image, your `Dockerfile` should contain something along this lines: ```docker -FROM gitea/gitea:@version@ +FROM gitea/gitea:@dockerVersion@ [...] COPY custom/app.ini /data/gitea/conf/app.ini diff --git a/docs/installation/from-source.md b/docs/installation/from-source.md index 976476c6..c0f31588 100644 --- a/docs/installation/from-source.md +++ b/docs/installation/from-source.md @@ -45,7 +45,7 @@ To work with tagged releases, the following commands can be used: ```bash git branch -a -git checkout v@version@ +git checkout @sourceBranch@ ``` To validate a Pull Request, first enable the new branch (`xyz` is the PR id; @@ -55,14 +55,14 @@ for example `2663` for [#2663](https://github.com/go-gitea/gitea/pull/2663)): git fetch origin pull/xyz/head:pr-xyz ``` -To build Gitea from source at a specific tagged release (like v@version@), list the +To build Gitea from source at a specific tagged release (like @sourceVersion@), list the available tags and check out the specific tag. List available tags with the following. ```bash git tag -l -git checkout v@version@ # or git checkout pr-xyz +git checkout @sourceVersion@ # or git checkout pr-xyz ``` ## Build diff --git a/docs/installation/with-docker-rootless.md b/docs/installation/with-docker-rootless.md index 94b89294..e1a45dd1 100644 --- a/docs/installation/with-docker-rootless.md +++ b/docs/installation/with-docker-rootless.md @@ -38,7 +38,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -58,7 +58,7 @@ 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 `:nightly-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-nightly-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly-rootless`) +For a stable release you could use `:latest-rootless`, `:1-rootless` or specify a certain release like `:@dockerVersion@-rootless`, but if you'd like to use the latest development version then `:nightly-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-nightly-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly-rootless`) ## Custom port @@ -71,7 +71,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -95,7 +95,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless + environment: + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 @@ -136,7 +136,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless environment: + - GITEA__database__DB_TYPE=postgres + - GITEA__database__HOST=db:5432 @@ -184,7 +184,7 @@ version: "2" + services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - - ./data:/var/lib/gitea @@ -211,7 +211,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always + user: 1001 volumes: @@ -283,7 +283,7 @@ docker-compose up -d - Rename folder (inside volume) gitea to custom - Edit app.ini if needed - Set START_SSH_SERVER = true -- Use image gitea/gitea:@version@-rootless +- Use image gitea/gitea:@dockerVersion@-rootless ## Managing Deployments With Environment Variables diff --git a/docs/installation/with-docker.md b/docs/installation/with-docker.md index 5fff4a25..e60d6f60 100644 --- a/docs/installation/with-docker.md +++ b/docs/installation/with-docker.md @@ -23,7 +23,7 @@ image as a service. Since there is no database available, one can be initialized Create a directory like `gitea` and 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. If you don't give the volume correct permissions, the container may not start. -For a stable release you can use `:latest`, `:1` or specify a certain release like `:@version@`, but if you'd like to use the latest development version of Gitea then you could use the `:nightly` tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-nightly` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly`) +For a stable release you can use `:latest`, `:1` or specify a certain release like `:@dockerVersion@`, but if you'd like to use the latest development version of Gitea then you could use the `:nightly` tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-nightly` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly`) ```yaml version: "3" @@ -34,7 +34,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -66,7 +66,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -101,7 +101,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -152,7 +152,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -208,7 +208,7 @@ networks: + services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea restart: always networks: diff --git a/docusaurus.config.js b/docusaurus.config.js index 68d878fa..9dfe85a2 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -61,6 +61,78 @@ const pageConfig = renderApiSSR ? { ], }: {} +const globalVariables = { + current: { + 'goVersion': '1.22', + 'minGoVersion': '1.22', + 'minNodeVersion': '18', + 'version': 'main-nightly', + 'sourceVersion': 'main', + 'sourceBranch': 'main', + 'dockerVersion': 'nightly', + 'displayVersion': '1.23-dev' + }, + '1.22': { + 'goVersion': '1.22', + 'minGoVersion': '1.22', + 'minNodeVersion': '18', + 'version': '1.22.1', + 'sourceVersion': 'v1.22.1', + 'sourceBranch': 'release/v1.22', + 'dockerVersion': '1.22.1', + 'displayVersion': '1.22.1' + }, + '1.21': { + 'goVersion': '1.21', + 'minGoVersion': '1.21', + 'minNodeVersion': '18', + 'version': '1.21.11', + 'sourceVersion': 'v1.21.11', + 'sourceBranch': 'release/v1.21', + 'dockerVersion': '1.21.11', + 'displayVersion': '1.21.11' + }, + '1.20': { + 'goVersion': '1.20', + 'minGoVersion': '1.20', + 'minNodeVersion': '16', + 'version': '1.20.6', + 'sourceVersion': 'v1.20.6', + 'sourceBranch': 'release/v1.20', + 'dockerVersion': '1.20.6', + 'displayVersion': '1.20.6' + }, + '1.19': { + 'goVersion': '1.20', + 'minGoVersion': '1.19', + 'minNodeVersion': '14', + 'version': '1.19.4', + 'sourceVersion': 'v1.19.4', + 'sourceBranch': 'release/v1.19', + 'dockerVersion': '1.19.4', + 'displayVersion': '1.19.4' + } +} + +const versions = { + current: { + label: globalVariables['current'].displayVersion, // path is kept as next for dev (so users can always find "nightly" docs) + banner: 'unreleased', + }, + '1.22': { + label: globalVariables['1.22'].displayVersion, + }, + '1.21': { + label: globalVariables['1.21'].displayVersion, + }, + '1.20': { + label: globalVariables['1.20'].displayVersion, + }, + '1.19': { + label: globalVariables['1.19'].displayVersion, + } +} + /** @type {import('@docusaurus/types').Config} */ const config = { title: 'Gitea Documentation', @@ -112,24 +184,7 @@ const config = { } return `https://gitea.com/gitea/docs/src/branch/main/i18n/${locale}/docusaurus-plugin-content-docs/${version === 'current' ? 'current': `version-${version}`}/${docPath}`; }, - versions: { - current: { - label: '1.23-dev', // path is kept as next for dev (so users can always find "nightly" docs) - banner: 'unreleased', - }, - '1.22': { - label: '1.22.1', - }, - '1.21': { - label: '1.21.11', - }, - '1.20': { - label: '1.20.6' - }, - '1.19': { - label: '1.19.4', - } - }, + versions: versions, lastVersion: '1.22', async sidebarItemsGenerator({defaultSidebarItemsGenerator, ...args}) { const {item} = args; @@ -154,6 +209,29 @@ const config = { ], apiConfig, ], + markdown: { + preprocessor: ({filePath, fileContent}) => { + var key = ''; + var found = false; + for (key in globalVariables) { + let folderName = (key == 'current' ? 'current' : `version-${key}`); + if (filePath.includes(`/${folderName}/`)) { + found = true; + break; + } + } + if (key == '' || !found) { + key = 'current'; + } + + let content = fileContent; + for (const variable in globalVariables[key]) { + content = content.replaceAll('@'+variable+'@', globalVariables[key][variable]); + } + + return content + }, + }, themes: [ [ "@easyops-cn/docusaurus-search-local", diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/current/administration/external-renderers.md b/i18n/zh-cn/docusaurus-plugin-content-docs/current/administration/external-renderers.md index cd19d3da..186ad61e 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/current/administration/external-renderers.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/current/administration/external-renderers.md @@ -24,7 +24,7 @@ Gitea 通过外部二进制文件支持自定义文件渲染(例如 Jupyter no 如果您正在使用 Docker 镜像,则您的 `Dockerfile` 应该包含以下内容: ```docker -FROM gitea/gitea:@version@ +FROM gitea/gitea:@dockerVersion@ [...] COPY custom/app.ini /data/gitea/conf/app.ini diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/from-source.md b/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/from-source.md index f29ef101..8e51c540 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/from-source.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/from-source.md @@ -30,7 +30,7 @@ git clone https://github.com/go-gitea/gitea ```bash git branch -a -git checkout v@version@ +git checkout @sourceBranch@ ``` 要验证一个拉取请求(Pull Request, PR),要先启用新的分支(其中 `xyz` 是 PR 的 ID;例如,对于 [#2663](https://github.com/go-gitea/gitea/pull/2663),ID是 `2663 `): @@ -39,12 +39,12 @@ git checkout v@version@ git fetch origin pull/xyz/head:pr-xyz ``` -要以指定发行版本(如 v@version@ )的源代码来构建 Gitea,可执行以下命令列出可用的版本并选择某个版本签出。 +要以指定发行版本(如 @sourceVersion@ )的源代码来构建 Gitea,可执行以下命令列出可用的版本并选择某个版本签出。 使用以下命令列出可用的版本: ```bash git tag -l -git checkout v@version@ # or git checkout pr-xyz +git checkout @sourceVersion@ # or git checkout pr-xyz ``` ## 构建 diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/with-docker-rootless.md b/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/with-docker-rootless.md index 6ea2339d..3a380182 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/with-docker-rootless.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/with-docker-rootless.md @@ -33,7 +33,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -53,7 +53,7 @@ sudo chown 1000:1000 config/ data/ > 如果未为卷设置正确的权限,容器可能无法启动。 -对于稳定版本,您可以使用 `:latest-rootless`、`:1-rootless`,或指定特定的版本,如: `@version@-rootless`。如果您想使用最新的开发版本,则可以使用 `:dev-rootless` 标签。如果您想运行发布分支的最新提交,可以使用 `:1.x-dev-rootless` 标签,其中 x是 Gitea 的次要版本号(例如:`1.16-dev-rootless`)。 +对于稳定版本,您可以使用 `:latest-rootless`、`:1-rootless`,或指定特定的版本,如: `@dockerVersion@-rootless`。如果您想使用最新的开发版本,则可以使用 `:dev-rootless` 标签。如果您想运行发布分支的最新提交,可以使用 `:1.x-dev-rootless` 标签,其中 x是 Gitea 的次要版本号(例如:`1.16-dev-rootless`)。 ## 自定义端口 @@ -64,7 +64,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -87,7 +87,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless + environment: + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 @@ -127,7 +127,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless environment: + - GITEA__database__DB_TYPE=postgres + - GITEA__database__HOST=db:5432 @@ -172,7 +172,7 @@ version: "2" + services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - - ./data:/var/lib/gitea @@ -199,7 +199,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always + user: 1001 volumes: @@ -252,7 +252,7 @@ docker-compose up -d - 将卷中的文件夹(gitea)重命名为 custom - 如果需要,编辑 `app.ini` - 设置 `START_SSH_SERVER = true` -- 使用镜像 `gitea/gitea:@version@-rootless` +- 使用镜像 `gitea/gitea:@dockerVersion@-rootless` ## 使用环境变量管理部署 diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/with-docker.md b/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/with-docker.md index fd4cb30d..b7bf4ce0 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/with-docker.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/current/installation/with-docker.md @@ -14,7 +14,7 @@ Gitea 在其 Docker Hub 组织内提供自动更新的 Docker 镜像。可以始 ## 基本 -最简单的设置只是创建一个卷和一个网络,然后将 `gitea/gitea:latest` 镜像作为服务启动。由于没有可用的数据库,因此可以使用 SQLite3 初始化数据库。创建一个类似 `gitea` 的目录,并将以下内容粘贴到名为 `docker-compose.yml` 的文件中。请注意,该卷应由配置文件中指定的 UID/GID 的用户/组拥有。如果您不授予卷正确的权限,则容器可能无法启动。另请注意,标签 `:latest` 将安装当前的开发版本。对于稳定的发行版,您可以使用 `:1` 或指定某个发行版,例如 `@version@`。 +最简单的设置只是创建一个卷和一个网络,然后将 `gitea/gitea:latest` 镜像作为服务启动。由于没有可用的数据库,因此可以使用 SQLite3 初始化数据库。创建一个类似 `gitea` 的目录,并将以下内容粘贴到名为 `docker-compose.yml` 的文件中。请注意,该卷应由配置文件中指定的 UID/GID 的用户/组拥有。如果您不授予卷正确的权限,则容器可能无法启动。另请注意,标签 `:latest` 将安装当前的开发版本。对于稳定的发行版,您可以使用 `:1` 或指定某个发行版,例如 `@dockerVersion@`。 ```yaml version: "3" @@ -25,7 +25,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -55,7 +55,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -89,7 +89,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -139,7 +139,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -192,7 +192,7 @@ networks: + services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea restart: always networks: diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/administration/external-renderers.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/administration/external-renderers.md index eb058931..2a9235bd 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/administration/external-renderers.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/administration/external-renderers.md @@ -22,7 +22,7 @@ Gitea 通过外部二进制文件支持自定义文件渲染(例如 Jupyter no 如果您正在使用 Docker 镜像,则您的 `Dockerfile` 应该包含以下内容: ```docker -FROM gitea/gitea:@version@ +FROM gitea/gitea:@dockerVersion@ [...] COPY custom/app.ini /data/gitea/conf/app.ini diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/from-source.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/from-source.md index 64ee9c24..aebffe70 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/from-source.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/from-source.md @@ -25,14 +25,14 @@ cd gitea ```bash git branch -a -git checkout v@version@ +git checkout @sourceBranch@ ``` -最后,你也可以直接使用标签版本如 `v@version@`。你可以执行以下命令列出可用的版本并选择某个版本签出: +最后,你也可以直接使用标签版本如 `@sourceVersion@`。你可以执行以下命令列出可用的版本并选择某个版本签出: ```bash git tag -l -git checkout v@version@ +git checkout @sourceVersion@ ``` ## 编译 diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/with-docker-rootless.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/with-docker-rootless.md index e63be2e9..7fdac22d 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/with-docker-rootless.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/with-docker-rootless.md @@ -33,7 +33,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -53,7 +53,7 @@ sudo chown 1000:1000 config/ data/ > 如果未为卷设置正确的权限,容器可能无法启动。 -对于稳定版本,您可以使用 `:latest-rootless`、`:1-rootless`,或指定特定的版本,如: `@version@-rootless`。如果您想使用最新的开发版本,则可以使用 `:dev-rootless` 标签。如果您想运行发布分支的最新提交,可以使用 `:1.x-dev-rootless` 标签,其中 x是 Gitea 的次要版本号(例如:`1.16-dev-rootless`)。 +对于稳定版本,您可以使用 `:latest-rootless`、`:1-rootless`,或指定特定的版本,如: `@dockerVersion@-rootless`。如果您想使用最新的开发版本,则可以使用 `:dev-rootless` 标签。如果您想运行发布分支的最新提交,可以使用 `:1.x-dev-rootless` 标签,其中 x是 Gitea 的次要版本号(例如:`1.16-dev-rootless`)。 ## 自定义端口 @@ -64,7 +64,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -87,7 +87,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless + environment: + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 @@ -127,7 +127,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless environment: + - GITEA__database__DB_TYPE=postgres + - GITEA__database__HOST=db:5432 @@ -172,7 +172,7 @@ version: "2" + services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - - ./data:/var/lib/gitea @@ -199,7 +199,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always + user: 1001 volumes: @@ -252,7 +252,7 @@ docker-compose up -d - 将卷中的文件夹(gitea)重命名为 custom - 如果需要,编辑 `app.ini` - 设置 `START_SSH_SERVER = true` -- 使用镜像 `gitea/gitea:@version@-rootless` +- 使用镜像 `gitea/gitea:@dockerVersion@-rootless` ## 使用环境变量管理部署 diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/with-docker.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/with-docker.md index cb0e820d..9be08330 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/with-docker.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.19/installation/with-docker.md @@ -12,7 +12,7 @@ Gitea 在其 Docker Hub 组织内提供自动更新的 Docker 镜像。可以始 ## 基本 -最简单的设置只是创建一个卷和一个网络,然后将 `gitea/gitea:latest` 镜像作为服务启动。由于没有可用的数据库,因此可以使用 SQLite3 初始化数据库。创建一个类似 `gitea` 的目录,并将以下内容粘贴到名为 `docker-compose.yml` 的文件中。请注意,该卷应由配置文件中指定的 UID/GID 的用户/组拥有。如果您不授予卷正确的权限,则容器可能无法启动。另请注意,标签 `:latest` 将安装当前的开发版本。对于稳定的发行版,您可以使用 `:1` 或指定某个发行版,例如 `@version@`。 +最简单的设置只是创建一个卷和一个网络,然后将 `gitea/gitea:latest` 镜像作为服务启动。由于没有可用的数据库,因此可以使用 SQLite3 初始化数据库。创建一个类似 `gitea` 的目录,并将以下内容粘贴到名为 `docker-compose.yml` 的文件中。请注意,该卷应由配置文件中指定的 UID/GID 的用户/组拥有。如果您不授予卷正确的权限,则容器可能无法启动。另请注意,标签 `:latest` 将安装当前的开发版本。对于稳定的发行版,您可以使用 `:1` 或指定某个发行版,例如 `@dockerVersion@`。 ```yaml version: "3" @@ -23,7 +23,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -53,7 +53,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -87,7 +87,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -137,7 +137,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -190,7 +190,7 @@ networks: + services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea restart: always networks: diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/administration/external-renderers.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/administration/external-renderers.md index eb058931..2a9235bd 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/administration/external-renderers.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/administration/external-renderers.md @@ -22,7 +22,7 @@ Gitea 通过外部二进制文件支持自定义文件渲染(例如 Jupyter no 如果您正在使用 Docker 镜像,则您的 `Dockerfile` 应该包含以下内容: ```docker -FROM gitea/gitea:@version@ +FROM gitea/gitea:@dockerVersion@ [...] COPY custom/app.ini /data/gitea/conf/app.ini diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/from-source.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/from-source.md index bdc34aec..d7bd4eb7 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/from-source.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/from-source.md @@ -30,14 +30,14 @@ cd gitea ```bash git branch -a -git checkout v@version@ +git checkout @sourceBranch@ ``` -最后,你也可以直接使用标签版本如 `v@version@`。你可以执行以下命令列出可用的版本并选择某个版本签出: +最后,你也可以直接使用标签版本如 `@sourceVersion@`。你可以执行以下命令列出可用的版本并选择某个版本签出: ```bash git tag -l -git checkout v@version@ +git checkout @sourceVersion@ ``` ## 编译 diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/with-docker-rootless.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/with-docker-rootless.md index 6ea2339d..3a380182 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/with-docker-rootless.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/with-docker-rootless.md @@ -33,7 +33,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -53,7 +53,7 @@ sudo chown 1000:1000 config/ data/ > 如果未为卷设置正确的权限,容器可能无法启动。 -对于稳定版本,您可以使用 `:latest-rootless`、`:1-rootless`,或指定特定的版本,如: `@version@-rootless`。如果您想使用最新的开发版本,则可以使用 `:dev-rootless` 标签。如果您想运行发布分支的最新提交,可以使用 `:1.x-dev-rootless` 标签,其中 x是 Gitea 的次要版本号(例如:`1.16-dev-rootless`)。 +对于稳定版本,您可以使用 `:latest-rootless`、`:1-rootless`,或指定特定的版本,如: `@dockerVersion@-rootless`。如果您想使用最新的开发版本,则可以使用 `:dev-rootless` 标签。如果您想运行发布分支的最新提交,可以使用 `:1.x-dev-rootless` 标签,其中 x是 Gitea 的次要版本号(例如:`1.16-dev-rootless`)。 ## 自定义端口 @@ -64,7 +64,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -87,7 +87,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless + environment: + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 @@ -127,7 +127,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless environment: + - GITEA__database__DB_TYPE=postgres + - GITEA__database__HOST=db:5432 @@ -172,7 +172,7 @@ version: "2" + services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - - ./data:/var/lib/gitea @@ -199,7 +199,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always + user: 1001 volumes: @@ -252,7 +252,7 @@ docker-compose up -d - 将卷中的文件夹(gitea)重命名为 custom - 如果需要,编辑 `app.ini` - 设置 `START_SSH_SERVER = true` -- 使用镜像 `gitea/gitea:@version@-rootless` +- 使用镜像 `gitea/gitea:@dockerVersion@-rootless` ## 使用环境变量管理部署 diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/with-docker.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/with-docker.md index 2c11809e..2dad81ed 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/with-docker.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.20/installation/with-docker.md @@ -17,7 +17,7 @@ Gitea 在其 Docker Hub 组织内提供自动更新的 Docker 镜像。可以始 ## 基本 -最简单的设置只是创建一个卷和一个网络,然后将 `gitea/gitea:latest` 镜像作为服务启动。由于没有可用的数据库,因此可以使用 SQLite3 初始化数据库。创建一个类似 `gitea` 的目录,并将以下内容粘贴到名为 `docker-compose.yml` 的文件中。请注意,该卷应由配置文件中指定的 UID/GID 的用户/组拥有。如果您不授予卷正确的权限,则容器可能无法启动。另请注意,标签 `:latest` 将安装当前的开发版本。对于稳定的发行版,您可以使用 `:1` 或指定某个发行版,例如 `@version@`。 +最简单的设置只是创建一个卷和一个网络,然后将 `gitea/gitea:latest` 镜像作为服务启动。由于没有可用的数据库,因此可以使用 SQLite3 初始化数据库。创建一个类似 `gitea` 的目录,并将以下内容粘贴到名为 `docker-compose.yml` 的文件中。请注意,该卷应由配置文件中指定的 UID/GID 的用户/组拥有。如果您不授予卷正确的权限,则容器可能无法启动。另请注意,标签 `:latest` 将安装当前的开发版本。对于稳定的发行版,您可以使用 `:1` 或指定某个发行版,例如 `@dockerVersion@`。 ```yaml version: "3" @@ -28,7 +28,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -58,7 +58,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -92,7 +92,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -142,7 +142,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -195,7 +195,7 @@ networks: + services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea restart: always networks: diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/administration/external-renderers.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/administration/external-renderers.md index 8f8df4fa..ce56249e 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/administration/external-renderers.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/administration/external-renderers.md @@ -22,7 +22,7 @@ Gitea 通过外部二进制文件支持自定义文件渲染(例如 Jupyter no 如果您正在使用 Docker 镜像,则您的 `Dockerfile` 应该包含以下内容: ```docker -FROM gitea/gitea:@version@ +FROM gitea/gitea:@dockerVersion@ [...] COPY custom/app.ini /data/gitea/conf/app.ini diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/from-source.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/from-source.md index d1de77e3..91c16081 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/from-source.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/from-source.md @@ -33,7 +33,7 @@ git clone https://github.com/go-gitea/gitea ```bash git branch -a -git checkout v@version@ +git checkout @sourceBranch@ ``` 要验证一个拉取请求(Pull Request, PR),要先启用新的分支(其中 `xyz` 是 PR 的 ID;例如,对于 [#2663](https://github.com/go-gitea/gitea/pull/2663),ID是 `2663 `): @@ -42,12 +42,12 @@ git checkout v@version@ git fetch origin pull/xyz/head:pr-xyz ``` -要以指定发行版本(如 v@version@ )的源代码来构建 Gitea,可执行以下命令列出可用的版本并选择某个版本签出。 +要以指定发行版本(如 @sourceVersion@ )的源代码来构建 Gitea,可执行以下命令列出可用的版本并选择某个版本签出。 使用以下命令列出可用的版本: ```bash git tag -l -git checkout v@version@ # or git checkout pr-xyz +git checkout @sourceVersion@ # or git checkout pr-xyz ``` ## 构建 diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/with-docker-rootless.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/with-docker-rootless.md index 6ea2339d..3a380182 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/with-docker-rootless.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/with-docker-rootless.md @@ -33,7 +33,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -53,7 +53,7 @@ sudo chown 1000:1000 config/ data/ > 如果未为卷设置正确的权限,容器可能无法启动。 -对于稳定版本,您可以使用 `:latest-rootless`、`:1-rootless`,或指定特定的版本,如: `@version@-rootless`。如果您想使用最新的开发版本,则可以使用 `:dev-rootless` 标签。如果您想运行发布分支的最新提交,可以使用 `:1.x-dev-rootless` 标签,其中 x是 Gitea 的次要版本号(例如:`1.16-dev-rootless`)。 +对于稳定版本,您可以使用 `:latest-rootless`、`:1-rootless`,或指定特定的版本,如: `@dockerVersion@-rootless`。如果您想使用最新的开发版本,则可以使用 `:dev-rootless` 标签。如果您想运行发布分支的最新提交,可以使用 `:1.x-dev-rootless` 标签,其中 x是 Gitea 的次要版本号(例如:`1.16-dev-rootless`)。 ## 自定义端口 @@ -64,7 +64,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -87,7 +87,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless + environment: + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 @@ -127,7 +127,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless environment: + - GITEA__database__DB_TYPE=postgres + - GITEA__database__HOST=db:5432 @@ -172,7 +172,7 @@ version: "2" + services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - - ./data:/var/lib/gitea @@ -199,7 +199,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always + user: 1001 volumes: @@ -252,7 +252,7 @@ docker-compose up -d - 将卷中的文件夹(gitea)重命名为 custom - 如果需要,编辑 `app.ini` - 设置 `START_SSH_SERVER = true` -- 使用镜像 `gitea/gitea:@version@-rootless` +- 使用镜像 `gitea/gitea:@dockerVersion@-rootless` ## 使用环境变量管理部署 diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/with-docker.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/with-docker.md index c75b3050..15337a5d 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/with-docker.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.21/installation/with-docker.md @@ -17,7 +17,7 @@ Gitea 在其 Docker Hub 组织内提供自动更新的 Docker 镜像。可以始 ## 基本 -最简单的设置只是创建一个卷和一个网络,然后将 `gitea/gitea:latest` 镜像作为服务启动。由于没有可用的数据库,因此可以使用 SQLite3 初始化数据库。创建一个类似 `gitea` 的目录,并将以下内容粘贴到名为 `docker-compose.yml` 的文件中。请注意,该卷应由配置文件中指定的 UID/GID 的用户/组拥有。如果您不授予卷正确的权限,则容器可能无法启动。另请注意,标签 `:latest` 将安装当前的开发版本。对于稳定的发行版,您可以使用 `:1` 或指定某个发行版,例如 `@version@`。 +最简单的设置只是创建一个卷和一个网络,然后将 `gitea/gitea:latest` 镜像作为服务启动。由于没有可用的数据库,因此可以使用 SQLite3 初始化数据库。创建一个类似 `gitea` 的目录,并将以下内容粘贴到名为 `docker-compose.yml` 的文件中。请注意,该卷应由配置文件中指定的 UID/GID 的用户/组拥有。如果您不授予卷正确的权限,则容器可能无法启动。另请注意,标签 `:latest` 将安装当前的开发版本。对于稳定的发行版,您可以使用 `:1` 或指定某个发行版,例如 `@dockerVersion@`。 ```yaml version: "3" @@ -28,7 +28,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -58,7 +58,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -92,7 +92,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -142,7 +142,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -195,7 +195,7 @@ networks: + services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea restart: always networks: diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/administration/external-renderers.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/administration/external-renderers.md index e7888fbd..7d462496 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/administration/external-renderers.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/administration/external-renderers.md @@ -25,7 +25,7 @@ Gitea 通过外部二进制文件支持自定义文件渲染(例如 Jupyter no 如果您正在使用 Docker 镜像,则您的 `Dockerfile` 应该包含以下内容: ```docker -FROM gitea/gitea:@version@ +FROM gitea/gitea:@dockerVersion@ [...] COPY custom/app.ini /data/gitea/conf/app.ini diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/from-source.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/from-source.md index 5be23982..fe576847 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/from-source.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/from-source.md @@ -33,7 +33,7 @@ git clone https://github.com/go-gitea/gitea ```bash git branch -a -git checkout v@version@ +git checkout @sourceBranch@ ``` 要验证一个拉取请求(Pull Request, PR),要先启用新的分支(其中 `xyz` 是 PR 的 ID;例如,对于 [#2663](https://github.com/go-gitea/gitea/pull/2663),ID是 `2663 `): @@ -42,12 +42,12 @@ git checkout v@version@ git fetch origin pull/xyz/head:pr-xyz ``` -要以指定发行版本(如 v@version@ )的源代码来构建 Gitea,可执行以下命令列出可用的版本并选择某个版本签出。 +要以指定发行版本(如 @sourceVersion@ )的源代码来构建 Gitea,可执行以下命令列出可用的版本并选择某个版本签出。 使用以下命令列出可用的版本: ```bash git tag -l -git checkout v@version@ # or git checkout pr-xyz +git checkout @sourceVersion@ # or git checkout pr-xyz ``` ## 构建 diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/with-docker-rootless.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/with-docker-rootless.md index 6ea2339d..3a380182 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/with-docker-rootless.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/with-docker-rootless.md @@ -33,7 +33,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -53,7 +53,7 @@ sudo chown 1000:1000 config/ data/ > 如果未为卷设置正确的权限,容器可能无法启动。 -对于稳定版本,您可以使用 `:latest-rootless`、`:1-rootless`,或指定特定的版本,如: `@version@-rootless`。如果您想使用最新的开发版本,则可以使用 `:dev-rootless` 标签。如果您想运行发布分支的最新提交,可以使用 `:1.x-dev-rootless` 标签,其中 x是 Gitea 的次要版本号(例如:`1.16-dev-rootless`)。 +对于稳定版本,您可以使用 `:latest-rootless`、`:1-rootless`,或指定特定的版本,如: `@dockerVersion@-rootless`。如果您想使用最新的开发版本,则可以使用 `:dev-rootless` 标签。如果您想运行发布分支的最新提交,可以使用 `:1.x-dev-rootless` 标签,其中 x是 Gitea 的次要版本号(例如:`1.16-dev-rootless`)。 ## 自定义端口 @@ -64,7 +64,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -87,7 +87,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless + environment: + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 @@ -127,7 +127,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless environment: + - GITEA__database__DB_TYPE=postgres + - GITEA__database__HOST=db:5432 @@ -172,7 +172,7 @@ version: "2" + services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - - ./data:/var/lib/gitea @@ -199,7 +199,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always + user: 1001 volumes: @@ -252,7 +252,7 @@ docker-compose up -d - 将卷中的文件夹(gitea)重命名为 custom - 如果需要,编辑 `app.ini` - 设置 `START_SSH_SERVER = true` -- 使用镜像 `gitea/gitea:@version@-rootless` +- 使用镜像 `gitea/gitea:@dockerVersion@-rootless` ## 使用环境变量管理部署 diff --git a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/with-docker.md b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/with-docker.md index c75b3050..15337a5d 100644 --- a/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/with-docker.md +++ b/i18n/zh-cn/docusaurus-plugin-content-docs/version-1.22/installation/with-docker.md @@ -17,7 +17,7 @@ Gitea 在其 Docker Hub 组织内提供自动更新的 Docker 镜像。可以始 ## 基本 -最简单的设置只是创建一个卷和一个网络,然后将 `gitea/gitea:latest` 镜像作为服务启动。由于没有可用的数据库,因此可以使用 SQLite3 初始化数据库。创建一个类似 `gitea` 的目录,并将以下内容粘贴到名为 `docker-compose.yml` 的文件中。请注意,该卷应由配置文件中指定的 UID/GID 的用户/组拥有。如果您不授予卷正确的权限,则容器可能无法启动。另请注意,标签 `:latest` 将安装当前的开发版本。对于稳定的发行版,您可以使用 `:1` 或指定某个发行版,例如 `@version@`。 +最简单的设置只是创建一个卷和一个网络,然后将 `gitea/gitea:latest` 镜像作为服务启动。由于没有可用的数据库,因此可以使用 SQLite3 初始化数据库。创建一个类似 `gitea` 的目录,并将以下内容粘贴到名为 `docker-compose.yml` 的文件中。请注意,该卷应由配置文件中指定的 UID/GID 的用户/组拥有。如果您不授予卷正确的权限,则容器可能无法启动。另请注意,标签 `:latest` 将安装当前的开发版本。对于稳定的发行版,您可以使用 `:1` 或指定某个发行版,例如 `@dockerVersion@`。 ```yaml version: "3" @@ -28,7 +28,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -58,7 +58,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -92,7 +92,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -142,7 +142,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -195,7 +195,7 @@ networks: + services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea restart: always networks: diff --git a/versioned_docs/version-1.19/administration/external-renderers.md b/versioned_docs/version-1.19/administration/external-renderers.md index 7ac33c87..975e7ed7 100644 --- a/versioned_docs/version-1.19/administration/external-renderers.md +++ b/versioned_docs/version-1.19/administration/external-renderers.md @@ -21,7 +21,7 @@ In order to get file rendering through external binaries, their associated packa If you're using a Docker image, your `Dockerfile` should contain something along this lines: ```docker -FROM gitea/gitea:@version@ +FROM gitea/gitea:@dockerVersion@ [...] COPY custom/app.ini /data/gitea/conf/app.ini diff --git a/versioned_docs/version-1.19/installation/from-source.md b/versioned_docs/version-1.19/installation/from-source.md index fb2f4206..a06f3fca 100644 --- a/versioned_docs/version-1.19/installation/from-source.md +++ b/versioned_docs/version-1.19/installation/from-source.md @@ -51,7 +51,7 @@ To work with tagged releases, the following commands can be used: ```bash git branch -a -git checkout v@version@ +git checkout @sourceBranch@ ``` To validate a Pull Request, first enable the new branch (`xyz` is the PR id; @@ -61,14 +61,14 @@ for example `2663` for [#2663](https://github.com/go-gitea/gitea/pull/2663)): git fetch origin pull/xyz/head:pr-xyz ``` -To build Gitea from source at a specific tagged release (like v@version@), list the +To build Gitea from source at a specific tagged release (like @sourceVersion@), list the available tags and check out the specific tag. List available tags with the following. ```bash git tag -l -git checkout v@version@ # or git checkout pr-xyz +git checkout @sourceVersion@ # or git checkout pr-xyz ``` ## Build diff --git a/versioned_docs/version-1.19/installation/with-docker-rootless.md b/versioned_docs/version-1.19/installation/with-docker-rootless.md index 1e5e86f7..a61ade8a 100644 --- a/versioned_docs/version-1.19/installation/with-docker-rootless.md +++ b/versioned_docs/version-1.19/installation/with-docker-rootless.md @@ -36,7 +36,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -56,7 +56,7 @@ 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 `:nightly-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-nightly-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly-rootless`) +For a stable release you could use `:latest-rootless`, `:1-rootless` or specify a certain release like `:@dockerVersion@-rootless`, but if you'd like to use the latest development version then `:nightly-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-nightly-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly-rootless`) ## Custom port @@ -69,7 +69,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -93,7 +93,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless + environment: + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 @@ -134,7 +134,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless environment: + - GITEA__database__DB_TYPE=postgres + - GITEA__database__HOST=db:5432 @@ -182,7 +182,7 @@ version: "2" + services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - - ./data:/var/lib/gitea @@ -209,7 +209,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always + user: 1001 volumes: @@ -281,7 +281,7 @@ docker-compose up -d - Rename folder (inside volume) gitea to custom - Edit app.ini if needed - Set START_SSH_SERVER = true -- Use image gitea/gitea:@version@-rootless +- Use image gitea/gitea:@dockerVersion@-rootless ## Managing Deployments With Environment Variables diff --git a/versioned_docs/version-1.19/installation/with-docker.md b/versioned_docs/version-1.19/installation/with-docker.md index adda004c..6ccc7729 100644 --- a/versioned_docs/version-1.19/installation/with-docker.md +++ b/versioned_docs/version-1.19/installation/with-docker.md @@ -21,7 +21,7 @@ image as a service. Since there is no database available, one can be initialized Create a directory like `gitea` and 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. If you don't give the volume correct permissions, the container may not start. -For a stable release you can use `:latest`, `:1` or specify a certain release like `:@version@`, but if you'd like to use the latest development version of Gitea then you could use the `:nightly` tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-nightly` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly`) +For a stable release you can use `:latest`, `:1` or specify a certain release like `:@dockerVersion@`, but if you'd like to use the latest development version of Gitea then you could use the `:nightly` tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-nightly` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly`) ```yaml version: "3" @@ -32,7 +32,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -64,7 +64,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -99,7 +99,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -150,7 +150,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -206,7 +206,7 @@ networks: + services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea restart: always networks: diff --git a/versioned_docs/version-1.20/administration/external-renderers.md b/versioned_docs/version-1.20/administration/external-renderers.md index de371e21..f91d7c0e 100644 --- a/versioned_docs/version-1.20/administration/external-renderers.md +++ b/versioned_docs/version-1.20/administration/external-renderers.md @@ -25,7 +25,7 @@ In order to get file rendering through external binaries, their associated packa If you're using a Docker image, your `Dockerfile` should contain something along this lines: ```docker -FROM gitea/gitea:@version@ +FROM gitea/gitea:@dockerVersion@ [...] COPY custom/app.ini /data/gitea/conf/app.ini diff --git a/versioned_docs/version-1.20/installation/from-source.md b/versioned_docs/version-1.20/installation/from-source.md index 74070ccf..70571878 100644 --- a/versioned_docs/version-1.20/installation/from-source.md +++ b/versioned_docs/version-1.20/installation/from-source.md @@ -55,7 +55,7 @@ To work with tagged releases, the following commands can be used: ```bash git branch -a -git checkout v@version@ +git checkout @sourceBranch@ ``` To validate a Pull Request, first enable the new branch (`xyz` is the PR id; @@ -65,14 +65,14 @@ for example `2663` for [#2663](https://github.com/go-gitea/gitea/pull/2663)): git fetch origin pull/xyz/head:pr-xyz ``` -To build Gitea from source at a specific tagged release (like v@version@), list the +To build Gitea from source at a specific tagged release (like @sourceVersion@), list the available tags and check out the specific tag. List available tags with the following. ```bash git tag -l -git checkout v@version@ # or git checkout pr-xyz +git checkout @sourceVersion@ # or git checkout pr-xyz ``` ## Build diff --git a/versioned_docs/version-1.20/installation/with-docker-rootless.md b/versioned_docs/version-1.20/installation/with-docker-rootless.md index 94b89294..e1a45dd1 100644 --- a/versioned_docs/version-1.20/installation/with-docker-rootless.md +++ b/versioned_docs/version-1.20/installation/with-docker-rootless.md @@ -38,7 +38,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -58,7 +58,7 @@ 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 `:nightly-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-nightly-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly-rootless`) +For a stable release you could use `:latest-rootless`, `:1-rootless` or specify a certain release like `:@dockerVersion@-rootless`, but if you'd like to use the latest development version then `:nightly-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-nightly-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly-rootless`) ## Custom port @@ -71,7 +71,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -95,7 +95,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless + environment: + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 @@ -136,7 +136,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless environment: + - GITEA__database__DB_TYPE=postgres + - GITEA__database__HOST=db:5432 @@ -184,7 +184,7 @@ version: "2" + services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - - ./data:/var/lib/gitea @@ -211,7 +211,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always + user: 1001 volumes: @@ -283,7 +283,7 @@ docker-compose up -d - Rename folder (inside volume) gitea to custom - Edit app.ini if needed - Set START_SSH_SERVER = true -- Use image gitea/gitea:@version@-rootless +- Use image gitea/gitea:@dockerVersion@-rootless ## Managing Deployments With Environment Variables diff --git a/versioned_docs/version-1.20/installation/with-docker.md b/versioned_docs/version-1.20/installation/with-docker.md index 1abf7b11..05ebed30 100644 --- a/versioned_docs/version-1.20/installation/with-docker.md +++ b/versioned_docs/version-1.20/installation/with-docker.md @@ -25,7 +25,7 @@ image as a service. Since there is no database available, one can be initialized Create a directory like `gitea` and 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. If you don't give the volume correct permissions, the container may not start. -For a stable release you can use `:latest`, `:1` or specify a certain release like `:@version@`, but if you'd like to use the latest development version of Gitea then you could use the `:nightly` tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-nightly` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly`) +For a stable release you can use `:latest`, `:1` or specify a certain release like `:@dockerVersion@`, but if you'd like to use the latest development version of Gitea then you could use the `:nightly` tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-nightly` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly`) ```yaml version: "3" @@ -36,7 +36,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -68,7 +68,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -103,7 +103,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -154,7 +154,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -210,7 +210,7 @@ networks: + services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea restart: always networks: diff --git a/versioned_docs/version-1.21/administration/external-renderers.md b/versioned_docs/version-1.21/administration/external-renderers.md index b1a9cef6..4a81fe7e 100644 --- a/versioned_docs/version-1.21/administration/external-renderers.md +++ b/versioned_docs/version-1.21/administration/external-renderers.md @@ -25,7 +25,7 @@ In order to get file rendering through external binaries, their associated packa If you're using a Docker image, your `Dockerfile` should contain something along this lines: ```docker -FROM gitea/gitea:@version@ +FROM gitea/gitea:@dockerVersion@ [...] COPY custom/app.ini /data/gitea/conf/app.ini diff --git a/versioned_docs/version-1.21/installation/from-source.md b/versioned_docs/version-1.21/installation/from-source.md index 10bbadcb..9c4bf408 100644 --- a/versioned_docs/version-1.21/installation/from-source.md +++ b/versioned_docs/version-1.21/installation/from-source.md @@ -47,7 +47,7 @@ To work with tagged releases, the following commands can be used: ```bash git branch -a -git checkout v@version@ +git checkout @sourceBranch@ ``` To validate a Pull Request, first enable the new branch (`xyz` is the PR id; @@ -57,14 +57,14 @@ for example `2663` for [#2663](https://github.com/go-gitea/gitea/pull/2663)): git fetch origin pull/xyz/head:pr-xyz ``` -To build Gitea from source at a specific tagged release (like v@version@), list the +To build Gitea from source at a specific tagged release (like @sourceVersion@), list the available tags and check out the specific tag. List available tags with the following. ```bash git tag -l -git checkout v@version@ # or git checkout pr-xyz +git checkout @sourceVersion@ # or git checkout pr-xyz ``` ## Build diff --git a/versioned_docs/version-1.21/installation/with-docker-rootless.md b/versioned_docs/version-1.21/installation/with-docker-rootless.md index abfbbdbf..4c1e3e2c 100644 --- a/versioned_docs/version-1.21/installation/with-docker-rootless.md +++ b/versioned_docs/version-1.21/installation/with-docker-rootless.md @@ -38,7 +38,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -58,7 +58,7 @@ 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 `:nightly-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-nightly-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly-rootless`) +For a stable release you could use `:latest-rootless`, `:1-rootless` or specify a certain release like `:@dockerVersion@-rootless`, but if you'd like to use the latest development version then `:nightly-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-nightly-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly-rootless`) ## Custom port @@ -71,7 +71,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -95,7 +95,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless + environment: + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 @@ -136,7 +136,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless environment: + - GITEA__database__DB_TYPE=postgres + - GITEA__database__HOST=db:5432 @@ -184,7 +184,7 @@ version: "2" + services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - - ./data:/var/lib/gitea @@ -211,7 +211,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always + user: 1001 volumes: @@ -283,7 +283,7 @@ docker-compose up -d - Rename folder (inside volume) gitea to custom - Edit app.ini if needed - Set START_SSH_SERVER = true -- Use image gitea/gitea:@version@-rootless +- Use image gitea/gitea:@dockerVersion@-rootless ## Managing Deployments With Environment Variables diff --git a/versioned_docs/version-1.21/installation/with-docker.md b/versioned_docs/version-1.21/installation/with-docker.md index c1e04bc2..6cebda69 100644 --- a/versioned_docs/version-1.21/installation/with-docker.md +++ b/versioned_docs/version-1.21/installation/with-docker.md @@ -25,7 +25,7 @@ image as a service. Since there is no database available, one can be initialized Create a directory like `gitea` and 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. If you don't give the volume correct permissions, the container may not start. -For a stable release you can use `:latest`, `:1` or specify a certain release like `:@version@`, but if you'd like to use the latest development version of Gitea then you could use the `:nightly` tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-nightly` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly`) +For a stable release you can use `:latest`, `:1` or specify a certain release like `:@dockerVersion@`, but if you'd like to use the latest development version of Gitea then you could use the `:nightly` tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-nightly` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly`) ```yaml version: "3" @@ -36,7 +36,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -68,7 +68,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -103,7 +103,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -154,7 +154,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -210,7 +210,7 @@ networks: + services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea restart: always networks: diff --git a/versioned_docs/version-1.22/administration/external-renderers.md b/versioned_docs/version-1.22/administration/external-renderers.md index 55afaf8d..a56941ea 100644 --- a/versioned_docs/version-1.22/administration/external-renderers.md +++ b/versioned_docs/version-1.22/administration/external-renderers.md @@ -25,7 +25,7 @@ In order to get file rendering through external binaries, their associated packa If you're using a Docker image, your `Dockerfile` should contain something along this lines: ```docker -FROM gitea/gitea:@version@ +FROM gitea/gitea:@dockerVersion@ [...] COPY custom/app.ini /data/gitea/conf/app.ini diff --git a/versioned_docs/version-1.22/installation/from-source.md b/versioned_docs/version-1.22/installation/from-source.md index 1bccffa0..bb89cd2b 100644 --- a/versioned_docs/version-1.22/installation/from-source.md +++ b/versioned_docs/version-1.22/installation/from-source.md @@ -47,7 +47,7 @@ To work with tagged releases, the following commands can be used: ```bash git branch -a -git checkout v@version@ +git checkout @sourceBranch@ ``` To validate a Pull Request, first enable the new branch (`xyz` is the PR id; @@ -57,14 +57,14 @@ for example `2663` for [#2663](https://github.com/go-gitea/gitea/pull/2663)): git fetch origin pull/xyz/head:pr-xyz ``` -To build Gitea from source at a specific tagged release (like v@version@), list the +To build Gitea from source at a specific tagged release (like @sourceVersion@), list the available tags and check out the specific tag. List available tags with the following. ```bash git tag -l -git checkout v@version@ # or git checkout pr-xyz +git checkout @sourceVersion@ # or git checkout pr-xyz ``` ## Build diff --git a/versioned_docs/version-1.22/installation/with-docker-rootless.md b/versioned_docs/version-1.22/installation/with-docker-rootless.md index 94b89294..e1a45dd1 100644 --- a/versioned_docs/version-1.22/installation/with-docker-rootless.md +++ b/versioned_docs/version-1.22/installation/with-docker-rootless.md @@ -38,7 +38,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -58,7 +58,7 @@ 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 `:nightly-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-nightly-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly-rootless`) +For a stable release you could use `:latest-rootless`, `:1-rootless` or specify a certain release like `:@dockerVersion@-rootless`, but if you'd like to use the latest development version then `:nightly-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-nightly-rootless` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly-rootless`) ## Custom port @@ -71,7 +71,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - ./data:/var/lib/gitea @@ -95,7 +95,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless + environment: + - GITEA__database__DB_TYPE=mysql + - GITEA__database__HOST=db:3306 @@ -136,7 +136,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless environment: + - GITEA__database__DB_TYPE=postgres + - GITEA__database__HOST=db:5432 @@ -184,7 +184,7 @@ version: "2" + services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always volumes: - - ./data:/var/lib/gitea @@ -211,7 +211,7 @@ version: "2" services: server: - image: gitea/gitea:@version@-rootless + image: gitea/gitea:@dockerVersion@-rootless restart: always + user: 1001 volumes: @@ -283,7 +283,7 @@ docker-compose up -d - Rename folder (inside volume) gitea to custom - Edit app.ini if needed - Set START_SSH_SERVER = true -- Use image gitea/gitea:@version@-rootless +- Use image gitea/gitea:@dockerVersion@-rootless ## Managing Deployments With Environment Variables diff --git a/versioned_docs/version-1.22/installation/with-docker.md b/versioned_docs/version-1.22/installation/with-docker.md index 233402fc..440c9813 100644 --- a/versioned_docs/version-1.22/installation/with-docker.md +++ b/versioned_docs/version-1.22/installation/with-docker.md @@ -25,7 +25,7 @@ image as a service. Since there is no database available, one can be initialized Create a directory like `gitea` and 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. If you don't give the volume correct permissions, the container may not start. -For a stable release you can use `:latest`, `:1` or specify a certain release like `:@version@`, but if you'd like to use the latest development version of Gitea then you could use the `:nightly` tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-nightly` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly`) +For a stable release you can use `:latest`, `:1` or specify a certain release like `:@dockerVersion@`, but if you'd like to use the latest development version of Gitea then you could use the `:nightly` tag. If you'd like to run the latest commit from a release branch you can use the `:1.x-nightly` tag, where x is the minor version of Gitea. (e.g. `:1.16-nightly`) ```yaml version: "3" @@ -36,7 +36,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -68,7 +68,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -103,7 +103,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -154,7 +154,7 @@ networks: services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea environment: - USER_UID=1000 @@ -210,7 +210,7 @@ networks: + services: server: - image: gitea/gitea:@version@ + image: gitea/gitea:@dockerVersion@ container_name: gitea restart: always networks: