Commit Graph

163 Commits

Author SHA1 Message Date
Ignasi Barrera 59c1db6bf6 Propagate TimeoutException in awaitCompletion 2012-11-02 16:11:58 +01:00
Ignasi Barrera c6d57446e9 Made install chef gems script portable
Made install chef gems script portable to yum based
distributions.

This was tested with CentOS 5.6 with the apache2 recipe.
Everything works fine except the startup of the apache
server due to an issue in the apache2 recipe. When it creates
the httpd.conf file it does no set the right permissions.
2012-10-08 19:15:36 +02:00
Ignasi Barrera 31683b3f5a Provide the existing validator credentials in context creation
This commit fixes #12.

Now when bootstrapping nodes using Chef, the validator credentials
must be provided in context creation. Since we cannot create validator
clients, having those credentials is a requirement to make the nodes
be able to autoregister to the Chef server during bootstrap.
When using this feature, the following properties must be set:
    ChefProperties.CHEF_VALIDATOR_NAME
    ChefProperties.CHEF_VALIDATOR_CREDENTIAL

Also refactored ChefConstants class into ChefProperties to follow the
new conventions.
2012-10-08 16:17:48 +02:00
Ignasi Barrera 88c65bb816 Updated RunListForGroup to new DataBagItem parser 2012-10-07 17:57:31 +02:00
Ignasi Barrera 416a5f90aa Added 'name' parameter to ChefContext and PrivatChefContext 2012-10-07 17:40:31 +02:00
Ignasi Barrera 3b361b4ed1 Fixed DatabagItem parser for search api.
The search api returns the databag item inside a 'raw_data'
object instead of returning it directly.
With this commit all live tests for the search api are passing
except the searchClients one for hosted and private chef due
to an existing issue in the target platform. Once it is fixed (by
opscode) the live test will pass.
2012-10-01 15:09:36 +02:00
Ignasi Barrera 4852e03237 Deal with index population delay in search api live tests 2012-10-01 14:11:14 +02:00
Ignasi Barrera bc733860a2 Added live test for search api methods 2012-09-30 21:08:59 +02:00
Ignasi Barrera 4c6e48fc47 Added SearchOptions to all search methods
Added a SearchOptions parameter to all search
methods in ChefApi. This way every search can be
customized and limited. Fixes #1.

This is still a WIP until the appropriate live tests
are added.
2012-09-29 16:28:50 +02:00
Ignasi Barrera c82de486dc Deprecate the jclouds.version property
Deprecated the jclouds.version property and used
project.version instead. This way should be easier
to keep in sync with core jclouds versioning.
2012-09-21 12:42:34 +02:00
Adrian Cole 3cb6e25929 bumped to 1.6.0-SNAPSHOT 2012-09-17 01:59:03 -07:00
Adrian Cole 0eaa946348 [maven-release-plugin] prepare for next development iteration 2012-09-15 08:48:33 -07:00
Adrian Cole e72f2789e2 [maven-release-plugin] prepare release jclouds-chef-1.5.0-rc.1 2012-09-15 08:48:32 -07:00
Garrett Eardley 1425e92538 added search query test case 2012-08-31 04:18:00 +01:00
Garrett Eardley 6d1b4f0bbf added node search chefapi 2012-08-30 23:02:32 +01:00
Adrian Cole 727e749296 [maven-release-plugin] prepare for next development iteration 2012-08-17 17:55:08 -07:00
Adrian Cole 9347c265fd [maven-release-plugin] prepare release jclouds-chef-1.5.0-beta.10 2012-08-17 17:55:07 -07:00
Adrian Cole a3053b41e6 updated to jclouds 1.5.0-beta.10 2012-08-17 17:53:33 -07:00
Jeff Gehlbach ef1dc56484 More changes in support of Chef environments
- Add and update constructors for org.jclouds.chef.domain.Node
- Make Node.chefEnvironment nullable
- Add JavaDoc indicating environments apply since Chef 0.10
- Update unit tests
2012-07-25 12:49:43 -07:00
Jeff Gehlbach a75d816ad7 Add support for chef_environment on Node domain object 2012-07-25 12:49:29 -07:00
Ignasi Barrera 0a4362c561 Fixed transient blobStorage build.
Refactored to use LocalAsyncBlobStore to be aligned with:
562f8277d3
2012-07-24 19:07:41 +02:00
Adrian Cole 4113cadb24 changed to group naming conventions and updated runScript syntax 2012-07-16 23:30:00 -04:00
Adrian Cole 4c1f8f8414 switched to new naming conventions 2012-07-15 23:36:15 -07:00
Ignasi Barrera 85ce1bd659 Fixed cookbook upload tests
There was an issue when commiting the sandbox after uploading its
contents. We were sending the is_complete flag as a String when the Chef
Server expected a boolean flag. Fixing the binder fixed the live test.
2012-07-03 16:09:48 +02:00
Ignasi Barrera 20912c9ad4 Enabled base Chef api tests in Private Chef
* Refactored BaseChefClientLiveTest to allow the use of different
  context types such as PrivateChefContext, etc.
* Added delegate methods to PrivateChef*Clients to access the
  Chef*Clients.
* Removed the hardcoded Chef Server version in tests and read it from
 the system properties.
