Merge lp:~bac/lpsetup/muerte_finis_init_host into lp:lpsetup
| Status: | Merged |
|---|---|
| Approved by: | Brad Crittenden on 2012-08-24 |
| Approved revision: | 82 |
| Merged at revision: | 76 |
| Proposed branch: | lp:~bac/lpsetup/muerte_finis_init_host |
| Merge into: | lp:lpsetup |
| Diff against target: |
342 lines (+58/-138) 8 files modified
commands.rst (+1/-19) lpsetup/cli.py (+0/-2) lpsetup/subcommands/finish_init_target.py (+0/-99) lpsetup/subcommands/install_lxc.py (+22/-12) lpsetup/subcommands/update.py (+13/-0) lpsetup/tests/subcommands/test_smoke.py (+0/-1) lpsetup/tests/test_utils.py (+6/-0) lpsetup/utils.py (+16/-5) |
| To merge this branch: | bzr merge lp:~bac/lpsetup/muerte_finis_init_host |
| Related bugs: |
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| Gary Poster (community) | 2012-08-23 | Approve on 2012-08-23 | |
|
Review via email:
|
|||
Commit Message
Move everything from finish-init-host to update or install-lxc and remove finish-init-host.
Description of the Change
Move 'make schema' to 'update' subcommand. Move 'make install' and the ownership change of /srv/launchpad.dev to be a final step of 'install-lxc'.
The function 'this_command' was changed to take an optional arbitrary command rather than always using sys.argv[0] to allow other commands to be invoked inside the lxc.
| Launchpad QA Bot (lpqabot) wrote : | # |
There are additional revisions which have not been approved in review. Please seek review and approval of these new revisions.
| Launchpad QA Bot (lpqabot) wrote : | # |
The attempt to merge lp:~bac/lpsetup/muerte_finis_init_host into lp:lpsetup failed. Below is the output from the failed tests.
./lpsetup/
16: 'pwd' imported but unused
+ set -o errexit
++ grep -v distribute_setup.py
++ find . -name build -prune -o -name '*.py'
+ pyfiles='./setup.py
./lplxcip/
./lplxcip/
./lplxcip/
./lplxcip/
./lplxcip/
./lplxcip/lxcip.py
./lpsetup/utils.py
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/cli.py'
+ pocketlint ./setup.py ./lplxcip/
| Launchpad QA Bot (lpqabot) wrote : | # |
The attempt to merge lp:~bac/lpsetup/muerte_finis_init_host into lp:lpsetup failed. Below is the output from the failed tests.
lxc.aa_profile = lxc-container-
WARNING: this command will destroy the 'lpsetup-
This includes all machines, services, data, and other resources. Continue [y/N]**
* Checking test environment. *
*******
*******
* Setting up the test environment for LXC container. *
*******
-------
check_call:
juju bootstrap -e lpsetup-testing-lxc
-------
*******
None
*******
*******
* Cleaning up. *
*******
*******
* Run time: 0:00:45.895267 *
*******
+ set -o errexit
++ find . -name build -prune -o -name '*.py'
++ grep -v distribute_setup.py
+ pyfiles='./setup.py
./lplxcip/
./lplxcip/
./lplxcip/
./lplxcip/
./lplxcip/
./lplxcip/lxcip.py
./lpsetup/utils.py
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/
./lpsetup/cli.py'
+ pocketlint ./setup.py ./lplxcip/
| Brad Crittenden (bac) wrote : | # |
The previous failure is curious. Retrying.

Thank you, Brad. This looks good. It is nice to see so much deleted code!
I'm slightly concerned that this code in the new finish function...
206 + # Change owner of /srv/launchpad. dev/. '/srv/launchpad .dev/', pwd_database. pw_uid, pwd_database. pw_gid)
207 + pwd_database = pwd.getpwnam(user)
208 + os.chown(
...won't work in some edge cases because it should be using the password database in the container, and not in the host. I can imagine that this edge case won't happen because we need to have the same user in the host and the container, and they need to share passwords. If that's the case, please add a comment to that effect; otherwise, please consider using the container's password database.
In this help text...
231 This is basically the same of running `init-lxc` and then, inside the \ init-target` .
232 - newly created container, `init-repo`, `update` and `finish-
233 + newly created container, `init-repo` and `update`.
...I suggest that we instead change the text to say, "This is basically the same as running `init-lxc` and then, inside the newly created container, `lp-setup init-repo`, `lp-setup update` and `make install`." To be clear, that is four changes: s/the same of running/the same as running/, s/`init- repo`/` lp-setup init-repo`, s/`update` /`lp-setup update`/, and s/`finish- init-target` /`make install`.
Thank you!