<feed xmlns='http://www.w3.org/2005/Atom'>
<title>vyos-cloud-init.git/cloudinit/util.py, branch sagitta-public-unmaintained</title>
<subtitle> (mirror of https://github.com/vyos/vyos-cloud-init.git)
</subtitle>
<id>https://git.amelek.net/vyos/vyos-cloud-init.git/atom?h=sagitta-public-unmaintained</id>
<link rel='self' href='https://git.amelek.net/vyos/vyos-cloud-init.git/atom?h=sagitta-public-unmaintained'/>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/'/>
<updated>2021-12-16T02:16:38+00:00</updated>
<entry>
<title>Adopt Black and isort (SC-700) (#1157)</title>
<updated>2021-12-16T02:16:38+00:00</updated>
<author>
<name>James Falcon</name>
<email>james.falcon@canonical.com</email>
</author>
<published>2021-12-16T02:16:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=bae9b11da9ed7dd0b16fe5adeaf4774b7cc628cf'/>
<id>urn:sha1:bae9b11da9ed7dd0b16fe5adeaf4774b7cc628cf</id>
<content type='text'>
Applied Black and isort, fixed any linting issues, updated tox.ini
and CI.
</content>
</entry>
<entry>
<title>find_devs_with_openbsd: ensure we return the last entry (#1149)</title>
<updated>2021-12-13T17:31:39+00:00</updated>
<author>
<name>Gonéri Le Bouder</name>
<email>goneri@lebouder.net</email>
</author>
<published>2021-12-13T17:31:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=f4692c5d96323dc635fca26b742199d4c41f88d3'/>
<id>urn:sha1:f4692c5d96323dc635fca26b742199d4c41f88d3</id>
<content type='text'>
`sysctl -n hw.disknames` returns a trailing `\n`. We need to clean
this up. In addition, the criteria matching system is a source of
problem because:

- we don't have a way to look up the label of the partition
- we've got situation where an ISO image can be exposed through a virtio
  block device.

So we just totally ignore the value of `criteria`. We end-up with a
slightly longer loop of mount-retry. But this way we're sure we don't
miss a configuration disk.

Tested on Kubvirt with the help of Brady Pratt @jbpratt.</content>
</entry>
<entry>
<title>find_devs/openbsd: accept ISO on disk (#1132)</title>
<updated>2021-12-09T22:46:27+00:00</updated>
<author>
<name>Gonéri Le Bouder</name>
<email>goneri@lebouder.net</email>
</author>
<published>2021-12-09T22:46:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=24739592217e5ba91e09e8c28b852d31a2c0cc77'/>
<id>urn:sha1:24739592217e5ba91e09e8c28b852d31a2c0cc77</id>
<content type='text'>
When the metadata is an ISO image and is exposed through a disk,
the device is called `/dev/sd?a` internally. For instance `/dev/sd1a`.

It can then be mounted with `mount_cd9660 /dev/sd1a /mnt`.

Metadata in the FAT32 format are exposed as `/dev/sd?i`.

With this change, we try to mount `/dev/sd?a` in addition to `/dev/sd?i`.

Closes: https://github.com/ContainerCraft/kmi/issues/12</content>
</entry>
<entry>
<title>Improve error log message when mount failed (#1140)</title>
<updated>2021-12-09T22:45:37+00:00</updated>
<author>
<name>Ksenija Stanojevic</name>
<email>KsenijaS@users.noreply.github.com</email>
</author>
<published>2021-12-09T22:45:37+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=b591e9dba6c85f3934bc309032c3e436b8dcb3ac'/>
<id>urn:sha1:b591e9dba6c85f3934bc309032c3e436b8dcb3ac</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Add miraclelinux support (#1128)</title>
<updated>2021-12-07T14:23:45+00:00</updated>
<author>
<name>Haruki TSURUMOTO</name>
<email>fortune.rocket42@gmail.com</email>
</author>
<published>2021-12-07T14:23:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=0ed00ad9cdebc2d4dabd8bd6d7c901584963def5'/>
<id>urn:sha1:0ed00ad9cdebc2d4dabd8bd6d7c901584963def5</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Add Strict Metaschema Validation (#1101)</title>
<updated>2021-12-06T22:27:12+00:00</updated>
<author>
<name>Brett Holman</name>
<email>bholman.devel@gmail.com</email>
</author>
<published>2021-12-06T22:27:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=bedac77e9348e7a54c0ec364fb61df90cd893972'/>
<id>urn:sha1:bedac77e9348e7a54c0ec364fb61df90cd893972</id>
<content type='text'>
Improve schema validation.

This adds strict validation of config module definitions at testing
time, with plumbing included for future runtime validation. This
eliminates a class of bugs resulting from schemas that have definitions
that are incorrect, but get interpreted by jsonschema as
"additionalProperties" that are therefore ignored.

- Add strict meta-schema for jsonschema unit test validation
- Separate schema from module metadata structure
- Improve type annotations for various functions and data types

Cleanup:
- Remove unused jsonschema "required" elements 
- Eliminate manual memoization in schema.py:get_schema(),
        reference module.__doc__ directly</content>
</entry>
<entry>
<title>testing: monkeypatch system_info call in unit tests (SC-533) (#1117)</title>
<updated>2021-11-22T22:56:41+00:00</updated>
<author>
<name>James Falcon</name>
<email>james.falcon@canonical.com</email>
</author>
<published>2021-11-22T22:56:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=31daf6670aeeba1d452c70bc0d4d04139652be36'/>
<id>urn:sha1:31daf6670aeeba1d452c70bc0d4d04139652be36</id>
<content type='text'>
testing: monkeypatch system_info call in unit tests

system_info can make calls that read or write from the filesystem, which
should require special mocking. It is also decorated with 'lru_cache',
which means test authors often don't realize they need to be mocking.
Also, we don't actually want the results from the user's local
machine, so monkeypatching it across all tests should be reasonable.

Additionally, moved some of 'system_info` into a helper function to
reduce the surface area of the monkeypatch, added tests for the new
function (and fixed a bug as a result), and removed related mocks that
should be no longer needed.</content>
</entry>
<entry>
<title>cc_ssh.py: fix private key group owner and permissions (#1070)</title>
<updated>2021-10-19T19:32:10+00:00</updated>
<author>
<name>Emanuele Giuseppe Esposito</name>
<email>eesposit@redhat.com</email>
</author>
<published>2021-10-19T19:32:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=ee296ced9c0a61b1484d850b807c601bcd670ec1'/>
<id>urn:sha1:ee296ced9c0a61b1484d850b807c601bcd670ec1</id>
<content type='text'>
When default host keys are created by sshd-keygen (/etc/ssh/ssh_host_*_key)
in RHEL/CentOS/Fedora, openssh it performs the following:

# create new keys
if ! $KEYGEN -q -t $KEYTYPE -f $KEY -C '' -N '' &gt;&amp;/dev/null; then
        exit 1
fi

# sanitize permissions
/usr/bin/chgrp ssh_keys $KEY
/usr/bin/chmod 640 $KEY
/usr/bin/chmod 644 $KEY.pub
Note that the group ssh_keys exists only in RHEL/CentOS/Fedora.

Now that we disable sshd-keygen to allow only cloud-init to create
them, we miss the "sanitize permissions" part, where we set the group
owner as ssh_keys and the private key mode to 640.

According to https://bugzilla.redhat.com/show_bug.cgi?id=2013644#c8, failing
to set group ownership and permissions like openssh does makes the RHEL openscap
tool generate an error.

Signed-off-by: Emanuele Giuseppe Esposito eesposit@redhat.com

RHBZ: 2013644</content>
</entry>
<entry>
<title>Allow comments in runcmd and report failed commands correctly (#1049)</title>
<updated>2021-10-07T20:08:13+00:00</updated>
<author>
<name>Brett Holman</name>
<email>bpholman5@gmail.com</email>
</author>
<published>2021-10-07T20:08:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=725a7f7f19eb39b472e1f24b447fc9a596bf1748'/>
<id>urn:sha1:725a7f7f19eb39b472e1f24b447fc9a596bf1748</id>
<content type='text'>
Allow comments in runcmd and report failed commands correctly

A `runcmd` script may fail to parse properly, but does not mark
`runcmd` as failed when that occurs. Additionally `shellify()` fails
to correctly parse scripts that contain a comment line.

Rectify both issues and add unit tests to verify correct behavior.

LP: #1853146</content>
</entry>
<entry>
<title>Improve ug_util.py (#1013)</title>
<updated>2021-09-13T19:41:45+00:00</updated>
<author>
<name>Shreenidhi Shedi</name>
<email>53473811+sshedi@users.noreply.github.com</email>
</author>
<published>2021-09-13T19:41:45+00:00</published>
<link rel='alternate' type='text/html' href='https://git.amelek.net/vyos/vyos-cloud-init.git/commit/?id=f3cc94949d9f153b4a5135f8b989ff11b36ab7ea'/>
<id>urn:sha1:f3cc94949d9f153b4a5135f8b989ff11b36ab7ea</id>
<content type='text'>
No functional changes.</content>
</entry>
</feed>
