| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | |
|
| |
| |
| |
| |
| |
| | |
Since we're no longer adding anything to the queue we can replace it with a loop.
This patch also splits the code up a little bit.
|
| |
| |
| |
| |
| |
| |
| | |
Artifact resolution is no longer recursive, so there's no need to requeue
sources, removing this queue provides a significant speed up. Fixing an
issue where artifact resoltuion was taking too long on some systems
(several minutes in some cases).
|
| | |
|
|\ \
| | |
| | |
| | |
| | |
| | | |
Reviewed-By: Adam Coldrick <adam.coldrick@codethink.co.uk>
Reviewed-By: Richard Ipsum <richard.ipsum@codethink.co.uk>
Reviewed-By: Richard Maw <richard.maw@codethink.co.uk>
|
| |/
| |
| |
| | |
It was broken by the per-source building changes.
|
|\ \
| |/
|/|
| |
| |
| | |
Reviewed-by: Sam Thursfield
Reviewed-by: Jim MacArthur
Reviewed-by: Richard Ipsum
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A quirk in the resource cleanup code meant that if you gave the same
version label when deploying a new version, then it would fail, then
remove the old version, as it had assumed that it was the one to create
those directories.
This patch fixes this issue by making short context managers for all the
resource allocation, so cleanup is done by walking up the context
managers, so only the mount and the temporary directory need to be
cleaned up if the `mkdir "$VERSION_ROOT"` fails.
I've tested this with a deploy of a version that doesn't already exist,
and the version I'm currently running, so I can conclusively say it's
fixed that problem.
|
|\
| |
| |
| |
| | |
Reviewed-by: Pedro Alvarez
Reviewed-by: Richard Maw
|
| | |
|
| |
| |
| |
| |
| |
| | |
The original resolve_artifacts method is essentially unchanged,
it's just private now. This means that aside from this name change
the tests remain the same.
|
| |
| |
| |
| |
| |
| |
| |
| | |
This patch started off as an attempt to address the comment in
find_root_artifacts, though this patch doesn't impose an ordering on the list
of artifacts as the comment suggested. The artifact resolver now returns
a list of root artifacts which may make it easier to add multi-system builds
to morph.
|
|\ \
| | |
| | |
| | |
| | | |
Reviewed-By: Pedro Alvarez <pedro.alvarez@codethink.co.uk>
Reviewed-By: Francisco Redondo Marchena <francisco.marchena@codethink.co.uk>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
It now gives an error message.
Previously it would fail with a backtrace like this:
2014-10-08 09:51:37 [systems/genivi-baseline-system-armv7lhf-jetson.morph][self]Removing temporary mounts
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/cliapp/app.py", line 190, in _run
self.process_args(args)
File "/src/morph/morphlib/exts/ssh-rsync.write", line 54, in process_args
self.upgrade_remote_system(location, temp_root)
File "/src/morph/morphlib/exts/ssh-rsync.write", line 107, in upgrade_remote_system
location, ['btrfs', 'subvolume', 'delete', orig_dir])
UnboundLocalError: local variable 'orig_dir' referenced before assignment
|
|\ \ \
| |/ /
|/| |
| | |
| | |
| | | |
Reviewed-by: Sam Thursfield
Reviewed-by: Richard Ipsum
Reviewed-by: Pedro Alvarez
|
| | | |
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
You can bind to an ephemeral port by passing 0 as the port number.
To work out which port you actually got, you need to call getsockname().
To facilitate being able to spawn multiple copies of the daemons for
testing environments, you can pass a -file option, which will make the
daemon write which port it actually bound to.
If this path is a fifo, reading from it in the spawner process will
allow synchronisation of only spawning services that require that port to
be ready after it is.
|
| | |
| | |
| | |
| | |
| | |
| | | |
This is needed for distbuild to deserialise based on the split rules on
the node that did the graph calculation, rather than the node that does
the building.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
I've rarely needed to use it, and on those rare occasions, it would have
been easy enough to calculate it.
Let's get rid of this step, and save everyone some time in future.
|
| | |
| | |
| | |
| | | |
It's easy enough to deploy the image.
|
|\ \ \
| | | |
| | | |
| | | |
| | | | |
Reviewed-By: Pedro Alvarez <pedro.alvarez@codethink.co.uk>
Reviewed-By: Francisco Redondo Marchena <francisco.marchena@codethink.co.uk>
|
| | |/
| |/|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Previously if the user included 'baserock' in their list of trove-ids,
the keyed URL expansions in the repo-alias field would change such that
reading from git.baserock.org required SSH access. This isn't good and
in particular breaks Mason, which by default isn't set up with a Gitano
account on the Trove that it reads from, and therefore doesn't have SSH
access to that Trove.
With this change, the trove-id field will not cause the default
'baserock:' and 'upstream:' prefixes to be overridden, so setting
'trove-id = baserock' in morph.conf will not Morph's behaviour to
change.
|
| | |
| | |
| | |
| | |
| | | |
os.read is limited to an int in size. copy_slice_from_file was trying
to os.read more than that causing an OverflowError.
|
| |/
|/|
| |
| |
| |
| |
| |
| |
| | |
With this patch, the fstab of the system to be deployed
as an upgrade will be conifgured using the UUID of
the disk.
Now when doing an upgrade is not needed to specify the
ROOT_DEVICE.
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, if morph is installed in the system, `morph --version`
prints the sha1 of the version installed.
$ morph --version
e8adedb8f3f27d9212caf277b8e8f7c6792a20c2
If you run morph from git, the output will be something similar to
the following.
$ morph --version
baserock-14.26-124-g7b73af4
This patch changes the behaviour of the latter to match the former.
|
|
|
|
|
|
|
|
|
| |
The msg parameter to status is a format string. If we pass a string
directly to it, then we have to be careful to escape any formatting
characters.
However, we can just do the interpolation directly in the status call
instead, which is less code.
|
| |
|
|\
| |
| |
| |
| |
| | |
Reviewed-by: Lars Wirzenius (+2 to misc fixups)
Reviewed-by: Sam Thursfield (+1 to per-source building)
Reviewed-by: Paul Sherwood (+1 to per-source building)
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| | |
This was used by artifacts to tell what they should put in their path,
based on what prefixes were used earlier.
This implementation didn't handle recursive deps, and it was trivial to
open-code it at the call-site, so it is no longer useful.
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| | |
This means we can avoid having to rewrite everything immediately after
the fields moved.
|
| | |
|
| |
| |
| |
| |
| | |
This is logically part of the previous patch, but has been split out to
ease reviewing.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Building per-artifact results in undesirable behaviour,
as multiple artifacts are produced for every chunk build.
It therefore makes more sense to build per-source.
This implies that actually, the model of one source per
morphology is wrong and we should move the dependencies
into the source.
Unlike chunks however, where every chunk artifact has the
same dependencies, stratum artifacts can have different
dependencies.
So before we can move the dependencies into the Source,
we need to have as many Sources as Stratum Artifacts.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
I need to be able to deduplicate a list of morphologies. Putting it in a
set is the easiest way, but it needs to be hashable.
It's not included in dicts by default, since they're stored by
reference, and you can change them while they're in the dict, so the
hash value can change.
I don't need to deduplicate morphologies by their contents, just by
reference though, so using `id` as the hash function is sufficient.
|
| |
| |
| |
| |
| | |
This means we can remove some complication from the MorphologyFactory
class.
|
| |
| |
| |
| |
| | |
This was used before the Artifact splitting code landed to determine
which artifacts should be produced.
|
| | |
|
| |
| |
| |
| |
| | |
There's other methods called get_sources in other modules, and
fetch_sources explains more about what it does in the context.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
metadata_version is for when the format of the /baserock metadata files
changes.
This means it would make sense for it to either live with the code for
generating the metadata, or the cache key code so it lives with the rest
of the compatibility values.
Since the code for generating the metadata isn't in a nice module
anywhere, I've put it in the cachekeycomputer module.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
It was an odd thing to have, when Artifact objects are part of your
input.
Its purpose appears to have been to allow the build step to produce an
artifact called $morphology_name-rootfs, but since the split rules
decide that the artifact is called that anyway, the new_artifact step is
redundant.
|
| | |
|
| | |
|
| |
| |
| |
| |
| | |
This helps debugging issues with rule matching, since SplitRules can be
print-statemented
|
| |
| |
| |
| |
| |
| |
| |
| | |
It rather peculiarly defines artifacts that have different cache keys,
but the same source.
This flies in the face of how real artifacts get cache keys, and our
ability to move the cache key to being per-source.
|