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

Fixes #15979 - Add API for Ansible roles #26

Closed
wants to merge 1 commit into from

Conversation

xprazak2
Copy link
Contributor

@xprazak2 xprazak2 commented Aug 5, 2016

Needs #25 to work.

@xprazak2 xprazak2 force-pushed the ansible-roles-api branch 2 times, most recently from 2227147 to 03b6cb9 Compare August 26, 2016 06:06
class AnsibleRolesController < ::Api::V2::BaseController
include ::Api::Version2

before_action :find_resource, :only => [:destroy]
Copy link
Member

@dLobatog dLobatog Aug 26, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

show and import missing

@dLobatog
Copy link
Member

@xprazak2 Thanks, see comments inline. This should be easy to merge 😄

@xprazak2
Copy link
Contributor Author

I use find_resource in controller and I added show, import and obsolete actions. Because we cannot do a two step import as in UI, import imports all missing roles from proxy (or Foreman instance if no proxy is given in params), same goes for obsolete.

@imported = @importer.import!
end

api :POST, '/asnible/ansible_roles/obsolete', N_('Obsolete Ansible roles')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo, I'll fix it on merge.

@dLobatog
Copy link
Member

dLobatog commented Sep 1, 2016

Merged as 3a7067d, thanks @xprazak2

@dLobatog dLobatog closed this Sep 1, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants