Comments (4)
Hi!
This output doesn't mean that nginx is not installed, it's just the standard output from dpkg -s (package status) when the package is not found. Did you run it again to check if the output was different?
from cuisine.
Hello Sébastien!
I tried again using your last changes, but it did not work. I think it should be like this:
diff --git a/cuisine/cuisine.py b/cuisine/cuisine.py
index b9d6f98..05cd3dd 100644
--- a/cuisine/cuisine.py
+++ b/cuisine/cuisine.py
@@ -218,7 +218,7 @@ def package_install( package, update=False ):
def package_ensure( package ):
"""Tests if the given package is installed, and installes it in case it's not
already there."""
- if run("dpkg -s %s | grep 'Status:' ; true" % package).find("installed") == -1:
+ if run("dpkg-query -W -f='${Status}' %s ; true" % package).find("installed") == -1:
package_install(package)
def command_ensure( command, package=None ):
from cuisine.
Thanks a lot, I updated with you changes and pushed it. Let me know if this works.
from cuisine.
yeah, thanks!
now this works fine
from cuisine.
Related Issues (20)
- group_user_ensure fails in suse 11 sp3 HOT 5
- `user_create` function appears in duplicate HOT 1
- cuisine.file_write fails with 7.6 and 7.7 HOT 2
- Why `apt_get` function executes a command twice?
- What is changed between version 0.7.6 and 0.7.7? HOT 6
- SyntaxError: 'invalid syntax' cuisine.py at 342 HOT 1
- how to set up attributes (chef like ) in cuisine HOT 1
- `dir_ensure` tries to create the directory even if it exists HOT 3
- Please rename "bsd" features "freebsd" HOT 2
- file_upload() behavior for lcd context incompatible with fabric put() HOT 4
- Using hashlib breaks compatibility with CentoOS 5 HOT 2
- package_ensure_apt(package_name, update=True) upgrade all package not only selected HOT 2
- Newline at end of updated text
- process_find can't find processes due to leading spaces. HOT 3
- trapping fabric.exceptions.NetworkError HOT 3
- NameError: name 'env' is not defined HOT 2
- README links
- Support for Fabric 2.x? HOT 1
- Fix simple typo: referes -> refers
- Python 3 support
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 cuisine.