HUB
Sign inSign up

corfr/git-autoupdate

By corfr

•Updated about 10 years ago

Container exposing a git repository and auto-updating it

Image
1

1M+

corfr/git-autoupdate repository overview

⁠Git auto-updating container

Image: corfr/git-autoupdate⁠

This image:

  • takes a GIT_URL, that it clones and expose as a volume (/git)
  • polls from the git remote periodically

Arguments:

  • GIT_URL: provided as this to git clone
  • POLLING_FREQ: polling frequency as given to cron, something like "*/5 * * * *", default to 5 minutes
  • SSH_KEY: can be used to provide an SSH key to authenticate against remote repository
  • VOLUME_PATH: if you're not happy with the default volume /git

Warning:

  • SSH_KEY expect as base64'd string
  • In case URL is ssh (ssh:// or git@), the image will automatically accept the remote key.

For instance you can deploy this as a systemd unit to serve an always up-to-date repository to other services.

Sample usages:

  • HTTP repository:
docker run \
            --rm \
            --name legato-docs
            -e GIT_URL=https://github.com/legatoproject/legato-docs.git \
            corfr/git-autoupdate
  • SSH repository:
docker run \
            --rm \
            --name legato-docs
            -e [email protected]:legatoproject/legato-docs.git \
            -e SSH_KEY="$(cat ~/.ssh/id_rsa | base64)" \
            corfr/git-autoupdate
  • Expose repository as another name:
docker run \
            --rm \
            --name legato-docs
            -e GIT_URL=https://github.com/legatoproject/legato-docs.git \
            -e VOLUME_PATH=/legato-docs \
            -v /legato-docs \
            corfr/git-autoupdate

Tag summary

Content type

Image

Digest

sha256:a57c18251…

Size

98.4 MB

Last updated

about 10 years ago

docker pull corfr/git-autoupdate