A restrictive checkout umask can remove group and other execute bits.
Require the owner execute bit on source postinstall files and reject all
execute bits on data files. Native package tests still require exact modes.
Preserve source modes when staging Debian package builds and accept a
private source fixture. Build group-writable profiles under umasks 0022
and 0002, then check the extracted data, postscripts and directories.
Verify that staging and packaging leave source permissions unchanged,
including a world-writable data file. Reuse the payload checks for normal,
reduced and permission-regression builds.
Group-writable sources leave install and netboot assets writable by other users in the Debian package. Remove group and other write permission from those two staged trees. Preserve executable bits and leave source files and the rest of the payload unchanged.
RPM preparation removes group write permission from source files. Assert the packaged data and postinstall modes instead of comparing them with checkout permissions. Report modes in octal and keep the content, alias and customization checks.
Use relative aliases for identical shipped profiles. Keep their public names,
resolved contents and executable modes. Custom copies remain independent.
Share line normalization and directive filtering across the legacy text
reader, its include reader and the record reader. Keep leading whitespace
in legacy includes and leave each parser expansion policy unchanged.
Signed-off-by: Vinícius Ferrão <2031761+viniciusferrao@users.noreply.github.com>
A paused journal view restores a row number after refreshing its history.
When older records leave the window, that row selects a different entry.
Match the selected entry by its journal cursor and retain its wrapped-line
position. If the entry has left the window, select the oldest retained row
without resuming follow mode.
Each failure of the definition write runs over a published image, an
image without a checksum, a new image, or a statelite image. The
previous root image, checksum, metainfo, kernel and ramdisk must be
back, and the files of a new image must be gone. When a row does not go
back, also after a changed rootimgdir, the new files must stay. The
publication lock must be held during the writes and released after
them. A row written before its call failed must keep the new files.
imgimport publishes the root image, kernel and ramdisk before it writes
the image definition. When the database refused or failed a write, the
new boot files stayed with the previous definition.
The import now holds the publication lock of the image from before it
places the files until the outcome of the definition is known. When the
definition is not written and its rows went back, it puts back the
previous files, with the checksum and metainfo of the root image. It
removes the files that had no previous version. While a row did not go
back, the new files stay, as that row can refer to them.
A caller takes the publication lock, then publishes or removes a root
image under it. Another host must not get the lock meanwhile, the lock
must stay held until the caller releases it, and a lock that another
host left must be reported.
The image lock is per host, so another host can publish a root image
between two steps of a caller. lock_rootimg_publication and
unlock_rootimg_publication let a caller hold the publication lock across
such steps. publish_rootimg takes the held lock, and the new
unpublish_rootimg removes an archive with its checksum and metainfo
under it.
The database refuses the linuximage, kit or kitrepo write, the
linuximage commit dies, or a kitrepo section of an unexpected shape
dies, after earlier rows are written. The osimage row, also a disabled
one, one with a quote in a value, or one whose disable column was NULL,
and a previous linuximage row with its rootimgdir must be back, and a
new linuximage row must be gone. A kit that another import uses and a
row that another writer changed or filled must stay. A restore that
fails, or a row that cannot be read back, must be reported.
set_config writes the osimage, linuximage and kit rows one by one. When
a later write failed, the rows written before it stayed. An image could
keep a new linuximage row, with a new rootimgdir, beside its previous
osimage row.
set_config now keeps the osimage and linuximage rows that it replaces,
disabled rows included. When a write or its commit fails, or bundle
data of an unexpected shape dies between the writes, it checks each row
that it tried to write. It writes changed rows back and removes the rows
that it added, with NULL values as NULL. It skips a row that another
writer changed or filled, so that change stays. set_config reports the
rows that did not go back, also to a caller that asks for their number.
Kit rows stay as written, because other images can use them.
A database trigger refuses the write to the osimage or the linuximage
table after the import opened it. The write also dies, gets no reply,
dies after its row is written, or its commit dies. The import must fail
and name the table, unless the row is written. It must leave no
transaction open and keep the pending write of another request.
imgimport ignored the result of each write of the image definition. A
write that the database refused left the previous rows, and the import
still reported success. The import now fails and names the table when a
write returns an error, returns no reply or dies, or its commit fails.
A row that holds the new values despite the failure counts as written,
with a warning.
After a failed write the import commits, as before. A rollback would
drop the pending writes of other requests, which share the transaction
of the table in the database worker.
Run the complete postscripts with controlled credential replies and native
SSH key generation. Check successful and empty replies, server errors,
retry limits, flow-control differences and password logging.
Move the common credential response filters into xcatlib.sh. Keep the
requests, key retry filters and caller-specific retry, flow-control and
listener handling in place.