-
Notifications
You must be signed in to change notification settings - Fork 680
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
Add omnibus for inspec #658
Conversation
Inspec is already part of |
@srenatus No, that was not left out intentionally. I just figured out that omnibus software uses bundler, which is not required at all. So I harmonize both, so that we can depend on |
name 'inspec' | ||
|
||
dependency 'ruby' | ||
dependency 'train' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no need to define train, since it is defined as gem dependency
064feeb
to
ae9c6d2
Compare
@@ -0,0 +1,3 @@ | |||
<% config_files.each do |file| -%> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This and the other deb
and rpm
resource files appear identical to the default versions that omnibus will use. Perhaps we can remove them from here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Go ahead, makes sense from my perspective.
ae9c6d2
to
5aaa675
Compare
|
||
# Dependecy added to avoid this pry error: | ||
# "Sorry, you can't use Pry without Readline or a compatible library." | ||
gem "install rb-readline --no-document", env: env |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If this is required, should we put it in our gemspec instead?
Ready for Review. Two questions possible changes we could consider:
|
6763fe1
to
a6dbb22
Compare
- Removes resource files which matched the default implementations contained in omnibus. - Removes software definition for train which will be installed via the gem dependecies in the inspec defintion. - Appbundle inspec to match our other ruby-based projects - Update rubocop style violations - Update copyright notices Signed-off-by: Steven Danna <steve@chef.io>
a6dbb22
to
07f7485
Compare
@stevendanna Awesome, works as expected! |
I think we should go with appbundler for now and leave the Gemfile.lock out of this PR |
If you're using appbundler, then you need bundler (to generate the Gemfile.lock), negating the need to write the custom inspec software definition. |
|
||
# Dependecy added to avoid this pry error: "Sorry, you can't use Pry | ||
# without Readline or a compatible library." | ||
gem 'install rb-readline --no-document', env: env |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ksubrama Can you open a PR to add this improvement?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can do - I'm noting down a few other issues I noticed and will open a PR will all of the fixes.
|
||
# Defaults to C:/inspec on Windows | ||
# and /opt/inspec on all other platforms | ||
install_dir "#{default_root}/#{name}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we prefer C:/opscode/inspec? It is where we land all our other projects and yet another top level directory at root level is going to be a bit annoying. Also, top level directories in a drive has special pitfalls when it comes to permission/inheritance.
This is the first step to build packages for InSpec. The current PR includes all files required to build deb and rpm packages.