Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/adfinis/gitlab-docsbot
The Docs Bot - A simple service which receives HTTP build triggers from GitLab and unpacks built artifacts inside a configured directory.
https://github.com/adfinis/gitlab-docsbot
automation bot documentation gitlab gitlab-ci webhook
Last synced: 24 days ago
JSON representation
The Docs Bot - A simple service which receives HTTP build triggers from GitLab and unpacks built artifacts inside a configured directory.
- Host: GitHub
- URL: https://github.com/adfinis/gitlab-docsbot
- Owner: adfinis
- License: gpl-3.0
- Created: 2017-05-17T08:43:39.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-01-03T15:19:21.000Z (about 6 years ago)
- Last Synced: 2024-11-08T19:46:47.232Z (3 months ago)
- Topics: automation, bot, documentation, gitlab, gitlab-ci, webhook
- Language: Python
- Homepage:
- Size: 32.2 KB
- Stars: 1
- Watchers: 17
- Forks: 1
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# GitLab CI Docs Bot
[![Travis](https://img.shields.io/travis/adfinis-sygroup/gitlab-docsbot.svg?style=flat-square)](https://travis-ci.org/adfinis-sygroup/gitlab-docsbot)
[![License](https://img.shields.io/github/license/adfinis-sygroup/gitlab-docsbot.svg?style=flat-square)](LICENSE)This script starts a simple web server which accepts requests from GitLab
webhooks and downloads artifacts from the latest build to a defined directory.## Installation
```
# apt-get install python-setuptools python-pip python-yaml
# python setup.py install
# systemctl daemon-reload
# systemctl enable gitlab-autodocs.service
# systemctl start gitlab-autodocs.service
```## Configuration
### Initial
Add a new user in GitLab called `docs-bot` and get his API-Key. Then edit
`/etc/gitlab-autodocs.yaml` and set your GitLab URL and the API key.### Add new repos to sync
You need to create a `.docs-bot.yml` in your repository, example:
```
docs:
extract_to: /var/www/docs/autodocs-ci-test
download_delay: 10
stages:
- docs
````docs` needs to be the root entry of `.docs-bot.yml`
- `extract_to` directory to put artifacts
- `download_delay` since GitLab triggers before uploading artifacts, you can
configure a delay before fetching them
- `stages` if defined, only sync specified build stages configured in
`.gitlab-ci.yml`In GitLab, you need to grant `docs-bot` access to your repo and add a new
webhook which triggers on build events, pointing to your docsync URL.## Contributions
Contributions are more than welcome! Please feel free to open new issues or
pull requests.## License
GNU GENERAL PUBLIC LICENSE Version 3See the [LICENSE](LICENSE) file.