summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
| * | Add morphlib module for common write extension codeLars Wirzenius2013-02-063-0/+160
| | |
| * | Add deployment pluginLars Wirzenius2013-02-064-1/+203
| |/ | | | | | | | | | | | | | | | | | | | | This adds a new optional field to system morphologies: "configuration-extensions". The deployment plugin relies heavily on code from the branch and merge plugin. This needs to be eventually fixed by refactoring the codebase so that the shared code is in morphlib and not in plugins. However, doing that is beyond the scope of adding a deployment plugin.
* | Merge branch 'baserock/richardmaw/branch-from-image-v4'Sam Thursfield2013-02-1111-77/+455
|\ \
| * | git: clone then checkout instead of clone -bRichard Maw2013-02-111-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | Newer versions of git have changed the behaviour when cloning with --branch=$sha1. It used to be nearly synonamous with clone then checkout. The clone then checkout logic is different to the clone with branch logic, since they have different behaviour with regard to the branches that are checked out in the workspace.
| * | Add a black-box test for branch-from-imageRichard Maw2013-02-113-0/+59
| | | | | | | | | | | | | | | | | | | | | The test builds a system, makes a commit to mainline, then branches from the system and checks whether it is petrified to the exact commits that the system was built from by checking the morphology contents and rebuilding the system.
| * | branch and merge: add branch-from-image commandRichard Maw2013-02-111-0/+128
| | | | | | | | | | | | | | | | | | Branch from image takes a directory containing metadata, then creates a branch of what the System was built from and petrifies it to when the System was built.
| * | branch and merge: combine checkout and branch logicRichard Maw2013-02-111-48/+37
| | |
| * | Make petrify more versatile than just making tagsRichard Maw2013-02-111-8/+18
| | | | | | | | | | | | | | | | | | | | | | | | Pass resolved_refs in with the key as a repo, ref pair to petrify to the value, rather than petrifying to the current state of the ref. Set update_working_tree to also change files in the working tree, instead of just the index.
| * | RepoAliasResolver: gimp logging during testsRichard Maw2013-02-111-0/+2
| | | | | | | | | | | | | | | | | | Applications default to logging to console, which causes unwanted output during tests, and I thought this was tidier than allowing tests to override the logger per-call.
| * | RepoAliasResolver: Add aliases_from_url methodRichard Maw2013-02-112-0/+63
| | | | | | | | | | | | This returns a sorted list of possible aliases for a url.
| * | repoaliasresolver: compile patterns on creationRichard Maw2013-02-112-19/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | This also involved codifying it ignoring malformed aliases. Such behaviour was implemented before, but wasn't obvious. The restructuring made it have a line of code of its own, which meant it needed unit testing.
| * | Add a regression test for metadata including repo aliasRichard Maw2013-02-112-0/+97
| | |
| * | Make metadata include the repo-alias.Richard Maw2013-02-112-1/+3
|/ / | | | | | | | | | | | | | | | | This is required for reproducing the morphologies that created the artifacts. It is possible, but expensive, to `unexpand` a url, provided your repository aliases are the same as the morphology's, but this may not always be the case.
* | Merge remote-tracking branch 'origin/samthursfield/morph-name-equals-filename'Lars Wirzenius2013-02-113-90/+37
|\ \
| * | Remove test for name mismatchesSam Thursfield2013-02-081-66/+0
| | | | | | | | | | | | No longer possible for this to happen.
| * | Require morphology name to match filenameSam Thursfield2013-02-082-24/+37
| |/ | | | | | | | | | | | | Allowing differences causes only confusion. Whether or not the 'name' field should surive at all is up for debate: it's very useful when seeing the contents of the morphology out of context (e.g. in documentation or pastebins), but is that worth the extra effort?
* | Merge remote-tracking branch 'origin/baserock/richardmaw/safeyaml'Lars Wirzenius2013-02-111-4/+4
|\ \ | |/ |/|
| * yaml: use Safe Loaders and DumpersRichard Maw2013-02-111-4/+4
|/ | | | | This is equivalent to using yaml.safe_load(), but lets us customise how yaml is parsed.
* Merge remote-tracking branch 'remotes/origin/samthursfield/drive-by-fixes'Lars Wirzenius2013-02-064-45/+18
|\
| * Remove deprecated functionsSam Thursfield2013-02-061-24/+0
| |
| * Avoid confusing error when staging area is emptySam Thursfield2013-02-061-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For Morph to work it's necessary for the staging area to contain a full FHS heirarchy. However, if the staging area is empty we want to give the user an obvious error. Previously we would say something like: OSError: [Errno 2] No such file or directory: '/tmp/ccache' This makes it seem like the problem is with ccache. With this patch, we will instead get as far as: /bin/sh: No such file or directory This should make the real problem clearer. Also, aborting while trying to mount the ccache directory causes the /proc and /dev/shm mounts to persist which is fixed by this patch.
| * Tidy up create_cachedir()Sam Thursfield2013-02-062-19/+15
| |
* | Merge branch 'master' of git://git.baserock.org/baserock/baserock/morphLars Wirzenius2013-02-069-114/+153
|\ \ | |/
| * Merge branch 'liw/soft-pyyaml-dep'Sam Thursfield2013-01-297-112/+151
| |\ | | | | | | | | | Merge commit fixes up a copyright year and removes EOL whitespace
| | * Make yaml be an optional dependencyLars Wirzenius2013-01-297-111/+151
| | | | | | | | | | | | | | | This can go away when we have made a release with yaml in it, and its staging filler.
| * | scripts/bootstrap: Fix eglibc2 buildSam Thursfield2013-01-291-1/+1
| | |
| * | Fix copyright yearSam Thursfield2013-01-291-1/+1
| | |
* | | Merge branch 'master' of git://git.baserock.org/baserock/baserock/morphLars Wirzenius2013-01-291-2/+3
|\ \ \ | |/ / | | / | |/ |/|
| * Merge branch 'samthursfield/no-distcc'Sam Thursfield2013-01-291-2/+3
| |\ |/ / | | | | Reviewed-By: Lars Wirzenius (on IRC)
| * Disable distcc by defaultSam Thursfield2013-01-291-2/+3
|/ | | | | | | | | | | | | | | Current versions of build-essential in the Baserock morphologies don't contain distcc, but Morph tries to use distcc anyway. Since useful operation of distcc requires setting up a distcc network, there's no reason for it to be on by default. This change fixes bootstrap, and means that users of the build-essential staging filler no longer have to set no-distcc=true manually. In the future, cliapp will grow automatic boolean negation, which will allow us to turn this setting into a 'distcc' setting that defaults to false rather than the current rather ugly double negative.
* Fix cwd parsing in setup.pyLars Wirzenius2013-01-291-1/+2
| | | | | | If __file__ has no directory in it, dirname will return the empty string, which in turn will break subprocess.Popen. The fix is to use '.' instead of the empty string.
* Merge branch 'jjardon/yaml-v2'Sam Thursfield2013-01-2818-129/+314
|\
| * Remove unneded json module importsJavier Jardón2013-01-284-9/+3
| |
| * Change build tests to use YAML morphologiesJavier Jardón2013-01-285-96/+64
| |
| * Fix testsRichard Maw2013-01-223-5/+89
| | | | | | | | | | | | | | | | Invalid text changed to be something that doesn't parse as YAML either, and catch convert the YAMLError to the expected exception. Ideally there wouldn't be any `#pragma: no cover`s, but I could not trigger these code paths.
| * Parse as YAML if not valid JSONRichard Maw2013-01-225-9/+147
| | | | | | | | | | Tests are currently broken, one because invalid JSON can be valid YAML, and coverage is incomplete.
| * Move OrderedDict and json loading to morphlib.utilRichard Maw2013-01-222-11/+12
| | | | | | | | | | | | | | | | This way everyone who needs json or an OrderedDict doesn't have to worry about it. Currently morph2 is the only one that needs this complex behaviour, other users of the json module don't need object_pairs_hook.
* | Merge remote-tracking branch 'origin/baserock/richardmaw/morph-version'Lars Wirzenius2013-01-287-7/+216
|\ \
| * | Add regression test for metadata including versionRichard Maw2013-01-282-0/+100
| | |
| * | Include morph-version in artifact metadataRichard Maw2013-01-281-0/+7
| | | | | | | | | | | | | | | | | | This can be used to rebuild an artifact with the exact same version of morph. Eventually there may be a tool to do this, but it allows for expert diagnosis until that point.
| * | Make morph get its version from git.Richard Maw2013-01-284-7/+109
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When morph is built, it writes various version information from git into morphlib. When morphlib is loaded it attempts to read this version information. if it cannot be found then it checks whether morphlib is being run from inside a git checkout, if it is then it reads the information that way. If it isn't in a git checkout then it raises an exception as builds made in such a fashion are not reproducible. The git version information retained is: 1. The output of git describe This is a relatively human-friendly way of knowing a version and gives a reasonably short output string. This will end with `-unreproducible` if there were uncommitted changes. 2. The commit sha1, so the exact part of Morph's history can be found 3. The tree sha1, so if the branch has been rebased rather than merged such that the commit is lost, you may still be able to find it, though it requires a git-wizard to check it out 4. The branch of morph, so that it's easier to see if the Further possible changes to increase reproducibility include: 1. Not allowing `python setup.py build` if there are uncommitted changes 2. Failing to run with uncommitted changes (recommended against since it will just annoy developers who are making changes to morph, and make them commit just to shut it up, then destroy the history later) Requiring an extra flag to build in this case may work better. 3. Reading the uncommitted changes into a tree object and including that would allow it to be recovered if the tree was later committed. 4. Checking whether the commit has been pushed upstream as well. Too annoying to work.
* | Merge remote-tracking branch ↵Lars Wirzenius2013-01-282-3/+61
|\ \ | | | | | | | | | | | | | | | 'origin/baserock/richardmaw/temp-build-ref-commit-fix' Broke a long line to make test suite pass.
| * | Add test for committed removes being trackedRichard Maw2013-01-251-0/+56
| | | | | | | | | | | | This was the only case found which was fixed by the previous commit.
| * | Make temporary build refs count changes against HEADRichard Maw2013-01-251-3/+4
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before it would determine which files are changed by comparing your working tree to This gets even weirder, since it's effectively comparing your working tree, the last commit on the temporary build ref, and the last commit of your HEAD, so committing a change to remove a file isn't noticed, because it was in the temporary build branch. It could also cause a strange case of a file being both added and untracked. Now the working tree and HEAD are compared, and committed on top of the temporary build ref. Better handling of the status output is still required, a deleted file is treated identically to an added one if it is only removed in the index. It would also be nicer to keep the user's index, since they may have added or removed files from it.
* | Fix copyright yearSam Thursfield2013-01-281-1/+1
| |
* | Merge remote-tracking branch 'origin/samthursfield/build-essential'Lars Wirzenius2013-01-282-0/+558
|\ \ | |/ |/| | | Fixed long lines in scripts/bootstrap while merging.
| * Run ldconfig after populating staging chrootSam Thursfield2013-01-241-0/+3
| | | | | | | | | | | | | | | | After installing libraries into the staging area, we need to run ldconfig to update the shared library cache. I presume that this wasn't required until now because the cache in the staging filler tarball was enough.
| * Add script to manually create a build-essential staging fillerSam Thursfield2013-01-241-0/+553
|/ | | | | | | | | | | | | This functionality, of building a build-essential staging filler using host tools rather than a staging chroot, will eventually be done by Morph (and best of all, it will be done automatically when changes are made to the build-essential stratum). The script doesn't handle fetching source, so to use the script, you require a base directory which must contain a 'gits' subdirectory with a checkout of each chunk. Beyond this the build process is handled by the script, except for installing fhs-dirs (which requires root priviliges and must be done manually).
* Remove scripts/clean-git-cacheSam Thursfield2013-01-221-240/+0
| | | | | | | This script has not worked for some time, and is not particularly useful ('rm -r' can do pretty much the same thing). Reviewed-By: Richard Maw <richard.maw@codethink.co.u>
* Merge branch 'baserock/richardmaw/fix-morph-check-on-squeeze'Richard Maw2013-01-223-0/+42
|\