Comments (3)
I have checked returncode after calling sys_run, the bug today is i call (lxc-stop -k -n %s) but not ((lxc-stop -k -n %s) % lxc_name). So the shell regard "%s" as lxc_name. I have checked the returncode after calling this, but the calling is a "grep RUNNING". It return not 0, the same with a stopped container. Docklet misakes it for a stopped container. It is not because that I call sys_run without checking returncode.
from docklet.
you mean checking like this?
if status == "running":
sys_run("lxc-stop -k -n %s" % lxc_name)
[success, status] = self.container_status(lxc_name)
should be
Ret = sys_run(...)
if Ret.returncode == 0:
I recommend not encapsulating sys call in sys_run, you can directly call subprocess.run with check=True, or we do not need to using this python 3.5 new api.
from docklet.
Done
from docklet.
Related Issues (20)
- replace GRE with VXLAN to avoid critical-node crash
- not using default setting while scaling out a new node HOT 1
- setting default container setting in user config panel or admin panel HOT 1
- Add multiple nodes in one click
- record and display history of all containers HOT 1
- generated_password file not exist after master init HOT 1
- Separate user module from monitor HOT 1
- Image save failed HOT 2
- rename Dashboard to Workspace HOT 1
- add docklet hyperlink in web portal HOT 1
- Cannot modify users' info in /user/list HOT 1
- Add qos rate limiting and port mappings billings
- Threading Synchronization
- Job Management module in batch computing
- Task management module for batch computing
- agent enhancement to support batch computing
- Users' requests are blocked sometimes because of unreleased users' locks HOT 1
- acquire lock without release when exception occur HOT 1
- Refine container job creation HOT 1
- Any chance updating this to use LXD HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from docklet.