Sign inSign up

felicio/git

By felicio

•Updated about 10 years ago

Git Service Under Various Protocols

Image
0

668

felicio/git repository overview

⁠Git Service Under Various Protocols

using Docker technology

Build Status

This project demonstrates containerization practices on a subject of version control. Each of inspected Dockerfiles focuses on configuration of a runtime environment for bare repositories' distribution via specified data transfer protocol.

Currently supported solutions are:

  • Git protocol
  • SSH protocol
  • HTTP protocol
  • HTTPS protocol

When built and run user is left with a container (an application) that serves user's provided Git repositories either to read-only public access or read-write access for contributors.

Project's diagram

⁠Build, Run

⁠Docker Engine
⁠Git Protocol

To simply share your work with others on trusted network run the following command.

docker build -t IMAGE PATH/git
docker run -dP -v PATH/Resources/srv:/srv/git/public --name CONTAINER IMAGE
⁠SSH Protocol

To let others contribute to your work add their public keys to a single file you'll later mount to the container.

docker build -t IMAGE -f PATH/ssh
docker run -dP -v PATH/Resources/authorized_keys:/home/git/.ssh/authorized_keys -v PATH/Resources/srv:/srv/git/private --name CONTAINER IMAGE
⁠Docker Compose
docker-compose up -d

⁠Clone

from a running container

git clone git://HOST:PORT/PATH
git clone ssh://git@HOST:PORT/PATH

⁠Clean Up

# Docker Engine
docker stop CONTAINER
docker rm -v CONTAINER
docker rmi IMAGE

# Docker Compose
docker-compose down -v --rmi all

Tag summary

Content type

Image

Digest

sha256:fd19f8927…

Size

92.9 MB

Last updated

about 10 years ago

docker pull felicio/git