| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For details of why we're moving please see:
https://groups.google.com/d/topic/puppet-users/NuspYhMpE5o/discussion
Removed explicit GPL licenses where appropriate
Replaced selected GPL licenses with Apache 2.0
Replaced LICENSE with Apache 2.0
Updated README
|
|
|
|
|
|
|
|
|
|
|
| |
It only had one available method, and the errors incorrectly
specified what it was.
This just defaults to listing all the time, and I've updated
the docs to be correct, too.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
Reviewed-by: Daniel Pittman <daniel@puppetlabs.com>
|
|\
| |
| |
| |
| | |
This joins the two repositories, including full history, into a single run, as
well as landing the interfaces work on the next branch ready for release.
|
| |
| |
| |
| |
| | |
The codebase is now using the new name, faces, uniformly to reference the
objects contained. All tests pass.
|
| |
| |
| |
| |
| |
| |
| |
| | |
This just changes filenames and directories; files are exact copies rather
than having additional modifications to make clearer each step of this
process.
This does leave a currently broken build. :/
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This ports the existing certificate location configuration to be a string
option, and then uses that to change the configuration. This will leak state
between calls, which is somewhat unavoidable, but should at least get the
basic stuff right for the CLI.
We eventually need the CA string to be supported by a stateless internal CA
implementation that allows us to do the right thing overall.
Reviewed-By: Dan Bode <dan@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This extends the CLI pre-parse phase to identify both string *and* global
options out of the Puppet settings/defaults system. This makes the regular
CLI support for setting Puppet configuration globals work as expected.
This moves us along the line of supporting these options more fully.
Reviewed-By: Dan Bode <dan@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| | |
We had a logic failure that didn't pass positional arguments at all, but which
our testing didn't verify. This entirely broke things. Now fixed, and a test
added to ensure we don't bug out further...
Reviewed-By: Pieter van de Bruggen <pieter@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| | |
We didn't correctly handle '--foo=bar' as having supplied an argument during
the pre-parse phase. Now we have a test for it, and a fix in the code.
Reviewed-By: Nick Lewis <nick@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This adds a test to verify that we are correctly removing the action name from
the set of arguments passed to the string action, then cleans up the previous
code so we don't need to mutilate the command line arguments: we can just
extract it from the resultant set of information.
Reviewed-By: Nick Lewis <nick@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
optparse will treat '--foo --bar' as "foo with the argument --bar" when foo
takes a mandatory argument. We need to emulate that behaviour in our
pre-parse of the command line.
Incidentally, fix up a bug in boolean options, and improve our testing.
Reviewed-By: Nick Lewis <nick@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This improves handling of the pre-parse of the command line to be
non-destructive, which cuts down the volume of garbage generated in the
process.
It also improves testing to verify that we get the darn thing right...
Reviewed-By: Pieter van de Bruggen <pieter@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| | |
This provides a solid test of the new code, by migrating the existing strings
to match. This also gives us a chance to determine any weak points in the
code as written.
Reviewed-By: Pieter van de Bruggen <pieter@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| | |
This removes dead code now we have terminus in the base string, and disables
some tests on StringBase app until they can be rewritten.
Reviewed-By: Pieter van de Bruggen <pieter@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| | |
Now we are pushing into production we can eliminate this language, which was a
legacy from the prototype that is no longer relevant globally.
Reviewed-By: Pieter van de Bruggen <pieter@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In order to identify the full set of options we need to know the action that
is being invoked; that actually requires a pre-processing step to identify
that out of the global options.
Notably, our spec is that options can be to the right of their declaration
point, but not to the left: that means that we can now extract the full set of
options, and interact with the standard Puppet option handling code, resulting
in at least vaguely saner behaviour...
Reviewed-By: Pieter van de Bruggen <pieter@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The purpose of this is to adapt the generic option support in our strings to
the command line; we adapt the generic option information to optparse, and
establish our environment early in the process to ensure that we can play nice
with Puppet::Application for the moment.
In the process we ensure that we detect, and report, conflicts in option
naming across the board. Additionally, when an option is declared with
multiple aliases, we insist that either all, or none, of them take an
argument.
To support this we support introspecting options having an optional argument,
as well as documentation and all.
Reviewed-By: Pieter van de Bruggen <pieter@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Earlier in their implementation the String prototype would set global state on
a String object to reflect options set on the command line. As we move
strings away from a CLI-only prototype, this becomes troublesome because we
can easily have, for example, HTTP access to a string, which means load
balancers can really make this confusing.
It also encourages global state pollution, where one invocation can adversely
influence another. A better approach is that we pass options to the string
action invocation directly; this makes the interaction stateless.
Changes required to your code to adapt to the new world:
- action(:foo) do |some, args|
+ action(:foo) do |some, args, options={}|
if options[:whatever] then
Reviewed-By: Pieter van de Bruggen <pieter@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
As per discussion with Luke, versions of an interface are first looked up by
requiring 'puppet/interface/{name}', and secondarily looked up by requiring
'{name}@{version}/puppet/interface/{name}' if the first failed.
A version of `:current` can be used to represent the version living in
'puppet/interface/{name}'.
Paired-With: Nick Lewis
|
| |
| |
| |
| |
| |
| |
| | |
Now that we have settled on the final public name for the API,
"Puppet::String", mass-rename and mass-edit all the files to follow.
Reviewed-By: Randall Hansen <randall@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Specifying a version of `:latest` will find the most recent version of the
named interface installed in your RUBYLIB, and attempt to load that. This is
unlikely to provide a stable dependency in the future, so should be used
sparingly, acknowledging the dangers.
Reviewed-By: Daniel Pittman
|
| |\
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
lib/puppet/interface/certificate.rb
spec/unit/application/interface_base_spec.rb
spec/unit/interface/interface_collection_spec.rb
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Puppet::Interface::interface is now Puppet::Interface::define, also aliased to
Puppet::Interface::[] for convenience.
Paired-With: Nick Lewis
|
| | |
| | |
| | |
| | |
| | |
| | | |
More information about the versioning scheme can be found at http://semver.org.
Paired-With: Nick Lewis
|
| | |
| | |
| | |
| | | |
Reviewed-By: Nick Lewis
|
| | |
| | |
| | |
| | | |
The common tasks of checking the --ca-location argument and becoming a CA process if necessary (that is, acting like a master) have been abstracted into the Application where they belong.
|
| | | |
|
| |/ |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Having an instance variable on class Interface is insufficient for
Interface::Indirector. This also changes the semantics of "Interface.interface"
to handle registration and loading actions, and for "Interface.new" to only
instantiate an Interface. Thus, consumers of the API should typically use
"Interface.interface", unless they have reasons to not want an interface
automatically registered.
Paired-With: Pieter van de Bruggen
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Ruby's namespace mechanism introduced a number of problems, including
incorrect name resolution for common and simple cases. Given that,
we've refactored back to class-level data structures with accessor
methods available.
The current method names are unlikely to be the final UI.
Reviewed-By: Daniel Pittman
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This application is similar in basic functionality to the "agent" application,
but implemented in terms of interfaces. It currently will retrieve facts,
retrieve a catalog, apply the catalog, and submit a report. Options such
as noop and daemonize are still to come.
Reviewed-By: Pieter van de Bruggen
|
| |
| |
| |
| |
| |
| |
| |
| | |
The application classes were having issues loading
the Interface class in certain circumstances because of
load order. This just pushes the loading as late as possible.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| | |
Paired-With: Richard Crowley
|
| |
| |
| |
| |
| |
| |
| | |
The initial merge of this branch hadn't actually been run against the full
suite of specs; a number of specs began failing shortly afterward.
Reviewed-By: Daniel Pittman
|
| |
| |
| |
| | |
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| | |
|
| |
| |
| |
| | |
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
I had broken some usages of plugins by incorrectly
selecting command-line arguments. The fix was
to remove the #main method contained in the
IndirectionBase subclass.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This allows all of the actions to react to the CLI
options.
I've also removed the unnecessary 'name' variables I
was using in various places - they were just the first
of the arguments, and they weren't actually always
names.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| | |
This is mostly in response to feature requests from
Dan.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| | |
Also added a test to hopefully confirm it won't
break again.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| | |
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We now have an indirection_base class along
with interface_base.
I've also added some basic tests for most
of the interfaces.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
They were previously classes, which made a lot of things stupider
than they needed to be.
This will likely involve some porting, but not much.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| | |
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| |
| |
| | |
It got broke when the Indirector base class was extracted.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| | |
We should exit cleanly rather than throw traces.
|
| |
| |
| |
| | |
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previously the app, indirection, and interface names
had to match exactly; now they can be arbitrary by
just defining an overriding 'indirection_name' class
method on the interface.
I also renamed the file_bucket_file classes accordingly.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|
| |
| |
| |
| |
| |
| |
| | |
This isn't 100% - it will probably only work for Yaml and
JSON - but it's a good start.
Signed-off-by: Luke Kanies <luke@puppetlabs.com>
|