Merge pull request #120 from leebaok/master

delete some unused code
#114
This commit is contained in:
leebaok 2016-05-24 04:02:29 -05:00
commit 4a2d86ad71
5 changed files with 3 additions and 8 deletions

View File

@ -329,10 +329,6 @@ IP=%s
def create_image(self,username,imagename,containername,description="not thing",imagenum=10): def create_image(self,username,imagename,containername,description="not thing",imagenum=10):
return self.imgmgr.createImage(username,imagename,containername,description,imagenum) return self.imgmgr.createImage(username,imagename,containername,description,imagenum)
def flush_container(self,username,imagename,containername):
self.imgmgr.flush_one(username,imagename,containername)
logger.info("container: %s has been flushed" % containername)
return 0
# check all local containers # check all local containers
def check_allcontainers(self): def check_allcontainers(self):
[both, onlylocal, onlyglobal] = self.diff_containers() [both, onlylocal, onlyglobal] = self.diff_containers()

0
src/sysmgr.py Normal file → Executable file
View File

View File

@ -339,7 +339,6 @@ class VclusterMgr(object):
proxytool.set_route('/go/'+username+'/'+clustername, target) proxytool.set_route('/go/'+username+'/'+clustername, target)
except: except:
return [False, "start cluster failed with setting proxy failed"] return [False, "start cluster failed with setting proxy failed"]
info['containers'][0]
# recover containers of this cluster # recover containers of this cluster
for container in info['containers']: for container in info['containers']:
worker = self.nodemgr.ip_to_rpc(container['host']) worker = self.nodemgr.ip_to_rpc(container['host'])

View File

@ -16,7 +16,7 @@ import threading
import etcdlib, network, container import etcdlib, network, container
from nettools import netcontrol from nettools import netcontrol
import monitor import monitor
from lvmtool import * from lvmtool import new_group, recover_group
################################################################## ##################################################################
# Worker # Worker
@ -61,7 +61,7 @@ class Worker(object):
if status: if status:
self.key = generatekey("machines/allnodes/"+self.addr) self.key = generatekey("machines/allnodes/"+self.addr)
else: else:
logger.error("get key failed. %s" % node) logger.error("get key failed. %s" % 'machines/runnodes/'+self.addr)
sys.exit(1) sys.exit(1)
# check token to check global directory # check token to check global directory

View File

@ -184,7 +184,7 @@
<footer class="main-footer"> <footer class="main-footer">
<!-- To the right --> <!-- To the right -->
<div class="pull-right hidden-xs"> <div class="pull-right hidden-xs">
<i>Docklet 0.2.6</i> <i>Docklet 0.2.7</i>
</div> </div>
<!-- Default to the left --> <!-- Default to the left -->
<strong>Copyright</strong>&copy;&nbsp;2016 <a href="http://docklet.unias.org">UniAS</a>@<a href="http://www.sei.pku.edu.cn"> SEI, PKU</a> <strong>Copyright</strong>&copy;&nbsp;2016 <a href="http://docklet.unias.org">UniAS</a>@<a href="http://www.sei.pku.edu.cn"> SEI, PKU</a>