Skip to main content

systemd configuration file access

Project description

Classes for Accessing the systemd Configuration Files

A collection of classes for accessing the systemd configuration files.

Only tested with Python 3.6 on Debian 9.5.

Installation

pip install sysdfiles

Documentation

Usage

from sysdfiles import NetworkFile

network = NetworkFile('/etc/systemd/network/lan.network')
print(network.match_name)
print(network.match_mac_address)
network.network_dhcp = ['8.8.8.8', '8.8.4.4']
network.network_dhcp_server = True
network.dhcp_server_emit_dns = True
network.dhcp_server_dns = '192.168.0.1'
network.route_metric = 10
network.save()

Copyright and License

Copyright © 2018 Shawn Baker using the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sysdfiles-0.2.0.tar.gz (15.0 kB view hashes)

Uploaded Source

Built Distribution

sysdfiles-0.2.0-py3-none-any.whl (21.6 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page