summaryrefslogtreecommitdiff
path: root/lib/chef/application
Commit message (Collapse)AuthorAgeFilesLines
* Remove copyright dateslcg/remove-copyright-datesLamont Granquist2020-04-137-7/+7
| | | | | | | | Legally incredibly dubious, particularly since we don't follow it strictly as policy, and we have git history instead, which does it right. This is just a waste of time and a cargo cult. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Fix typoVivek Singh2020-04-061-1/+1
| | | | Signed-off-by: Vivek Singh <vivek.singh@msystechnologies.com>
* Simplify YAML mode checking for chef-applyBryan McLellan2020-03-231-5/+2
| | | | Signed-off-by: Bryan McLellan <btm@loftninjas.org>
* Add YAML support to 'chef-apply'Bryan McLellan2020-03-231-1/+15
| | | | | | | Allows `chef-apply foo.yml` to be parsed as a YAML recipe. Also adds a configuration flag to enable `chef-apply foo.whatever --yaml`. Signed-off-by: Bryan McLellan <btm@loftninjas.org>
* fix ruby 2.7 encoding bug and add --always-dump-stacktrace optionLamont Granquist2020-03-112-1/+13
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Fix our verbosity helpTim Smith2020-02-201-1/+1
| | | | | | It's 3 times for the max now. Signed-off-by: Tim Smith <tsmith@chef.io>
* new distro constant for chef-applyMarc Chamberland2019-12-091-2/+2
| | | | Signed-off-by: Marc Chamberland <chamberland.marc@gmail.com>
* bribing the copsMarc Chamberland2019-12-052-3/+3
| | | | Signed-off-by: Marc Chamberland <chamberland.marc@gmail.com>
* inserting distro constants into windows service messagesMarc Chamberland2019-12-052-5/+5
| | | | Signed-off-by: Marc Chamberland <chamberland.marc@gmail.com>
* Add chef-utils gem with various recipe DSL helpersLamont Granquist2019-11-082-2/+2
| | | | | | | | | | | | | This is the implementation of [RFC-087](https://github.com/chef-boneyard/chef-rfc/blob/master/rfc087-distro-sugar-helpers.md) although some of the specifics have been iterated on and changed. The documentation will be in the [README.md](https://github.com/chef/chef/tree/master/chef-utils/README.md) once this is merged. While this PR mostly moves chef-sugar utilities into core-chef via this chef-utils gem, the scope of the chef-utils gem should be considered larger than just that. As an example this PR moves the Mash class into this gem for reuse in ohai as well. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Add format supported option in valuesVivek Singh2019-10-281-0/+1
| | | | Signed-off-by: Vivek Singh <vivek.singh@msystechnologies.com>
* Revert "Drop privileges before creating files in solo mode"lcg/revert-drop-permsLamont Granquist2019-09-111-1/+1
| | | | This reverts commit 68b9e91d3b1471dafbe854fd3fcdc793d5a8b70e.
* fail on interval runs on windowsLamont Granquist2019-08-283-3/+20
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Tidy up awkward reading commentlcg/application-base-classLamont Granquist2019-07-151-2/+1
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* support named run list on commandline in soloLamont Granquist2019-07-152-5/+5
| | | | | | this has to fix a bug for someone. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* consolidate some options in the base classLamont Granquist2019-07-153-53/+53
| | | | | | | | | | | | | | | most of these are options that apply to either chef-client -z or to chef-solo without legacy mode, so they are justifiably common options (that are handled by the trampolining into the Client code from Solo right now. the --legacy-mode switch is solo-specific (although we should wire it up for chef-client eventually once all the code is merged). old-reporting and skip-cookbook-sync only make sense for actual chef-client runs so are marked as such in the help text Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* --fips, --fatal-windows-admin-check and --disable-configLamont Granquist2019-07-153-19/+21
| | | | | | | | should fix fips mode for chef-solo, adds the windows admin check feature, but the distable-config option needs some future work to the base class to support it. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* add some comments on deprecation of the solo classLamont Granquist2019-07-153-0/+22
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* missing SELF_PIPE for the daemon loopLamont Granquist2019-07-152-3/+3
|
* migrate --delete-entire-chef-repo to base classLamont Granquist2019-07-153-10/+5
| | | | | | this is a trivial duplication Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Copy the daemon loop from client to baseLamont Granquist2019-07-153-157/+106
| | | | | | | These improvements never made it into solo and should be backwards compatible. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* add --target-mode to base classLamont Granquist2019-07-152-9/+9
| | | | | | this adds it to chef-solo Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* copy --ez to base classLamont Granquist2019-07-152-15/+16
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* change some uses of CLIENT to PRODUCT in the base classLamont Granquist2019-07-151-4/+4
|
* add --once to base classLamont Granquist2019-07-152-5/+5
| | | | | this was not present in chef-solo for whatever reason even though the code is there, it has always been broken
* normalize fetch_recipe_tarballLamont Granquist2019-07-153-25/+15
| | | | | | | | | | | this makes solo behave like client does. client was modified in these pulls: https://github.com/chef/chef/pull/7223 https://github.com/chef/chef/pull/7523 but those changes were never "ported" to solo.
* create application base class for de-duplicationLamont Granquist2019-07-153-346/+198
| | | | | | all of the changes in this commit should be mechanical and identical Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Style/StringLiteralsInInterpolationLamont Granquist2019-07-052-3/+3
| | | | | | since we use double quotes, be consistent everywhere. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Style/RegexpLiteralLamont Granquist2019-07-052-2/+2
| | | | | | | given how many regexps we have with /'s in the match this seems like a very good one. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Style/NegatedIfLamont Granquist2019-07-054-4/+4
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Style/SymbolArrayLamont Granquist2019-07-021-1/+1
| | | | | | start enforcing using %i{} instead of arrays of symbols Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* more distro constantsMarc Chamberland2019-06-032-3/+3
| | | | Signed-off-by: Marc Chamberland <mchamberland@pbsc.com>
* More distro constant applicationsMarc Chamberland2019-05-231-2/+2
| | | | Signed-off-by: Marc Chamberland <mchamberland@pbsc.com>
* distro constants for solo, zero and automateMarc Chamberland2019-05-233-6/+6
| | | | Signed-off-by: Marc Chamberland <mchamberland@pbsc.com>
* This hits the ones that are most frequently required.lcg/require-idempotencyLamont Granquist2019-05-205-11/+11
| | | | | | | | | Stops the kernel from scanning through all the activated gems every time in order to resolve names into pathnames. See rubygems/rubygems#2762 Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Add Chef license acceptance CLI flag to chef-solochef_apply_licenseTim Smith2019-05-151-0/+2
| | | | | | Our major CLI commands should all have this Signed-off-by: Tim Smith <tsmith@chef.io>
* Add license CLI options to chef-apply commandTim Smith2019-05-151-0/+2
| | | | | | | You could accept the license interactively but you could not do it via the CLI flag Signed-off-by: Tim Smith <tsmith@chef.io>
* fix a bunch of weirdly mangled require linesLamont Granquist2019-05-085-8/+8
| | | | Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Convert require to require_relativeLamont Granquist2019-05-087-44/+44
| | | | | | | This gives a speed boost since rubygems does not have to scan through every gem in the gemset in order to find the file. Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
* Merge pull request #7758 from chef/btm/target-modeTim Smith2019-05-061-0/+15
|\ | | | | Initial target_mode implementation
| * Update target mode log message for Chef::DistBryan McLellan2019-05-061-1/+1
| | | | | | | | Signed-off-by: Bryan McLellan <btm@chef.io>
| * Target Mode initial implementationBryan McLellan2019-05-061-0/+15
| | | | | | | | Signed-off-by: Bryan McLellan <btm@chef.io>
* | Use keyword arguments for acceptanceMark Anderson2019-05-031-1/+1
| | | | | | | | Signed-off-by: Mark Anderson <mark@chef.io>
* | Only Chef Software binaries should enforce EULAtyler-ball2019-05-032-2/+4
| | | | | | | | Signed-off-by: tyler-ball <tball@chef.io>
* | knife bootstrap is only knife command to have license acceptance flowtyler-ball2019-05-031-3/+0
| | | | | | | | | | | | | | | | Because in order to run `chef-client` on the bootstrapped node the user needs to have accepted the licenses locally. Right now we have commented out this code because we will enforce it in a different PR. Signed-off-by: tyler-ball <tball@chef.io>
* | Adding in the license-acceptance flowtyler-ball2019-05-032-0/+6
|/ | | | | | | | | This adds a new feature to chef-client where users must accept the EULA before using the product. Users can accept the license by passing '--chef-license accept', setting ENV[CHEF_LICENSE]=accept or by running 'chef-client' and following the interactive prompt. Signed-off-by: tyler-ball <tball@chef.io>
* Update specs for the new messagesTim Smith2019-05-021-1/+1
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Update more help descriptionsTim Smith2019-05-026-17/+18
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Fix a description I missedTim Smith2019-05-021-1/+1
| | | | Signed-off-by: Tim Smith <tsmith@chef.io>
* Fix up main binary help messagesTim Smith2019-05-025-109/+110
| | | | | | | | Periods after each sentence Use the branding better Fix some weird capitalization Signed-off-by: Tim Smith <tsmith@chef.io>