summaryrefslogtreecommitdiff
path: root/lib
Commit message (Collapse)AuthorAgeFilesLines
* WIPlcg/resource-sugarLamont Granquist2016-01-053-7/+106
|
* Don't activate cheffish and chef-provisioning until its DSL is usedjk/lazy-activationJohn Keiser2015-12-094-8/+148
|
* Merge pull request #4261 from chef/jdm/missing-varJay Mundrawala2015-12-091-1/+1
|\ | | | | Add missing exception variable
| * Add missing exception variableJay Mundrawala2015-12-091-1/+1
| |
* | Work with cheffish (which has no before_notifications)John Keiser2015-12-091-2/+4
| |
* | immediately_before -> beforeJohn Keiser2015-12-093-30/+30
| |
* | Add immediately_before notificationJohn Keiser2015-12-093-1/+85
|/
* Require what you useJohn Keiser2015-12-081-0/+1
|
* Merge pull request #4236 from chef/jdm/dsc_resource_timeoutThom May2015-12-082-2/+10
|\ | | | | Add timeout attribute to dsc_resource
| * Add timeout attribute to dsc_resourcejdm/dsc_resource_timeoutJay Mundrawala2015-12-032-2/+10
| | | | | | | | | | | | | | | | `dsc_resource` was missing a timeout resource. Some resources, such as `xSQLServerSetup` were taking longer than the default of 10 minuites set by mixlib-shellout. Fixes #4232
* | Merge pull request #4193 from chef/mwrock/packageSalim Alam2015-12-088-28/+500
|\ \ | | | | | | adds support for installer types inno, nsis, wise and installshield to windows_package resource
| * | adds support to installer types inno, nsis, wise and installshield top the ↵Matt Wrock2015-12-078-28/+500
| | | | | | | | | | | | windows_package resource
* | | restore handling of dpkg -s returns codes (w/tests)lcg/dpkg-s-return-codesLamont Granquist2015-12-071-1/+1
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously dpkg -s would allow a 0 or 1 exit status and it wasn't entirely clear why this was so either from the code or the tests. This restores throwing an exception if we are outside of the [0,1] range, and then adds tests for both behaviors: - on old ubuntu/debian we get an exit(0) and output on stdout if the file is not installed - on newer ubuntu/debian we get an exit(1) and output on stderr if the file is not installed Added tests for both those cases, and the case where dpkg -s does some other kind of exitcode barf and we should raise.
* | Merge pull request #4228 from chef/lcg/dpkg-cleanupLamont Granquist2015-12-072-44/+36
|\ \ | | | | | | fix couple of issues in dpkg cleanup
| * | fix comment after moving out of dpkg_packagelcg/dpkg-cleanupLamont Granquist2015-12-031-1/+1
| | |
| * | fix couple of issues in dpkg cleanupLamont Granquist2015-12-022-44/+36
| |/ | | | | | | | | | | | | | | | | | | | | | | this is just code rearrangement, no changes to behavior at all. pushes the source_array and resolved_source_array up into the superclass so that other providers can use it (as it was intended, but that slipped out of the last PR). also renamed it to something a little longer and less likely to clash with variables (which it was already doing). the block comment also refers to an earlier iteration that used coercions, which had to be backed out because of chefspec.
* | Fix resource `super` (broken because of test :focus)jk/fix-resource-superJohn Keiser2015-12-061-1/+12
| |
* | Revert lib/chef/api_client/registration.rb to use API V0 since it doesn't ↵tc/fix-api-client-registrationTyler Cloke2015-12-041-3/+7
|/ | | | support V1.
* Merge pull request #4196 from chef/lcg/dpkg-multipackageLamont Granquist2015-12-025-64/+209
|\ | | | | multipackage dpkg_package and bonus fixes
| * just use extendLamont Granquist2015-12-022-15/+10
| |
| * dpkg multipackage and bonus fixesLamont Granquist2015-12-025-64/+214
| | | | | | | | | | | | | | | | - multipackages dpkg_package - fixes edge conditions in load-current-resource around purging/removing packages that threw errors before - fixes the ability to purge packages that have been removed - adds a lot of functional tests for dpkg_package
* | Make to_hash include properties with defaults (fixes #4127)jk/4127John Keiser2015-12-021-3/+8
| |
* | Converge actions all together instead of in action :x (fixes #4124)jk/4124John Keiser2015-12-021-34/+15
|/
* Bump version to 12.6.0Salim Alam2015-12-011-1/+1
|
* extract declare_resource to a mixin and extend APILamont Granquist2015-12-013-78/+116
| | | | | | | - extract to its own mixin so it can be included without method_missing and the rest of the resources DSL - add ability to inject different run_context - add ability to create_if_missing into the resource_collection
* Add make_child_entry in ChefFS CookbookSubdirMaxime Brugidou2015-11-251-0/+5
| | | | Following a517fa8a we can't call `child` on cookbook subdirs.
* Merge pull request #4153 from matschaffer/patch-1Thom May2015-11-251-1/+1
|\ | | | | Require ShellOut before Knife::SSH definition
| * Require ShellOut before Knife::SSH definitionMat Schaffer2015-11-111-1/+1
| | | | | | | | | | | | | | | | | | I ran into a NameError when trying to run https://github.com/matschaffer/knife-solo/blob/master/test/knife_bootstrap_test.rb#L14 that I think this should fix. My suspicion is that under normal operation shell_out gets required via the application or platform. And prior to moving config into its own project it was being required in chef/config.rb In my tests since I end up loading knife ssh directly without the surrounding application things don't work out. I'll likely just add a line to my test helper for now but wanted to open this for comment or future improvement.
* | add better documentation to this methodLamont Granquist2015-11-241-10/+13
| | | | | | | | | | it violates our dont-violate-the-new-resource policy for a reason, but is likely still buggy if the resource gets reused.
* | Merge pull request #4200 from chef/jdm/dont-print-pscredJay Mundrawala2015-11-242-5/+22
|\ \ | | | | | | Prevent inspect on PsCredential from printing out plain text password
| * | Prevent inspect on PsCredential from printing out plain text passwordjdm/dont-print-pscredJay Mundrawala2015-11-232-5/+22
| | |
* | | Correcting regex for upstart_stateJustin Seubert2015-11-231-3/+3
| | |
* | | DTRT re: identity_fileJeff Blaine2015-11-232-14/+12
| | |
* | | Migrate to --ssh-identity-file instead of --identity-fileJeff Blaine2015-11-232-3/+13
|/ / | | | | | | | | | | | | | | | | | | | | | | Fixes #3434 Introduces --ssh-identity-file which is more like the other SSH arguments (they all begin with --ssh except this one). Behavior is unchanged. Migrates '-i' over with --ssh-identity-file Retains --identity-file with a deprecation statement.
* | dpkg provider cleanupLamont Granquist2015-11-201-60/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - :update and :install are now treated the same way and throw the same exceptions - :remove and :purge don't require the source at all, so don't do any checking on that - fix some convoluted side-effecty logic in load_current_resource - load_current_resource now correctly gets the dpkg state on :remove and :purge when the file does not exist (pretty sure the old logic did not) - fixed the FIXME about using en_US.UTF-8 (the default for shell_out!) - just use shell_out! to throw exceptions - clean up all the specs and remove all the instance vars from the code
* | Merge pull request #4188 from chef/salam/dsc-resource-fixSalim Alam2015-11-201-4/+9
|\ \ | | | | | | Update dsc_resource to use verbose stream output
| * | Update dsc_resource to use verbose stream outputsalam/dsc-resource-fixSalim Alam2015-11-191-4/+9
| | |
* | | Fix typo in commentGreg Karékinian2015-11-201-1/+1
|/ / | | | | | | | | | | s/vlaue/value/ Obvious fix.
* | Use repo_mode to decide whether to treat /users asJohn Keiser2015-11-181-7/+13
| | | | | | | | a list of users or as invites
* | Properly rescue ENOENT on delete and send DataNotFoundErrorJohn Keiser2015-11-181-6/+10
| | | | | | | | so that callers can 404 when deleting a nonexistent path
* | Fix /acls/environments and /acls/environments/x.jsonJohn Keiser2015-11-181-1/+14
| |
* | Support POST /organizations/NAME/association_requests and POST ↵John Keiser2015-11-181-0/+160
| | | | | | | | /organizations/NAME/users
* | WMF 5 RTM and Win 10 Threshold 2 allow the RefreshMode to be enabled.Steven Murawski2015-11-182-5/+40
| |
* | Add reboot notification to dsc_resourceSteven Murawski2015-11-182-32/+49
| |
* | Merge pull request #4158 from donaldguy/patch-1Thom May2015-11-171-2/+1
|\ \ | | | | | | Allow named_run_list to be loaded from config
| * | Allow named_run_list to be loaded from configDonald Guy2015-11-111-2/+1
| |/ | | | | | | | | nil default in application/client.rb shadowed any value from config when executing chef-client (but not chef-shell -z) default in config is set to nil at https://github.com/chef/chef/blob/b0dbe243d469cc36477ba8102b74a8456b6f276d/chef-config/lib/chef-config/config.rb#L363, so otherwise this change is a no-op
* | base package provider fixesLamont Granquist2015-11-174-47/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * removes the mutation of the new_resource.version * adds package_class_supports_arrays for multipackage providers * cleans up the package resource initializer and sets the package_name correctly through the accessor method. By mutating new_resource.version we were destroying the original intent of what the user was requesting. This is a bug that must be fixed. Generally, subclasses will be able to get the correct information they need through either the version argument they were passed in install_package(name, version) instead, or through their `#target_version_array` method. If this breaks anything then those providers need bugfixes as well (since this is a change to an internal API accessible only to subclassing, and there are backwards compatible and correct ways to get the information, this is *not* a SemVer violating change). See the fix I made to the OpenBSD provider to preserve the same semantics, avoid using new_resource.version where it was inappropriate, and make the code more symmetrical where before substantially different looking code in install_package and remove_package had exactly the same ultimate effect. The package_class_supports_arrays 'DSL' for writing multipackage providers coerces the arguments to the virtual methods (e.g. install_package) into arrays, even if the user is only requesting a single package install. This removes most of the `is_a?(Array)` checks from the implementation subclasses. The cleanup of the initializer is similarly necessary so that we can use Chef 12.5 coercions to make the package_name and version arguments accept string, but always be Arrays. This should eliminate the rest of the need to write `is_a?(Array)` code all over the package provider implementations.
* | Restore rspec 3.4 by setting project_source_dirsjk/rspec-3.4John Keiser2015-11-171-0/+1
| | | | | | | | to be the cookbooks (see http://rspec.info/blog/2015/11/rspec-3-4-has-been-released/, Better Failure Source Detection, for more info)
* | Merge pull request #4040 from chef/tm/live_execute_streamingThom May2015-11-126-2/+47
|\ \ | | | | | | Implement live streaming for execute resources
| * | More code reviewtm/live_execute_streamingThom May2015-11-112-10/+3
| | |