Public | Automated Build

Last pushed: 5 months ago
Short Description
Short description is empty for this repo.
Full Description

Gogs (Go Git Service) Docker Image

Latest version: 0.6.1 (fabric8/gogs:0.6.1)

This image runs Gogs with SSH & web access.

To configure Gogs, you can either mount a config file at /opt/gogs/custom/conf/app.ini
or use environment variables to configure all options. Specifying a config file
will prevent environment variables from taking effect: options are not merged.

All options in the config file
are configurable via environment variables using a special format for the name:

GOGS_SECTION_NAME__KEY_NAME

All environment variables prefixed with GOGS_ will be used to create the
/opt/gogs/custom/conf/app.ini file. The section name is optional, but the
key name is required. Notice the double underscore between SECTION_NAME &
KEY_NAME. For example, to override the user to run Gogs as
(RUN_USER) you can specify:

GOGS_RUN_USER=git

Or to override the database type (DB_TYPE key in [database] section) you can
specify:

GOGS_DATABASE__DB_TYPE=mysql

If a section contains a . (invalid env var for bash) then replace . with an _,
e.g. use GOGS_OAUTH_GOOGLE__ENABLED for the oauth.google section ENABLED key.

Reference config links:

Creating an initial admin user

By default, Gogs comes without a default admin user. This is great for security, but not great
when you're trying to integrate automated setups. This Docker image allows you to create a default
admin user by specifying some environment variables:

  • ADMIN_USER_CREATE: Should an admin user be created (default: true)
  • ADMIN_USER_NAME: Login for admin user (default: gogsadmin)
  • ADMIN_USER_PASSWORD: Password for admin user (default: admin123)
  • ADMIN_USER_EMAIL: Email address for admin user (default: gogs@fabric8.local)
Docker Pull Command
Owner
fabric8
Source Repository