{"id":19651401,"url":"https://github.com/sourceboat/docker-compose-githooks","last_synced_at":"2025-07-11T00:34:00.283Z","repository":{"id":46294611,"uuid":"198229485","full_name":"sourceboat/docker-compose-githooks","owner":"sourceboat","description":" Easily manage and version control Git Hooks in a Docker Compose setup.","archived":false,"fork":false,"pushed_at":"2024-10-02T03:08:36.000Z","size":30,"stargazers_count":12,"open_issues_count":1,"forks_count":1,"subscribers_count":4,"default_branch":"develop","last_synced_at":"2025-04-28T16:49:34.753Z","etag":null,"topics":["docker","docker-compose","git","git-hooks","hacktoberfest"],"latest_commit_sha":null,"homepage":"","language":"Dockerfile","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sourceboat.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2019-07-22T13:32:05.000Z","updated_at":"2024-02-27T16:58:32.000Z","dependencies_parsed_at":"2025-04-28T16:51:15.887Z","dependency_job_id":null,"html_url":"https://github.com/sourceboat/docker-compose-githooks","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/sourceboat/docker-compose-githooks","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sourceboat%2Fdocker-compose-githooks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sourceboat%2Fdocker-compose-githooks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sourceboat%2Fdocker-compose-githooks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sourceboat%2Fdocker-compose-githooks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sourceboat","download_url":"https://codeload.github.com/sourceboat/docker-compose-githooks/tar.gz/refs/heads/develop","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sourceboat%2Fdocker-compose-githooks/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264697567,"owners_count":23650955,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","docker-compose","git","git-hooks","hacktoberfest"],"created_at":"2024-11-11T15:06:26.600Z","updated_at":"2025-07-11T00:33:59.993Z","avatar_url":"https://github.com/sourceboat.png","language":"Dockerfile","readme":"# docker-compose-githooks\n\n[![Docker Build Status](https://img.shields.io/docker/cloud/build/sourceboat/docker-compose-githooks.svg?style=flat-square)](https://hub.docker.com/r/sourceboat/docker-compose-githooks/builds/)\n[![Release](https://img.shields.io/github/release/sourceboat/docker-compose-githooks.svg?style=flat-square)](https://github.com/sourceboat/docker-compose-githooks/releases)\n[![Docker Pulls](https://img.shields.io/docker/pulls/sourceboat/docker-compose-githooks.svg?style=flat-square)](https://hub.docker.com/r/sourceboat/docker-compose-githooks/)\n[![Image Size](https://img.shields.io/docker/image-size/sourceboat/docker-compose-githooks?style=flat-square)](https://microbadger.com/images/sourceboat/docker-compose-githooks)\n[![MicroBadger Layers](https://img.shields.io/microbadger/layers/sourceboat/docker-compose-githooks.svg?style=flat-square)](https://microbadger.com/images/sourceboat/docker-compose-githooks)\n\nEasily manage and version control [Git Hooks](https://git-scm.com/book/de/v1/Git-individuell-einrichten-Git-Hooks)\nin a [Docker Compose](https://docs.docker.com/compose/) setup.\n\n## Usage\n\nAdd a new service to your  `.docker-compose.yml` file:\n\n```yml\nversion: '3.7'\nservices:\n  \n  // ...\n  \n  githooks:\n    image: sourceboat/docker-compose-githooks:latest\n    volumes:\n      - ./.git:/tmp/.git\n      - ./.githooks:/tmp/.githooks\n```\n\nNow you can manage and version control your Git Hooks in the `.githooks` directory of your repository.\nEverytime you run `docker-compose up` the `githooks` service will create symlinks in `.git/hooks` to all files found in the `.githooks` directory.\n\nFor example you can create a `.githooks/pre-commit` file to run your linters inside your running containers:\n\n```sh\n#!/bin/sh\necho 'running pre-commit hook...'\ndocker-compose exec -T app yarn lint\n```\n\n## Changelog\n\nCheck [releases](https://github.com/sourceboat/docker-compose-githooks/releases) for all notable changes.\n\n## Credits\n\n- This project is based on [an article by Aurélien Hervé](https://hackernoon.com/using-git-hooks-in-a-dockerized-environment-55372c40815f).\n- [Phil-Bastian Berndt](https://github.com/pehbehbeh)\n- [All Contributors](https://github.com/sourceboat/docker-compose-githooks/graphs/contributors)\n\n## License\n\nThe MIT License (MIT). Please see [License File](LICENSE.md) for more information.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsourceboat%2Fdocker-compose-githooks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsourceboat%2Fdocker-compose-githooks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsourceboat%2Fdocker-compose-githooks/lists"}