geologs


Namegeologs JSON
Version 0.0.8 PyPI version JSON
download
home_pageNone
SummarySlack bot to watch log files and run basic server commands
upload_time2024-09-13 06:36:58
maintainerNone
docs_urlNone
authorNone
requires_pythonNone
licenseMIT
keywords slack log bot
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            ![https://pypi.org/project/geologs](https://img.shields.io/pypi/v/geologs.svg) ![https://pypi.org/project/geologs](https://img.shields.io/pypi/wheel/geologs) ![](https://img.shields.io/badge/certified-cool_project-blue)


# Geologs - Slack Bot

- Runs basic system commands and pipes the output to slack
- Watches specified log files and parses new lines before posting them in a specific slack channel

Pull requests welcome.


## Installation
``
pip install geologs
``

A new Slack application needs to be made for each server. Use `manifest.json` as a template for the required permissions.

It is expected the API keys are given as environmental variables as `SLACK_BOT_TOKEN` and `SLACK_APP_TOKEN`.

```
python -m geologs --conf=config.toml
```


## Configuration
Define the log files to listen to, delay in seconds between checking the file and an optional parser. 

Available parsers can be found in `geologs/parsers.py` to format the logs in a pretty format.

```toml
[testing]
channel = "#file-logs"
logfile = "test.log"
delay = 10
parser = "basic"

[test2]
channel = "#ssh-logins"
logcmd = "journalctl -u sshd --no-pager -f"
delay = 5
parser = "ssh"
```


            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "geologs",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": "slack, log, bot",
    "author": null,
    "author_email": "gyndlf <james@zingel.co.nz>",
    "download_url": "https://files.pythonhosted.org/packages/56/aa/7481c2dcc87c7b7e48d3de15dfda37fa243158e5e8d99b6d7f3350a602a8/geologs-0.0.8.tar.gz",
    "platform": null,
    "description": "![https://pypi.org/project/geologs](https://img.shields.io/pypi/v/geologs.svg) ![https://pypi.org/project/geologs](https://img.shields.io/pypi/wheel/geologs) ![](https://img.shields.io/badge/certified-cool_project-blue)\n\n\n# Geologs - Slack Bot\n\n- Runs basic system commands and pipes the output to slack\n- Watches specified log files and parses new lines before posting them in a specific slack channel\n\nPull requests welcome.\n\n\n## Installation\n``\npip install geologs\n``\n\nA new Slack application needs to be made for each server. Use `manifest.json` as a template for the required permissions.\n\nIt is expected the API keys are given as environmental variables as `SLACK_BOT_TOKEN` and `SLACK_APP_TOKEN`.\n\n```\npython -m geologs --conf=config.toml\n```\n\n\n## Configuration\nDefine the log files to listen to, delay in seconds between checking the file and an optional parser. \n\nAvailable parsers can be found in `geologs/parsers.py` to format the logs in a pretty format.\n\n```toml\n[testing]\nchannel = \"#file-logs\"\nlogfile = \"test.log\"\ndelay = 10\nparser = \"basic\"\n\n[test2]\nchannel = \"#ssh-logins\"\nlogcmd = \"journalctl -u sshd --no-pager -f\"\ndelay = 5\nparser = \"ssh\"\n```\n\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Slack bot to watch log files and run basic server commands",
    "version": "0.0.8",
    "project_urls": {
        "repository": "https://github.com/gyndlf/geologs"
    },
    "split_keywords": [
        "slack",
        " log",
        " bot"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7b268434c7f53e14a28a76ef933de1e071a240ee9dde0af59254cc2aac93b9f5",
                "md5": "5ebdae90be991581c057d5457d9d8e0a",
                "sha256": "7b6d6b8498bf5c37666108c710b5635eaf87610c880804ab7537531e46904887"
            },
            "downloads": -1,
            "filename": "geologs-0.0.8-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "5ebdae90be991581c057d5457d9d8e0a",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 10062,
            "upload_time": "2024-09-13T06:36:56",
            "upload_time_iso_8601": "2024-09-13T06:36:56.217343Z",
            "url": "https://files.pythonhosted.org/packages/7b/26/8434c7f53e14a28a76ef933de1e071a240ee9dde0af59254cc2aac93b9f5/geologs-0.0.8-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "56aa7481c2dcc87c7b7e48d3de15dfda37fa243158e5e8d99b6d7f3350a602a8",
                "md5": "e481776071a48bce319e4b7102ff120b",
                "sha256": "91897d9275d3bd0e2fcb786370ed3027fc27c62ce9db1d89fbd73348ee40d7c8"
            },
            "downloads": -1,
            "filename": "geologs-0.0.8.tar.gz",
            "has_sig": false,
            "md5_digest": "e481776071a48bce319e4b7102ff120b",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 8625,
            "upload_time": "2024-09-13T06:36:58",
            "upload_time_iso_8601": "2024-09-13T06:36:58.240697Z",
            "url": "https://files.pythonhosted.org/packages/56/aa/7481c2dcc87c7b7e48d3de15dfda37fa243158e5e8d99b6d7f3350a602a8/geologs-0.0.8.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-09-13 06:36:58",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "gyndlf",
    "github_project": "geologs",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "geologs"
}
        
Elapsed time: 1.25661s