Merge lp:~thumper/juju-core/fix-lxc-destroy into lp:~go-bot/juju-core/trunk
Proposed by
Tim Penhey
Status: | Merged | ||||
---|---|---|---|---|---|
Approved by: | Tim Penhey | ||||
Approved revision: | no longer in the source branch. | ||||
Merged at revision: | 1492 | ||||
Proposed branch: | lp:~thumper/juju-core/fix-lxc-destroy | ||||
Merge into: | lp:~go-bot/juju-core/trunk | ||||
Diff against target: |
33 lines (+1/-7) 2 files modified
container/lxc/lxc.go (+1/-5) container/lxc/lxc_test.go (+0/-2) |
||||
To merge this branch: | bzr merge lp:~thumper/juju-core/fix-lxc-destroy | ||||
Related bugs: |
|
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Juju Engineering | Pending | ||
Review via email: mp+175694@code.launchpad.net |
Commit message
Fix local provider destroy environment.
lxc-destroy removes the restart symlink, so we don't have to.
Right now we are failing because we can't remove it.
Description of the change
Fix local provider destroy environment.
lxc-destroy removes the restart symlink, so we don't have to.
Right now we are failing because we can't remove it.
To post a comment you must log in.
Reviewers: mp+175694_ code.launchpad. net,
Message:
Please take a look.
Description:
Fix local provider destroy environment.
lxc-destroy removes the restart symlink, so we don't have to.
Right now we are failing because we can't remove it.
https:/ /code.launchpad .net/~thumper/ juju-core/ fix-lxc- destroy/ +merge/ 175694
(do not edit description out of merge proposal)
Please review this at https:/ /codereview. appspot. com/11546043/
Affected files: lxc/lxc. go lxc/lxc_ test.go
A [revision details]
M container/
M container/
Index: [revision details] 20130718173319- vlhw6iu5usihaaz p
=== added file '[revision details]'
--- [revision details] 2012-01-01 00:00:00 +0000
+++ [revision details] 2012-01-01 00:00:00 +0000
@@ -0,0 +1,2 @@
+Old revision: tarmac-
+New revision: <email address hidden>
Index: container/ lxc/lxc. go lxc/lxc. go' lxc/lxc. go 2013-07-18 02:55:17 +0000 lxc/lxc. go 2013-07-18 21:43:30 +0000 Errorf( "failed to stop lxc container: %v", err) Destroy( ); err != nil { Errorf( "failed to destroy lxc container: %v", err) restartSymlink( name)); err != nil { Tracef( "auto-restart link removed")
=== modified file 'container/
--- container/
+++ container/
@@ -157,15 +157,11 @@
logger.
return err
}
+ // Destroy removes the restart symlink for us.
if err := container.
logger.
return err
}
- // Remove the autostart symlink
- if err := os.Remove(
- return err
- }
- logger.
// Move the directory. Tracef( "create old container dir: %s", removedContaine rDir)
logger.
Index: container/ lxc/lxc_ test.go lxc/lxc_ test.go' lxc/lxc_ test.go 2013-07-17 23:38:15 +0000 lxc/lxc_ test.go 2013-07-18 21:43:30 +0000 filepath. Join(s. ContainerDir, name), jc.DoesNotExist) filepath. Join(s. RemovedDir, name), jc.IsDirectory) filepath. Join(s. RestartDir, name+".conf"), jc.DoesNotExist)
=== modified file 'container/
--- container/
+++ container/
@@ -122,8 +122,6 @@
c.Assert(
// but instead, in the removed container dir
c.Assert(
- // Check that the restart link has been removed.
- c.Assert(
}
func (s *LxcSuite) TestStopContain erNameClash( c *gc.C) {