| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We have historically had the preferred contribution process on the
Redmine wiki, however this is not obvious to people that don't already
know it is there. By adding this document to the repository itself,
it becomes much easier for new contributors to find what the preferred
contribution methods are.
By having the preferred contribution method in the repository also
means that it becomes a "curated" document, which must go through the
same submission/review process that other changes to the repositories
go through.
Reviewed-by: Nick Fagerlund <nick.fagerlund@puppetlabs.com>
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
| | |/ /
| |/| |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
vcsrepo is available in a module of its own, is missing tests, and
goes against the long-term goal of moving "extra" types out of core
puppet into modules (an example of this is the nagios types).
This reverts commit 25b967559dfa39eb094008c7a3952c4ee885530b, reversing
changes made to b87a1dea704ed981f2f0af728afac2c63e87b5a8.
Reviewed-by: Michael Stahnke <mike@puppetlabs.com>
|
| | | |
| | | |
| | | |
| | | | |
Signed-off-by: Michael Stahnke <stahnma@puppetlabs.com>
|
|\ \ \ \
| | | | |
| | | | | |
(#8814) Update fqdn_rand for ruby 1.9.2 rand bug.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Ruby 1.9.2 does not accept a string for rand function, so rand('1')
fails even though this works in Ruby 1.8.x and the string is implicitly
converted to a number. We added to_i to avoid this bug.
|
|\ \ \ \ \
| | | | | |
| | | | | | |
(#5606) Print Augeas' /augeas//error info to debug on save failure
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
When saving fails, the contents of /augeas//error (for put_failed) are printed
to the debug log. Should help users track down the issue without needing to
replicate it with augtool.
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Raise a failure when Augeas changes cannot be saved (due to invalid layout of
the tree, permissions etc). Fixes a regression.
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
FileSetting#to_resource had a provision to not attempt to manage files in /dev,
which effectively stopped spec from trying to make their configuration
directories in /dev/null. However, on Windows, the path turns into something
like C:/dev/null, so the specs were still trying to manage their configuration
directories when this wasn't desired or handled by the spec.
Now, we also exclude management of C:/dev (or similar), to mimic the behavior
on Windows. Because this isn't a standard path (and thus will not be used for
anything else), there seems to be no harm in treating it as though it were
really /dev.
Reviewed-By: Josh Cooper <josh@puppetlabs.com>
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
ChaseMotorman/feature/master/8272-windows_service_support
(#8272) Add missing tests for Windows service provider methods.
|
|/ / / / / /
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Added missing spec tests for Windows service provider methods:
:stop, :enable, :disable, and :manual_start
Refactored to match Nick's previous work.
Reviewed By: Nick Lewis [nick@puppetlabs.com]
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | | |
(#8408/8409) Windows user and group providers
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
This provider, windows_adsi, uses the Puppet::Util::ADSI module to manage
groups. It can only manage group existence and memberships, but is fully
functional in those regards.
Based on work by: Joel Rosario <joel.r@.internal.directi.com>
Based on work by: Cameron Thomas <cameron@puppetlabs.com>
Reviewed-By: Matt Robinson <matt@puppetlabs.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
This provider, windows_adsi, uses the Puppet::Util::ADSI module to manage
users. It can currently only manage group memberships, comments, and home
directories, which are the only fields that can be managed via ADSI.
Based on work by: Joel Rosario <joel.r@.internal.directi.com>
Based on work by: Cameron Thomas <cameron@puppetlabs.com>
Reviewed-By: Matt Robinson <matt@puppetlabs.com>
|
|/ / / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
This module (Puppet::Util::ADSI) provides access to Active Directory Services
Interfaces, using win32ole. The base module has methods for generating resource
URIs and connecting to ADSI.
It also provides classes Puppet::Util::ADSI::User and Puppet::Util::ADSI::Group
for managing Active Directory users and groups, along with their properties and
group memberships. This will be used to implement the Windows ADSI user and
group providers.
Based on work by: Joel Rosario <joel.r@.internal.directi.com>
Based on work by: Cameron Thomas <cameron@puppetlabs.com>
Reviewed-By: Matt Robinson <matt@puppetlabs.com>
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* ticket/master/8663-windows-spec-tests:
(#8663) Exclude exec timeout test on Windows
|
|/ / / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The exec provider is not yet supported for Windows and this test relies
on /bin/sleep. And due to #8410 it attempts to execute the program named
"sleep 1", with variations of "sleep 1".bat, etc. This test needs to be
reworked for Windows when the exec provider is implemented.
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* ticket/master/8663-windows-spec-tests:
(#8663) Exclude git rev-parse HEAD spec test on Windows
|
|/ / / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
When running spec/integration/parser/compiler_spec.rb, the git command
passed to Puppet::Util.execute is an array containing a single string
["git rev-parse HEAD"]. On Unix, it calls Kernel.exec(*command), but on
Windows it calls Process.create(:command_line =>command), which attempts
to execute the program called "git rev-parse HEAD" and fails:
CreateProcess() failed: The system cannot find the file specified.
This commit marks the test as fails_on_windows, and will be re-enabled
when #8410 is fixed.
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
|\| | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
We have historically had the preferred contribution process on the
Redmine wiki, however this is not obvious to people that don't already
know it is there. By adding this document to the repository itself,
it becomes much easier for new contributors to find what the preferred
contribution methods are.
By having the preferred contribution method in the repository also
means that it becomes a "curated" document, which must go through the
same submission/review process that other changes to the repositories
go through.
Reviewed-by: Nick Fagerlund <nick.fagerlund@puppetlabs.com>
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
| |\ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* file-test-on-windows:
Check for the appropriate permissions in File type tests on Windows
Remove :fails_on_windows from file type tests that no longer fail on Windows
Disable file bucket diffing tests on Windows
Always put a slash between the checksum and path in filebucket URLs
Treat Windows absolute paths as absolute paths
Consolidate test logic determining if a registered file is in the temp directory
Clarify logic and error messages when initializing Puppet::FileBucket::File
Disable symlink related file tests on Windows
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Ruby's interface to the permissions on Windows does not map well to
the *nix concept of User, Group, and Other. On Windows directories
don't get the execute bit, and Ruby cannot manage group, and other via
the standard chmod interfaces.
Because of this, we no longer check that the execute bit is set on
Windows, and use a permission set that will show differences if we
fail to set the permissions on Windows.
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
With the previous changes to the file bucket and the handling of what
is considered an absolute path, enough pieces have slid into place
that the file type is now mostly working on Windows.
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
The diffing ability of the file bucket is purely master functionality,
and not supported on Windows.
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Since absolute paths on Windows do not always start with /, we need to
make sure that there is always a slash between the checksum and the
path, or the drive letter will end up being considered as part of the
checksum.
On systems where absolute paths always start with /, the extra slash
is removed by the parsing done to the constructed URL.
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Previously, we only considered files that matched the *nix concept of
'absolute' as being absolute paths. Since absolute paths on Windows
look more like URLs with this world-view, we need to specifically look
for the Windows absolute paths, and treat them as such.
We will still treat *nix absolute paths as absolute on Windows, even
though they are actually relative to the "current" drive. We do not
currently limit which "style" of absolute path is allowed based on
what the agent is.
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Previously, we were always using string comparisons, and hard-coded
paths to temp locations on non-Windows platforms. This was
problematic for a few reasons. We had to maintain a list of temp
locations for the various platforms, and the string comparisons were
unreliable on Windows, since paths have two string representations
(the "short" name containing a ~ followed by a number, and the "full"
name).
By getting the current temp location using Dir.tempdir (the same
mechanism our temp creation code uses), we no longer need to maintain
the list of temp locations. Also, rather than doing string
comparisons on file paths, we can use a combination of
Pathname#ascend, and File.identical? to determine if the path
registered as a temp file for deletion was actually created in the
temp location.
With this refactoring, the same code now works for both Windows, and
non-Windows platforms.
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Rather than stating the logic as 'if !thing', the two checks done when
initializing a new Puppet::FileBucket::File are now phrased as 'unless
thing', which should lessen the likelihood of overlooking the '!'.
We also now provide a reason for the ArgumentError being raised, which
should help users of Puppet::FileBucket::File quickly figure out what
is the problem when these exceptions are raised.
In addition to updating the tests to look for these new error
messages, we update the existing tests to specify which type of
exception, and what message it should have, when something is raised.
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
| |/ / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
While Windows filesystems typically have support for symlinks (NTFS),
there are no immediate plans to support symlinks on Windows.
Reviewed-by: Nick Lewis <nick@puppetlabs.com>
|
| |\ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* ticket/master/8644-host-provider:
(#8644) Host provider on Windows
|
| |/ / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The host provider did not work on Windows because it didn't know where
to find its hosts file. The provider now uses Win32::Resolv, which is
part of the standard ruby library, to find it.
Several host type/provider spec tests were marked as fails_on_windows,
but now that the provider is working, I removed the tag from those
tests, and verified that the tests now pass. There are two tests in
resources_spec that fail because the user and exec providers are not
supported on Windows yet, so those tests are marked as fails_on_windows.
Reviewed-by: Pieter van de Bruggen <pieter@puppetlabs.com>
|
| |\ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* ticket/master/8660-default-windows-install-paths:
(#8660) Fix destdir option on Windows
(#8660) Default config dir to %PROGRAMDATA% on Windows
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Specifying the --destdir option failed on windows because the install
script attempted to concatenate two absolute paths together. On Unix,
this is fine, but on Windows, it fails because the colon (part of the
drive specifier) is not a valid filename character. This commit adds a
method to join two paths, stripping off the drive specifier, if
present.
Also fixed a minor bug, which caused a deprecation warning to always
be printed when the --destdir option is omitted, which is the default
case.
Reviewed-by: Cameron Thomas <cameron@puppetlabs.com>
|
| |/ / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The puppet install.rb script now defaults the config directory to
%PROGRAMDATA%\PuppetLabs\puppet\etc on Windows. This is more inline
with Windows best-practices, as this directory is used to store
application data across all users. The PROGRAMDATA environment
variable also takes into account alternate system drives, by using the
SYSTEMDRIVE environment variable.
Note that the Dir::COMMON_APPDATA constant is so named because it
corresponds to the CSIDL_COMMON_APPDATA constant, which on 2000, XP,
and 2003 is %ALLUSERSPROFILE%\Application Data, and on Vista, Win7 and
2008 is %SYSTEMDRIVE%\ProgramData.
This commit also updates puppet's default run_mode var and conf
directories when running as "root" to match the install script, and
fixes the spec test, which was looking in the Dir::WINDOWS directory.
Reviewed-by: Cameron Thomas <cameron@puppetlabs.com>
|
| |\ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* ticket/master/8663-windows-spec-tests:
(#8663) Disable spec tests for unsupported functionality on Windows
|
| |/ / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
The mount, shell, and ssh_authorized_key types are not supported on
Windows, so these spec tests have been disabled when running on
Windows.
One of the compiler spec tests fails on Windows because
Puppet::Util.execute attempts to execute a program named "git rev-parse
HEAD". This has different semantics than Unix, where the command is
splatted, Kernel.exec(*command). Since this truly is a Windows bug, I
removed the fails_on_windows tag and updated ticket #8410.
Reviewed-by: Jacob Helwig <jacob@puppetlabs.com>
|
| |\ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* ticket/master/8663-windows-spec-tests:
(#8663) Drive letters are not valid absolute paths on Windows
(#8663) Update the run_mode spec test on Windows to match the code
(#8663) The ssh_authorized_key type is not supported on Windows
(#8663) Reenable spec tests on Windows that now pass
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
One of the file spec tests was attempting to use X: as a fully
qualified file path, and the file type was correctly rejecting it,
since it is a relative path. This commit changes the spec test to
expect the file type to raise an exception.
Reviewed-by: Jacob Helwig <jacob@puppetlabs.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
When running as root, the default conf and var directories on Windows
are currently puppet/etc and puppet/var within the windows
directory. Updated the spec tests to match what the code does on
Windows.
Whether or not this is the correct behavior is something that will be
addressed in the future. See #8660.
Reviewed-by: Jacob Helwig <jacob@puppetlabs.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
We are not supporting the ssh_authorized_key type on Windows at this
time, since Windows does not ship with an ssh server (though there are
third-party versions available). As a result these spec tests have
been disabled.
Reviewed-by: Jacob Helwig <jacob@puppetlabs.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
The cacher was causing spec tests to fail due to Time.now not having
millisecond resolution on Windows. Now that usage of the cacher has
been removed from many places, these tests now pass.
Reviewed-by: Jacob Helwig <jacob@puppetlabs.com>
|
| |\ \ \ \ \
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
* ticket/master/8392-disable-master-tests-on-windows:
(#8392) Disable master related tests on Windows
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
The master, and queue applications are not used for agent
functionality and since only agent functionality is supported on
Windows, these tests do not need to run.
Reviewed-by: Josh Cooper <josh@puppetlabs.com>
|
| |\ \ \ \ \ \
| | |/ / / / /
| |/| | | | | |
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Because Windows allows a service to be both running and disabled, we now
support that capability. If a service is explicitly requested to be running and
disabled, we will set it to manual start if necessary, start it, and then
disable it. If the service is requested to be running and enabled, we will now
enable it before attempting to start it (previously, this would simply try to
start it and fail).
The exception to this rule is a service which is disabled, and for which we are
not managing the enable property. In that case, we assume that some other
authority has disabled the service, and respect that, failing to start. Thus,
if the user actually wants a service to be running and disabled, they must
explicitly declare that intent.
Reviewed-By: Jacob Helwig <jacob@puppetlabs.com>
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
These were using fake objects when that's not really necessary, so replace them
with real ones. Additionally, many of these specs were doing the same thing
(like creating a resource), so that has been extracted to the before block.
Reviewed-By: Jacob Helwig <jacob@puppetlabs.com>
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Because the enable property of the service type uses :true and :false as its
valid values, rather than true and false, we need to return :true and :false
from our enabled? method. Otherwise, the property was being synced every time
it was enabled or disabled, regardless of whether it was actually in sync or
not.
Reviewed-By: Jacob Helwig <jacob@puppetlabs.com>
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
We want to use self.debug for logging in the provider, so that log messages are
properly associated with the resource, rather than generically coming from
Puppet.
Also fix the self.instances method to not use an unnecessary extra variable
when collecting.
Reviewed-By: Jacob Helwig <jacob@puppetlabs.com>
|
| |\ \ \ \ \ \
| | |/ / / / /
| |/| | | / /
| | | |_|/ /
| | |/| | |
| | | | | |
| | | | | |
| | | | | | |
* 2.7.x:
Deprecate RestAuthConfig#allowed? in favor of #check_authorization
Fix #6026 - security file should support inline comments
Fix #5010 - Allow leading whitespace in auth.conf
Fix #5777 - rule interpolation broke auth.conf CIDR rules
|