Project

General

Profile

Actions

Bug #30074

open

Wrong ‘foreign_input_sets -> template’ name on export

Added by Ricar pc almost 4 years ago.

Status:
New
Priority:
Normal
Assignee:
Category:
Plugin integration
Target version:
-
Difficulty:
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

Problem:
Hi, exported templates with ‘foreman_template’ plug-in, with foreign inputs, are generated with its own template name instead of the name of foreign template

Expected outcome:

Export with the name of the foreign input template instead of his own.

Foreman and Proxy versions:

1.24.2

Foreman and Proxy plugin versions:

foreman_templates 7.0.6

Distribution and version:

Red Hat Enterprise Linux Server 7.7

Other relevant data:

Example:

bash-4.2$ cat test__foreign_input_test_1.erb
<%#
name: TEST - Foreign input test 1
snippet: false
model: JobTemplate
job_category: gevIT
foreign_input_sets:

include: sample_input
include_all: false
template: TEST - Foreign input test 1 <<<<------- wrong foreign template name, exported with his own template name
provider_type: Ansible
kind: job_template
organizations:
TEST_ORG
locations:
Default Location
%>
name: “TEST”
hosts: all
gather_facts: False
vars:
tasks:
debug: msg=“Host-> <%=@host.shortname%>”

-bash-4.2$ hammer -v import-templates --filter=‘TEST - Foreign input test 1’

Name: TEST - Foreign input test 1
Type: job_template
Imported: false

Errors:
Validation:
1) Base: ERF98-1781 [ForeignInputSet::CircularDependencyError]: Circular dependency detected in foreign input set ‘TEST - Foreign input test 1’ -> ‘TEST - Foreign input test 1’. Templates stack:
2) Foreign_input_sets: is invalid
3) Foreign_input_sets.base: ERF98-1781 [ForeignInputSet::CircularDependencyError]: Circular dependency detected in foreign input set ‘TEST - Foreign input test 1’ -> ‘TEST - Foreign input test 1’. Templates stack:

No data to display

Actions

Also available in: Atom PDF