Age | Commit message (Collapse) | Author |
|
Vopying->Copying
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
If SWUPD_BUNDLES is empty no mega-image will be built and there's
no need to try and copy the os-core bundle contents from there,
instead the original image rootfs should be used as the source of
the copy.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
If the user hasn't defined any bundles a mega-image won't be
created and there's no need to recopy the mega image rootfs.
The original rootfs can be used in this case.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
This was a copy-and-paste of the check_output() method of the subprocess
module in order to support Python versions prior to 2.7 -- we should just
use the method from subprocess directly.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
Rather than trying to determine the manifest link name by removing the value
of the DATETIME variable from the image name duplicate the logic from
rootfs-postcommands.bbclass in OE-Core to derive the manifest name in the
same way.
This prevents issues when the IMAGE_NAME (and thus manifest name) differ
significantly from the IMAGE_NAME's used in OE-Core.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
This reverts commit ba2aeec203b09d96c6e81c85cdd57054bc670c93.
Manifest files are not currently writting with IMAGE_NAME_SUFFIX
|
|
Use manifest files written to DEPLOY_DIR_IMAGE, rather than
SWUPDMANIFESTDIR, during create_rootfs as the latter are (currently)
only written for package based bundles.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
The image name suffix is modifiable via the IMAGE_NAME_SUFFIX
variable, therefore when constructing image filenames we should
use the same variable.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
Use tempfile.mkstemp() from the standard library, rather than our
own logic, to create a unique filename in workdir to use as the
copyfile for the tar operation.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
The copyxattrtree() method will copy the entire contents of the src
directory to dst preserving extended attributes on files.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
Consistently use docstrings for documenting methods in lib/swupd/*
and ensure every method is documented.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
The manifest files are used for various things so we must be sure
they are available, even if the swupd inputs were staged from a
shared state.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
When creating a composed rootfs for swupdimage images we also write
an updated manifest of the composed image's content. To better match
behaviour of other manifests in DEPLOY_DIR_IMAGE also create a
symlink to the latest manifest.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
When swupdimage rootfs are constructed they rely on reading the
contents of the rootfs.manifest files for each bundle they contain
in order to determine the image's contents. However it's possible,
especially with the addition of a sstate accelerated
do_stage_swupd_inputs, that the manifests will have been generated
in a different bitbake invocation and therefore that the DATETIME
in the IMAGE_NAME will be different.
This change accounts for that eventuality by falling back to the
manifest's symlink when the composed manifest filename (including
DATETIME) doesn't exist.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
When writing the rootfs.manifest for package manager staged bundles
also create a symlink to the manifest to better match the pattern
of manifests created for images.
We'll use this in a future commit to make the composed rootfs
construction in swupdimage based images more robust.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
SWUPD_FILE_BLACKLIST allows a user to list files, with a path in
the target rootfs, that they do not wish to be copied into the
swupd state directory for processing.
This mechanism can be used to prevent files being processed by
swupd which should not be tracked in a manifest file and thus not
processed by swupd-client.
The primary use for this is to exclude files in /etc which are
runtime modified (/etc/mtab) or generated at boot (/etc/machine-id)
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
swupd-client doesn't support bundles being removed from the server,
if a bundle receipt still exists on the client but the manifest
disapears from the server the client doesn't know how to handle it.
Prevent a workaround for this by adding a SWUPD_EMPTY_BUNDLES
variable which can be used to continue to provide a manifest entry
for a bundle which is otherwise empty. With this workaround the
client can update to the empty bundle, removing files that it used
to provide (unless they are now provided by an alternative bundle).
Note: this was implemented as a separate variable, rather than
allowing SWUPD_BUNDLES to be defined without a corresponding
BUNDLE_CONTENTS varflag as it is expected the latter is more likely
to lead to unexpected results due to accidental misconfiguration.
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|
|
Signed-off-by: Joshua Lock <joshua.g.lock@intel.com>
|