simple cgit docker image with authentication
330
simple cgit docker with authentication
docker run \
--detach \
--publish "{{port_ui}}:80/tcp" \
--publish "{{port}}:22" \
--name "{{docker_name}}" \
--restart unless-stopped \
--volume "{{conf_dir}}:/config" \
--volume "{{repos_dir}}:/cgit" \
--env "SSH_KEY={{ssh-public-key}}" \
--env "CGIT_TITLE={{title}}" \
--env "CGIT_DESC={{description}}" \
--env "DEFAULT_USER={{username}}" \
--env "DEFAULT_PASS={{password}}" \
"mikescher/cgit_auth"
# Then navigate to http://{{domain}}:{{port}} for the cgit website
$> sh "git@{{domain}}" -p "{{port}}"
$> cd /cgit
$> git init "{{repo_name}}" --bare
$> /opt/cgit-simple-authentication repo add "{{repo_name}}" "{{username}}"
$> git remote add origin "ssh://git@{{domain}}:{{port}}"
$> git push
Content type
Image
Digest
sha256:fc47b74db…
Size
232.1 MB
Last updated
almost 2 years ago
docker pull mikescher/cgit_auth