Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

be_enabled for upstart service on RHEL 6 not working correctly #417

Closed
fletchowns opened this issue Feb 4, 2016 · 5 comments
Closed

be_enabled for upstart service on RHEL 6 not working correctly #417

fletchowns opened this issue Feb 4, 2016 · 5 comments

Comments

@fletchowns
Copy link

I'm running CentOS 6.5 with inspec

I run uwsgi as an upstart service. I had the following inspec test:

describe upstart_service('uwsgi') do
    it { should be_installed }
    it { should be_enabled }
    it { should be_running }
end
Failures:

  1) Service uwsgi should be enabled
     Failure/Error: DEFAULT_FAILURE_NOTIFIER = lambda { |failure, _opts| raise failure }
       expected that `Service uwsgi` is enabled
     # ./test/integration/default/mytest_spec.rb:11:in `block (2 levels) in load'
     # C:/Users/fletchowns/AppData/Local/chefdk/gem/ruby/2.1.0/gems/kitchen-inspec-0.10.1/lib/kitchen/verifier/inspec.b:43:in `call'

Apparently it uses initctl show-config to do this check, but the RHEL 6 version of upstart doesn't seem to support that:

# initctl show-config uwsgi
initctl: invalid command: show-config
Try `initctl --help' for more information.
# initctl version
init (upstart 0.6.5)
@chris-rock
Copy link
Contributor

@fletchowns thanks for reporting. Can you provide installation instructions for upstart on CentOS?

@fletchowns
Copy link
Author

@chris-rock I don't remember doing anything special to install upstart on CentOS, I think it came with it. I'm using the chef/bento box for centos 6.5: http://opscode-vm-bento.s3.amazonaws.com/vagrant/virtualbox/opscode_centos-6.5_chef-provisionerless.box

@chris-rock
Copy link
Contributor

if its in the bento box, that is great, that eases the testing. thanks for sharing.

@srenatus
Copy link
Contributor

srenatus commented Feb 5, 2016

Yup, seems like show-config was added in 1.3.

@fletchowns
Copy link
Author

New version works great guys, thanks for the lightning fast turnaround!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants