Method: Compliance::API.target_url
- Defined in:
- lib/bundles/inspec-compliance/api.rb
.target_url(config, profile) ⇒ Object
196 197 198 199 200 201 202 203 204 205 206 |
# File 'lib/bundles/inspec-compliance/api.rb', line 196 def self.target_url(config, profile) owner, id, ver = profile_split(profile) return "#{config['server']}/owners/#{owner}/compliance/#{id}/tar" unless is_automate_server?(config) if ver.nil? "#{config['server']}/profiles/#{owner}/#{id}/tar" else "#{config['server']}/profiles/#{owner}/#{id}/version/#{ver}/tar" end end |