Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added automatic inclusion of object kind and api version for create requ... #58

Merged
merged 3 commits into from
Apr 7, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions lib/kubeclient/common.rb
Original file line number Diff line number Diff line change
Expand Up @@ -136,6 +136,11 @@ def create_entity(entity_type, entity_config)
# to_hash should be called because of issue #9 in recursive open
# struct
hash = entity_config.to_hash
# TODO: temporary solution to add "kind" and apiVersion to request
# until this issue is solved
# https://github.com/GoogleCloudPlatform/kubernetes/issues/6439
hash['kind'] = entity_type
hash['apiVersion'] = @api_version
handle_exception do
rest_client[get_resource_name(entity_type)].post(hash.to_json)
end
Expand Down