From 7701bfc18b02bc0a97d94e3c3fd48b4e9af5af98 Mon Sep 17 00:00:00 2001 From: Stephen Benjamin Date: Mon, 2 Mar 2015 12:57:08 +0100 Subject: [PATCH] Use plugin methods for apipie --- lib/foreman_salt/engine.rb | 3 ++- lib/foreman_salt/version.rb | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/foreman_salt/engine.rb b/lib/foreman_salt/engine.rb index 1b7bdf1b..9ae24876 100644 --- a/lib/foreman_salt/engine.rb +++ b/lib/foreman_salt/engine.rb @@ -24,7 +24,6 @@ class Engine < ::Rails::Engine end initializer 'foreman_salt.apipie' do - Apipie.configuration.api_controllers_matcher << "#{ForemanSalt::Engine.root}/app/controllers/foreman_salt/api/v2/*.rb" Apipie.configuration.checksum_path += ['/salt/api/'] end @@ -32,6 +31,8 @@ class Engine < ::Rails::Engine Foreman::Plugin.register :foreman_salt do requires_foreman '>= 1.8' + apipie_documented_controllers ["#{ForemanSalt::Engine.root}/app/controllers/foreman_salt/api/v2/*.rb"] + ## Menus menu :top_menu, :salt_environments, :url_hash => { :controller => :'foreman_salt/salt_environments', :action => :index }, diff --git a/lib/foreman_salt/version.rb b/lib/foreman_salt/version.rb index 72c2a2c6..01fe0be0 100644 --- a/lib/foreman_salt/version.rb +++ b/lib/foreman_salt/version.rb @@ -1,3 +1,3 @@ module ForemanSalt - VERSION = '2.0.0' + VERSION = '2.0.1' end