Merge ~t0rrant/cloud-init:1819966-sysconfig-options into cloud-init:master
Proposed by
Manuel Torrinha
Status: | Work in progress |
---|---|
Proposed branch: | ~t0rrant/cloud-init:1819966-sysconfig-options |
Merge into: | cloud-init:master |
Diff against target: |
145 lines (+139/-0) 1 file modified
cloudinit/config/cc_sysconfig.py (+139/-0) |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
cloud-init Commiters | Pending | ||
Review via email: mp+371948@code.launchpad.net |
Commit message
Added support for arbitrary options in sysconfig
These options should be added within the `sysconfig` key, as such:
```
network:
version: 2
sysconfig:
NTPSERVERARGS: "minpoll 3 maxpoll 4"
RES_OPTIONS: "rotate"
```
LP: #1819966
Signed-off-by: Manuel Torrinha <email address hidden>
Description of the change
Added a new handle (handle_sysconfig) to deal with the new key.
Using the options passed in the cloud-init config file a /etc/sysconfig/
To post a comment you must log in.
I do not feel comfortable with having a dummy handler for this, I guess
the purpose of the `network` key is exclusive for network interfaces and
network interface interaction. Having a handle_ function is perhaps not
the best choice.
For now this does what is intended, will eventually discuss this with the
cloud-init team and maybe this will be done in some other way.
On a final note, when running tox tests I get several errors/warnings, however:
```
...
Your code has been rated at 10.00/10 (previous run: 10.00/10, +0.00)
```