# python3-cyberfusion-systemd-support
Library for [systemd](https://systemd.io/).
# Install
## PyPI
Run the following command to install the package from PyPI:
pip3 install python3-cyberfusion-systemd-support
Next, ensure you are working on a system that ships systemd.
## Debian
Run the following commands to build a Debian package:
mk-build-deps -i -t 'apt -o Debug::pkgProblemResolver=yes --no-install-recommends -y'
dpkg-buildpackage -us -uc
# Configure
No configuration is supported.
# Usage
## Units
```python
from cyberfusion.SystemdSupport.units import Unit
unit = Unit(f"example.{Unit.SUFFIX_SERVICE}")
unit.disable()
unit.stop()
unit.enable()
unit.restart()
unit.reload()
print(unit.is_active)
print(unit.is_enabled)
```
## Tmp files
```python
from cyberfusion.SystemdSupport.tmp_files import TmpFileConfigurationLine, TmpFileConfigurationFile
tmp_file_configuration_line = str(TmpFileConfigurationLine(type_="d", path="/tmp/example", mode="0755", user="example", group="example"))
tmp_file_configuration_file = TmpFileConfigurationFile(path="/etc/tmpfiles.d/example.conf")
tmp_file_configuration_file.create()
```
Raw data
{
"_id": null,
"home_page": null,
"name": "python3-cyberfusion-systemd-support",
"maintainer": null,
"docs_url": null,
"requires_python": null,
"maintainer_email": null,
"keywords": null,
"author": null,
"author_email": "Cyberfusion <support@cyberfusion.io>",
"download_url": "https://files.pythonhosted.org/packages/97/00/eff8e0925c3c181e7e0840951c77047cf3cdb9dc81112bcaf52653b7c47f/python3_cyberfusion_systemd_support-1.1.1.3.tar.gz",
"platform": null,
"description": "# python3-cyberfusion-systemd-support\n\nLibrary for [systemd](https://systemd.io/).\n\n# Install\n\n## PyPI\n\nRun the following command to install the package from PyPI:\n\n pip3 install python3-cyberfusion-systemd-support\n\nNext, ensure you are working on a system that ships systemd.\n\n## Debian\n\nRun the following commands to build a Debian package:\n\n mk-build-deps -i -t 'apt -o Debug::pkgProblemResolver=yes --no-install-recommends -y'\n dpkg-buildpackage -us -uc\n\n# Configure\n\nNo configuration is supported.\n\n# Usage\n\n## Units\n\n```python\nfrom cyberfusion.SystemdSupport.units import Unit\n\nunit = Unit(f\"example.{Unit.SUFFIX_SERVICE}\")\n\nunit.disable()\nunit.stop()\nunit.enable()\nunit.restart()\nunit.reload()\n\nprint(unit.is_active)\nprint(unit.is_enabled)\n```\n\n## Tmp files\n\n```python\nfrom cyberfusion.SystemdSupport.tmp_files import TmpFileConfigurationLine, TmpFileConfigurationFile\n\ntmp_file_configuration_line = str(TmpFileConfigurationLine(type_=\"d\", path=\"/tmp/example\", mode=\"0755\", user=\"example\", group=\"example\"))\ntmp_file_configuration_file = TmpFileConfigurationFile(path=\"/etc/tmpfiles.d/example.conf\")\n\ntmp_file_configuration_file.create()\n```\n",
"bugtrack_url": null,
"license": null,
"summary": "Library for systemd.",
"version": "1.1.1.3",
"project_urls": {
"Source": "https://github.com/CyberfusionIO/python3-cyberfusion-systemd-support"
},
"split_keywords": [],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "fe1c2b3dc99745953ac788280e485e7726a26dee8c4d81e22fb2ea78e72acb42",
"md5": "22104c585116ff680e60f88d6c726aee",
"sha256": "737b911d40ae37df73ad7afc2557ce1063fc61480486028cf2a046189af9bc3f"
},
"downloads": -1,
"filename": "python3_cyberfusion_systemd_support-1.1.1.3-py3-none-any.whl",
"has_sig": false,
"md5_digest": "22104c585116ff680e60f88d6c726aee",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": null,
"size": 5140,
"upload_time": "2024-08-26T09:34:44",
"upload_time_iso_8601": "2024-08-26T09:34:44.672521Z",
"url": "https://files.pythonhosted.org/packages/fe/1c/2b3dc99745953ac788280e485e7726a26dee8c4d81e22fb2ea78e72acb42/python3_cyberfusion_systemd_support-1.1.1.3-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "9700eff8e0925c3c181e7e0840951c77047cf3cdb9dc81112bcaf52653b7c47f",
"md5": "ea29e27dc885595a8bce6e6b02055610",
"sha256": "bc02c04edbcc63bde12700ced80aebd47698929bf5660cefcf7ca10f567607ba"
},
"downloads": -1,
"filename": "python3_cyberfusion_systemd_support-1.1.1.3.tar.gz",
"has_sig": false,
"md5_digest": "ea29e27dc885595a8bce6e6b02055610",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 3685,
"upload_time": "2024-08-26T09:34:45",
"upload_time_iso_8601": "2024-08-26T09:34:45.832830Z",
"url": "https://files.pythonhosted.org/packages/97/00/eff8e0925c3c181e7e0840951c77047cf3cdb9dc81112bcaf52653b7c47f/python3_cyberfusion_systemd_support-1.1.1.3.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-08-26 09:34:45",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "CyberfusionIO",
"github_project": "python3-cyberfusion-systemd-support",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "python3-cyberfusion-systemd-support"
}