2012-07-02 16:17:05 +02:00
Ignasi Barrera 05481efd71 Do not force the Chef server version 2012-07-02 14:08:40 +02:00
Ignasi Barrera b4b7f5623a Custom chef version also in Private Chef
Configured PrivateChefAsyncClient to read the value of the
X-Chef-Version header from the jclouds.api-version property.
2012-06-29 16:08:30 +02:00
Ignasi Barrera 194cd906ce Fixed provate chef unit tests 2012-06-29 14:03:21 +02:00
Ignasi Barrera b88516fedc Added support for Chef 0.10
In Chef Server 0.10 the way the cookbooks are returned has changed. For
this reason, a couple of domain classes have been added to support this
new model.

Also added a @Provider in the ChefParserModule that will inject the
appropriate parser depending on the jclouds.api-version property set on
the context. This way the ChefAsyncClient method signatures remain
unchanged and the parser used to parse the cookbooks will be choosen at
runtime depending on the version used to create the context.
2012-06-29 13:47:31 +02:00
Ignasi Barrera d743d11934 Allow to modify the X-Chef-Version
Modified the ChefAsyncClient to read the value for the X-Chef-Version
header from the jclouds.api-version property. This way users will have a
way to configure the version of the Chef server they are consuming.
2012-06-28 17:54:28 +02:00
Ignasi Barrera 56fe3069a8 Fixed skipped chef-core live tests
* Refactored client creation tests and their dependencies to avoid
  errors related to context re-creation.
* Added method to ChefAsyncClient to get the contents of a resource
  (like a file in a cookbook) sending the authentication headers.
* Refactored chef-core live tests dependencies to avoid unnecessary test
  skips.
2012-06-28 15:50:55 +02:00
Ignasi Barrera de89539c85 Private key fixes:
* Added bouncycastle dependency in test scope to allow reading the
  private key files.
* Fixed the client name field in the json sent to update a client.
* Added the uploadContent method to the ChefAsyncClient in order to
  add the authentication headers to the upload contents to a sandbox
  request.
2012-06-27 16:33:46 +02:00
Ignasi Barrera ae857b4911 Initial live test fixes:
* Disabled parallel integration test execution to avoid concurrent
  creation of the same node.
* Fixed @Credential binding to bind the contents of the PEM file instead
  of the path.
* Fixed validation identity and credential property loading.
* TestOhaiModule did not use the overriden provider method. Changed
  strategy live tests to check against the current user as set by the
  CurrentUserProvider.
2012-06-27 13:39:07 +02:00
Adrian Cole 250722e9df moved chef to org.jclouds.api/chef; moved opscodeplatform to labs/privatechef,hostedchef; updated to latest jclouds 2012-06-26 13:29:41 -07:00
Adrian Cole 13406f433c update to latest snapshot 2012-04-23 19:15:40 -07:00
Adrian Cole 73c5ff84d9 upgraded to 1.5.0-SNAPSHOT 2012-04-16 11:07:42 -07:00
Adrian Cole 5f8bd736c2 updated to current license headers 2012-04-16 09:42:51 -07:00
Ignasi Barrera 1b059afacd Removed obsolete Javadoc 2011-09-23 18:14:23 +02:00
Ignasi Barrera 338e333bf7 Fixed ChefAsyncClientTest 2011-09-23 17:52:20 +02:00
Ignasi Barrera 96dd74cc67 Refactored create options parsing to be generic 2011-09-23 17:36:06 +02:00
Ignasi Barrera cbaf2a4605 Removed unused binder 2011-09-14 18:21:45 +02:00
Ignasi Barrera 2f11eac636 Minor javadoc change 2011-09-14 18:17:05 +02:00
Ignasi Barrera 5364ec33da Fixed admin parameter binding to the payload 2011-09-14 18:08:58 +02:00
Ignasi Barrera 5154ab2ee8 Refactored create client to be the jclouds way 2011-09-14 16:50:24 +02:00
Ignasi Barrera a9d425489f Added method to create a client with admin rights
This method creates a client with the 'admin' flag set, in an open source
Chef Server.

This does not work in Hosted Chef, since Opscode Platform
security design uses a different approach. By default a client is only
allowed to manage the node it's associated with, and setting this flag
in the POST or PUT request has no effect on the client permissions.
2011-09-09 17:36:58 +02:00
Ignasi Barrera 43669e8a8b Removed unused import 2011-08-24 13:29:40 +02:00
Ignasi Barrera be70cb3f67 Fixed Metadata deserialization
Metadata fields 'dependencies', 'conflicting', 'providing', 'platforms' and 'replacing' are
simple Map<String, String>, where the value is a version constraint like '>= 0.0.0', but not
a Json array.

See https://github.com/opscode/chef/blob/master/chef/lib/chef/cookbook/metadata.rb for more
details about Metadata format.
2011-08-24 13:15:02 +02:00
Chris Custine e2ab6bc791 Added OSGi headers.
Added dummy readme.
2011-05-23 02:30:08 -06:00
Chris Custine e191018c32 Fix broken test jars.
Fix installchefgem script and test.
2011-05-23 01:54:14 -06:00
Chris Custine f5b8186962 Fix AsyncClient test 2011-05-23 01:52:13 -06:00