https://github.com/fraoustin/gitweb
container docker for run a git server with ihm
https://github.com/fraoustin/gitweb
active docker-image
Last synced: 7 months ago
JSON representation
container docker for run a git server with ihm
- Host: GitHub
- URL: https://github.com/fraoustin/gitweb
- Owner: fraoustin
- Created: 2016-11-30T09:58:58.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2022-11-17T18:20:34.000Z (over 3 years ago)
- Last Synced: 2023-10-20T19:53:38.768Z (over 2 years ago)
- Topics: active, docker-image
- Language: CSS
- Homepage:
- Size: 332 KB
- Stars: 14
- Watchers: 2
- Forks: 12
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Docker Image for gitweb
generate a nginx server with git server and gitweb for ihm on http://127.0.0.1/
load when start image load file in
- /usr/share/gitweb/docker-entrypoint.pre
- /usr/share/gitweb/docker-entrypoint.post
## Parameter
- SET_CONTAINER_TIMEZONE (false or true) manage time of container
- CONTAINER_TIMEZONE timezone of container
- GITPROJECT
- GITUSER (default gituser)
- GITPASSWORD (default gitpassword)
- IHM (default "")
## Volume
- /var/lib/git
## Port
- 80 for gitweb
## Command
- addrepos: add repository
- addauth : add user for git
- rmrepos : remove repository
- rmauth : remove user
## Usage direct
run image fraoustin/gitweb
docker run -d -e "CONTAINER_TIMEZONE=Europe/Paris" -e "GITPROJECT=test" -v :/var/lib/git --name test -p 80:80 fraoustin/gitweb
user default is gituser and password default is gitpassword
you use http://localhost/ for access gitweb
you can clone project
git clone http://gituser:gitpassword@localhost/test.git
You can change user and password by variable environment
## Usage by Dockerfile
Sample of Dockerfile
FROM fraoustin/gitweb
COPY ./00_init.sh /usr/share/gitweb/docker-entrypoint.pre/00_init.sh
RUN chmod +x -R /usr/share/gitweb/docker-entrypoint.pre
File 00_init.sh
#!/bin/bash
REPOS='/var/lib/git/test.git'
if [ ! -d $REPOS ]; then
addrepos test
cd $REPOS
chmod -R g+ws .
chgrp -R nginx .
fi
addauth $GITUSER $GITPASSWORD
build image mygit
docker build -t mygit .
run image mygit
docker run -d -e "CONTAINER_TIMEZONE=Europe/Paris" -e "GITUSER=gituser" -e "GITPASSWORD=gitpassword" -v :/var/lib/git --name test -p 80:80 mygit
## IHM material design
If you want use a new design for ihm, you can use IHM variable
- IHM = mdl
docker run -d -e "CONTAINER_TIMEZONE=Europe/Paris" -e "IHM=mdl" -e "GITPROJECT=test" -v :/var/lib/git --name test -p 80:80 fraoustin/gitweb