containers icon indicating copy to clipboard operation
containers copied to clipboard

[bitnami/gitea] Gitea docker container boot loop

Open cameronmccord2 opened this issue 6 months ago • 2 comments

Name and Version

bitnami/gitea:1.22.1

What architecture are you using?

arm64

What steps will reproduce the bug?

I'm deploying gitea using Docker Swarm on Mac. Docker version 25.0.4-rd, build c4cd0a9.

What is the expected behavior?

The readme makes it seem like you don't need to specify a /opt/bitnami/gitea/custom/conf/app.ini volume and if you do that having that volume in read-only mode is valid. The container should boot.

What do you see instead?

The container is in a boot loop and exits in under a second. The following logs loop endlessly every few seconds when no app.ini volume is specified. The last line is what is important.

Welcome to the Bitnami gitea container
Subscribe to project updates by watching https://github.com/bitnami/containers
Submit issues and feature requests at https://github.com/bitnami/containers/issues
Upgrade to Tanzu Application Catalog for production environments to access custom-configured and pre-packaged software components. Gain enhanced features, including Software Bill of Materials (SBOM), CVE scan result reports, and VEX documents. To learn more, visit https://bitnami.com/enterprise
Configuring libnss_wrapper
** Starting Gitea setup **
Validating settings in GITEA_* environment variables...
Waiting for database connection...
Initializing Gitea...
Restoring persisted Gitea installation
Setting APP_NAME to 'Gitea - REDACTED' in Gitea configuration
open /opt/bitnami/gitea/custom/conf/app.ini: no such file or directory

If an app.ini volume is specified in read-only mode (for example - ./entrypoints/gitea_app.ini:/bitnami/gitea/custom/conf/app.ini:ro) the last line in the looping logs changes to the below and the container still fails to boot.

open /opt/bitnami/gitea/custom/conf/app.ini: read-only file system

The only way to get the container to boot is to add a blank ini file where the volume isn't read-only. I use env vars instead of the ini file to configure the container.

After the container finishes booting the blank app.ini file I include gets filled in with the full config (which is why read-only exits the container)

Additional information

No response

cameronmccord2 avatar Aug 02 '24 18:08 cameronmccord2