foreman_remote_execution 1.3.1 → 1.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.rubocop.yml +16 -0
- data/.rubocop_todo.yml +0 -6
- data/Rakefile +0 -1
- data/app/controllers/api/v2/job_invocations_controller.rb +1 -0
- data/app/controllers/concerns/foreman/controller/parameters/job_template.rb +1 -1
- data/app/controllers/job_templates_controller.rb +1 -1
- data/app/lib/actions/remote_execution/run_host_job.rb +3 -1
- data/app/models/concerns/foreman_remote_execution/foreman_tasks_cleaner_extensions.rb +37 -0
- data/app/models/concerns/foreman_remote_execution/foreman_tasks_task_extensions.rb +1 -1
- data/app/models/concerns/foreman_remote_execution/host_extensions.rb +1 -1
- data/app/models/host_status/execution_status.rb +1 -1
- data/app/models/job_invocation_composer.rb +15 -3
- data/app/models/job_template.rb +1 -1
- data/app/models/setting/remote_execution.rb +1 -1
- data/app/models/targeting.rb +3 -2
- data/app/models/template_input.rb +5 -1
- data/app/views/api/v2/foreign_input_sets/create.json.rabl +1 -1
- data/app/views/api/v2/foreign_input_sets/index.json.rabl +1 -1
- data/app/views/api/v2/foreign_input_sets/main.json.rabl +1 -1
- data/app/views/api/v2/foreign_input_sets/show.json.rabl +1 -1
- data/app/views/api/v2/job_invocations/create.json.rabl +1 -1
- data/app/views/api/v2/job_invocations/index.json.rabl +1 -1
- data/app/views/api/v2/job_invocations/main.json.rabl +2 -2
- data/app/views/api/v2/job_invocations/show.json.rabl +1 -1
- data/app/views/api/v2/job_templates/create.json.rabl +1 -1
- data/app/views/api/v2/job_templates/index.json.rabl +1 -1
- data/app/views/api/v2/job_templates/main.json.rabl +3 -3
- data/app/views/api/v2/job_templates/show.json.rabl +1 -1
- data/app/views/api/v2/job_templates/update.json.rabl +1 -1
- data/app/views/api/v2/remote_execution_features/index.json.rabl +1 -1
- data/app/views/api/v2/remote_execution_features/main.json.rabl +1 -1
- data/app/views/api/v2/remote_execution_features/show.json.rabl +1 -1
- data/app/views/api/v2/template_inputs/create.json.rabl +1 -1
- data/app/views/api/v2/template_inputs/index.json.rabl +1 -1
- data/app/views/api/v2/template_inputs/main.json.rabl +2 -2
- data/app/views/api/v2/template_inputs/show.json.rabl +1 -1
- data/app/views/job_invocations/_form.html.erb +4 -0
- data/app/views/job_invocations/_tab_overview.html.erb +4 -1
- data/app/views/job_templates/_custom_tabs.html.erb +2 -0
- data/db/migrate/20170613101039_add_timeout_to_job_templates_and_job_invocations.rb +6 -0
- data/foreman_remote_execution.gemspec +1 -1
- data/lib/foreman_remote_execution/engine.rb +1 -0
- data/lib/foreman_remote_execution/version.rb +1 -1
- data/locale/de/foreman_remote_execution.po +21 -0
- data/locale/en/foreman_remote_execution.po +21 -0
- data/locale/en_GB/foreman_remote_execution.po +21 -0
- data/locale/es/foreman_remote_execution.po +21 -0
- data/locale/foreman_remote_execution.pot +86 -56
- data/locale/fr/foreman_remote_execution.po +21 -0
- data/locale/ja/foreman_remote_execution.po +21 -0
- data/locale/ko/foreman_remote_execution.po +21 -0
- data/locale/pt_BR/foreman_remote_execution.po +21 -0
- data/locale/ru/foreman_remote_execution.po +21 -0
- data/locale/zh_CN/foreman_remote_execution.po +21 -0
- data/locale/zh_TW/foreman_remote_execution.po +21 -0
- data/test/unit/actions/run_hosts_job_test.rb +1 -1
- data/test/unit/concerns/foreman_tasks_cleaner_extensions_test.rb +20 -0
- data/test/unit/input_template_renderer_test.rb +5 -7
- data/test/unit/job_template_importer_test.rb +6 -6
- metadata +10 -6
@@ -397,6 +397,9 @@ msgstr "Les entrées n'ont pas toutes des valeurs associées. Les entrées deman
|
|
397
397
|
msgid "Override the description format from the template for this invocation only"
|
398
398
|
msgstr "Remplacer le format de description du modèle pour ce lancement uniquement"
|
399
399
|
|
400
|
+
msgid "Override the timeout interval from the template for this invocation only"
|
401
|
+
msgstr ""
|
402
|
+
|
400
403
|
msgid "Overview"
|
401
404
|
msgstr "Vue globale"
|
402
405
|
|
@@ -412,6 +415,9 @@ msgstr "En cours"
|
|
412
415
|
msgid "Perform no more executions after this time"
|
413
416
|
msgstr "Ne pas lancer d'autres exécutions après cette date."
|
414
417
|
|
418
|
+
msgid "Play Ansible roles"
|
419
|
+
msgstr ""
|
420
|
+
|
415
421
|
msgid "Port to use for SSH communication. Default port 22. You may override per host by setting a parameter called remote_execution_ssh_port."
|
416
422
|
msgstr ""
|
417
423
|
|
@@ -645,9 +651,21 @@ msgstr "Ce modèle est utilisé pour générer la description. Les valeurs d'ent
|
|
645
651
|
msgid "This template is used to generate the description.<br/>Input values can be used using the syntax %{package}.<br/>You may also include the job category and template<br/>name using %{job_category} and %{template_name}."
|
646
652
|
msgstr ""
|
647
653
|
|
654
|
+
msgid "Time in seconds from the start on the remote host after which the job should be killed."
|
655
|
+
msgstr ""
|
656
|
+
|
648
657
|
msgid "Time span"
|
649
658
|
msgstr "Durée"
|
650
659
|
|
660
|
+
msgid "Timeout interval"
|
661
|
+
msgstr ""
|
662
|
+
|
663
|
+
msgid "Timeout to kill"
|
664
|
+
msgstr ""
|
665
|
+
|
666
|
+
msgid "Timeout to kill after"
|
667
|
+
msgstr ""
|
668
|
+
|
651
669
|
msgid "Toggle DEBUG"
|
652
670
|
msgstr "Afficher STDOUT"
|
653
671
|
|
@@ -821,6 +839,9 @@ msgstr "lancé"
|
|
821
839
|
msgid "running %{percent}%%"
|
822
840
|
msgstr ""
|
823
841
|
|
842
|
+
msgid "seconds"
|
843
|
+
msgstr ""
|
844
|
+
|
824
845
|
msgid "succeeded"
|
825
846
|
msgstr "réussi"
|
826
847
|
|
@@ -397,6 +397,9 @@ msgstr "必要なすべての入力に値があるとは限りません。値が
|
|
397
397
|
msgid "Override the description format from the template for this invocation only"
|
398
398
|
msgstr "この呼び出しに対してのみテンプレートから説明形式を上書き"
|
399
399
|
|
400
|
+
msgid "Override the timeout interval from the template for this invocation only"
|
401
|
+
msgstr ""
|
402
|
+
|
400
403
|
msgid "Overview"
|
401
404
|
msgstr "概要"
|
402
405
|
|
@@ -412,6 +415,9 @@ msgstr "保留"
|
|
412
415
|
msgid "Perform no more executions after this time"
|
413
416
|
msgstr "これ以降実行しない"
|
414
417
|
|
418
|
+
msgid "Play Ansible roles"
|
419
|
+
msgstr ""
|
420
|
+
|
415
421
|
msgid "Port to use for SSH communication. Default port 22. You may override per host by setting a parameter called remote_execution_ssh_port."
|
416
422
|
msgstr ""
|
417
423
|
|
@@ -645,9 +651,21 @@ msgstr "このテンプレートは説明を生成するために使用されま
|
|
645
651
|
msgid "This template is used to generate the description.<br/>Input values can be used using the syntax %{package}.<br/>You may also include the job category and template<br/>name using %{job_category} and %{template_name}."
|
646
652
|
msgstr ""
|
647
653
|
|
654
|
+
msgid "Time in seconds from the start on the remote host after which the job should be killed."
|
655
|
+
msgstr ""
|
656
|
+
|
648
657
|
msgid "Time span"
|
649
658
|
msgstr "タイムスパン"
|
650
659
|
|
660
|
+
msgid "Timeout interval"
|
661
|
+
msgstr ""
|
662
|
+
|
663
|
+
msgid "Timeout to kill"
|
664
|
+
msgstr ""
|
665
|
+
|
666
|
+
msgid "Timeout to kill after"
|
667
|
+
msgstr ""
|
668
|
+
|
651
669
|
msgid "Toggle DEBUG"
|
652
670
|
msgstr "DEBUG の切り替え"
|
653
671
|
|
@@ -821,6 +839,9 @@ msgstr ""
|
|
821
839
|
msgid "running %{percent}%%"
|
822
840
|
msgstr ""
|
823
841
|
|
842
|
+
msgid "seconds"
|
843
|
+
msgstr ""
|
844
|
+
|
824
845
|
msgid "succeeded"
|
825
846
|
msgstr "成功"
|
826
847
|
|
@@ -396,6 +396,9 @@ msgstr "값이 없는 필수 입력이 있습니다. 누락된 입력: %s"
|
|
396
396
|
msgid "Override the description format from the template for this invocation only"
|
397
397
|
msgstr "이 호출에 대한 템플릿에서만 설명 형식 덮어쓰기"
|
398
398
|
|
399
|
+
msgid "Override the timeout interval from the template for this invocation only"
|
400
|
+
msgstr ""
|
401
|
+
|
399
402
|
msgid "Overview"
|
400
403
|
msgstr "개요"
|
401
404
|
|
@@ -411,6 +414,9 @@ msgstr "보류 중 "
|
|
411
414
|
msgid "Perform no more executions after this time"
|
412
415
|
msgstr "이 시간 이후 더 이상 실행을 수행하지 않음"
|
413
416
|
|
417
|
+
msgid "Play Ansible roles"
|
418
|
+
msgstr ""
|
419
|
+
|
414
420
|
msgid "Port to use for SSH communication. Default port 22. You may override per host by setting a parameter called remote_execution_ssh_port."
|
415
421
|
msgstr ""
|
416
422
|
|
@@ -644,9 +650,21 @@ msgstr "이 템플릿은 설명을 생성하는 데 사용됩니다. %{package}
|
|
644
650
|
msgid "This template is used to generate the description.<br/>Input values can be used using the syntax %{package}.<br/>You may also include the job category and template<br/>name using %{job_category} and %{template_name}."
|
645
651
|
msgstr ""
|
646
652
|
|
653
|
+
msgid "Time in seconds from the start on the remote host after which the job should be killed."
|
654
|
+
msgstr ""
|
655
|
+
|
647
656
|
msgid "Time span"
|
648
657
|
msgstr "기간"
|
649
658
|
|
659
|
+
msgid "Timeout interval"
|
660
|
+
msgstr ""
|
661
|
+
|
662
|
+
msgid "Timeout to kill"
|
663
|
+
msgstr ""
|
664
|
+
|
665
|
+
msgid "Timeout to kill after"
|
666
|
+
msgstr ""
|
667
|
+
|
650
668
|
msgid "Toggle DEBUG"
|
651
669
|
msgstr "DEBUG 토글"
|
652
670
|
|
@@ -820,6 +838,9 @@ msgstr ""
|
|
820
838
|
msgid "running %{percent}%%"
|
821
839
|
msgstr ""
|
822
840
|
|
841
|
+
msgid "seconds"
|
842
|
+
msgstr ""
|
843
|
+
|
823
844
|
msgid "succeeded"
|
824
845
|
msgstr "성공"
|
825
846
|
|
@@ -397,6 +397,9 @@ msgstr "Nem todas as entradas necessárias possuem valores. Entradas ausentes: %
|
|
397
397
|
msgid "Override the description format from the template for this invocation only"
|
398
398
|
msgstr "Substituir o formato de descrição do modelo somente para esta invocação"
|
399
399
|
|
400
|
+
msgid "Override the timeout interval from the template for this invocation only"
|
401
|
+
msgstr ""
|
402
|
+
|
400
403
|
msgid "Overview"
|
401
404
|
msgstr "Visão geral"
|
402
405
|
|
@@ -412,6 +415,9 @@ msgstr "Pendente"
|
|
412
415
|
msgid "Perform no more executions after this time"
|
413
416
|
msgstr "Não desempenhar execuções depois deste período"
|
414
417
|
|
418
|
+
msgid "Play Ansible roles"
|
419
|
+
msgstr ""
|
420
|
+
|
415
421
|
msgid "Port to use for SSH communication. Default port 22. You may override per host by setting a parameter called remote_execution_ssh_port."
|
416
422
|
msgstr ""
|
417
423
|
|
@@ -645,9 +651,21 @@ msgstr "Este modelo é usado para gerar a descrição. Os valores de entrada pod
|
|
645
651
|
msgid "This template is used to generate the description.<br/>Input values can be used using the syntax %{package}.<br/>You may also include the job category and template<br/>name using %{job_category} and %{template_name}."
|
646
652
|
msgstr ""
|
647
653
|
|
654
|
+
msgid "Time in seconds from the start on the remote host after which the job should be killed."
|
655
|
+
msgstr ""
|
656
|
+
|
648
657
|
msgid "Time span"
|
649
658
|
msgstr "Período de tempo"
|
650
659
|
|
660
|
+
msgid "Timeout interval"
|
661
|
+
msgstr ""
|
662
|
+
|
663
|
+
msgid "Timeout to kill"
|
664
|
+
msgstr ""
|
665
|
+
|
666
|
+
msgid "Timeout to kill after"
|
667
|
+
msgstr ""
|
668
|
+
|
651
669
|
msgid "Toggle DEBUG"
|
652
670
|
msgstr "Toggle DEBUG"
|
653
671
|
|
@@ -821,6 +839,9 @@ msgstr ""
|
|
821
839
|
msgid "running %{percent}%%"
|
822
840
|
msgstr ""
|
823
841
|
|
842
|
+
msgid "seconds"
|
843
|
+
msgstr ""
|
844
|
+
|
824
845
|
msgid "succeeded"
|
825
846
|
msgstr "com êxito "
|
826
847
|
|
@@ -402,6 +402,9 @@ msgstr "Отсутствуют значения некоторых обязат
|
|
402
402
|
msgid "Override the description format from the template for this invocation only"
|
403
403
|
msgstr "Переопределить формат описания из шаблона только на время этого вызова"
|
404
404
|
|
405
|
+
msgid "Override the timeout interval from the template for this invocation only"
|
406
|
+
msgstr ""
|
407
|
+
|
405
408
|
msgid "Overview"
|
406
409
|
msgstr "Обзор"
|
407
410
|
|
@@ -417,6 +420,9 @@ msgstr "Ожидание"
|
|
417
420
|
msgid "Perform no more executions after this time"
|
418
421
|
msgstr "Остановить после указанного числа повторений"
|
419
422
|
|
423
|
+
msgid "Play Ansible roles"
|
424
|
+
msgstr ""
|
425
|
+
|
420
426
|
msgid "Port to use for SSH communication. Default port 22. You may override per host by setting a parameter called remote_execution_ssh_port."
|
421
427
|
msgstr ""
|
422
428
|
|
@@ -652,9 +658,21 @@ msgstr "Это шаблон для генерации описания. Для
|
|
652
658
|
msgid "This template is used to generate the description.<br/>Input values can be used using the syntax %{package}.<br/>You may also include the job category and template<br/>name using %{job_category} and %{template_name}."
|
653
659
|
msgstr ""
|
654
660
|
|
661
|
+
msgid "Time in seconds from the start on the remote host after which the job should be killed."
|
662
|
+
msgstr ""
|
663
|
+
|
655
664
|
msgid "Time span"
|
656
665
|
msgstr "Интервал"
|
657
666
|
|
667
|
+
msgid "Timeout interval"
|
668
|
+
msgstr ""
|
669
|
+
|
670
|
+
msgid "Timeout to kill"
|
671
|
+
msgstr ""
|
672
|
+
|
673
|
+
msgid "Timeout to kill after"
|
674
|
+
msgstr ""
|
675
|
+
|
658
676
|
msgid "Toggle DEBUG"
|
659
677
|
msgstr "Показать DEBUG"
|
660
678
|
|
@@ -828,6 +846,9 @@ msgstr "выполняется"
|
|
828
846
|
msgid "running %{percent}%%"
|
829
847
|
msgstr ""
|
830
848
|
|
849
|
+
msgid "seconds"
|
850
|
+
msgstr ""
|
851
|
+
|
831
852
|
msgid "succeeded"
|
832
853
|
msgstr "завершено"
|
833
854
|
|
@@ -397,6 +397,9 @@ msgstr "没有为所有必填输入分配值。缺少输入:%s"
|
|
397
397
|
msgid "Override the description format from the template for this invocation only"
|
398
398
|
msgstr "只为这个调用使用该模板替代描述格式"
|
399
399
|
|
400
|
+
msgid "Override the timeout interval from the template for this invocation only"
|
401
|
+
msgstr ""
|
402
|
+
|
400
403
|
msgid "Overview"
|
401
404
|
msgstr "概览"
|
402
405
|
|
@@ -412,6 +415,9 @@ msgstr "等待处理"
|
|
412
415
|
msgid "Perform no more executions after this time"
|
413
416
|
msgstr "这个时间后不再执行任何操作"
|
414
417
|
|
418
|
+
msgid "Play Ansible roles"
|
419
|
+
msgstr ""
|
420
|
+
|
415
421
|
msgid "Port to use for SSH communication. Default port 22. You may override per host by setting a parameter called remote_execution_ssh_port."
|
416
422
|
msgstr ""
|
417
423
|
|
@@ -645,9 +651,21 @@ msgstr "这个模板是用来生成描述。可和使用句法 %{package} 输入
|
|
645
651
|
msgid "This template is used to generate the description.<br/>Input values can be used using the syntax %{package}.<br/>You may also include the job category and template<br/>name using %{job_category} and %{template_name}."
|
646
652
|
msgstr ""
|
647
653
|
|
654
|
+
msgid "Time in seconds from the start on the remote host after which the job should be killed."
|
655
|
+
msgstr ""
|
656
|
+
|
648
657
|
msgid "Time span"
|
649
658
|
msgstr "时间跨度"
|
650
659
|
|
660
|
+
msgid "Timeout interval"
|
661
|
+
msgstr ""
|
662
|
+
|
663
|
+
msgid "Timeout to kill"
|
664
|
+
msgstr ""
|
665
|
+
|
666
|
+
msgid "Timeout to kill after"
|
667
|
+
msgstr ""
|
668
|
+
|
651
669
|
msgid "Toggle DEBUG"
|
652
670
|
msgstr "切换 DEBUG"
|
653
671
|
|
@@ -821,6 +839,9 @@ msgstr ""
|
|
821
839
|
msgid "running %{percent}%%"
|
822
840
|
msgstr ""
|
823
841
|
|
842
|
+
msgid "seconds"
|
843
|
+
msgstr ""
|
844
|
+
|
824
845
|
msgid "succeeded"
|
825
846
|
msgstr "已成功"
|
826
847
|
|
@@ -397,6 +397,9 @@ msgstr "並不是所需的輸入都有值。缺少的輸入:%s"
|
|
397
397
|
msgid "Override the description format from the template for this invocation only"
|
398
398
|
msgstr "僅為這祈願從範本覆寫描述格式"
|
399
399
|
|
400
|
+
msgid "Override the timeout interval from the template for this invocation only"
|
401
|
+
msgstr ""
|
402
|
+
|
400
403
|
msgid "Overview"
|
401
404
|
msgstr "概覽"
|
402
405
|
|
@@ -412,6 +415,9 @@ msgstr "等待處理中"
|
|
412
415
|
msgid "Perform no more executions after this time"
|
413
416
|
msgstr "此時間之後不再進行任何執行"
|
414
417
|
|
418
|
+
msgid "Play Ansible roles"
|
419
|
+
msgstr ""
|
420
|
+
|
415
421
|
msgid "Port to use for SSH communication. Default port 22. You may override per host by setting a parameter called remote_execution_ssh_port."
|
416
422
|
msgstr ""
|
417
423
|
|
@@ -645,9 +651,21 @@ msgstr "這範本是用來產生描述。輸入值可以使用 %{package} 語法
|
|
645
651
|
msgid "This template is used to generate the description.<br/>Input values can be used using the syntax %{package}.<br/>You may also include the job category and template<br/>name using %{job_category} and %{template_name}."
|
646
652
|
msgstr ""
|
647
653
|
|
654
|
+
msgid "Time in seconds from the start on the remote host after which the job should be killed."
|
655
|
+
msgstr ""
|
656
|
+
|
648
657
|
msgid "Time span"
|
649
658
|
msgstr "時間跨度"
|
650
659
|
|
660
|
+
msgid "Timeout interval"
|
661
|
+
msgstr ""
|
662
|
+
|
663
|
+
msgid "Timeout to kill"
|
664
|
+
msgstr ""
|
665
|
+
|
666
|
+
msgid "Timeout to kill after"
|
667
|
+
msgstr ""
|
668
|
+
|
651
669
|
msgid "Toggle DEBUG"
|
652
670
|
msgstr "切換 DEBUG"
|
653
671
|
|
@@ -821,6 +839,9 @@ msgstr ""
|
|
821
839
|
msgid "running %{percent}%%"
|
822
840
|
msgstr ""
|
823
841
|
|
842
|
+
msgid "seconds"
|
843
|
+
msgstr ""
|
844
|
+
|
824
845
|
msgid "succeeded"
|
825
846
|
msgstr "已成功"
|
826
847
|
|
@@ -44,7 +44,7 @@ module ForemanRemoteExecution
|
|
44
44
|
|
45
45
|
it 'triggers the RunHostJob actions on the resolved hosts in run phase' do
|
46
46
|
planned.expects(:output).returns(:planned_count => 0)
|
47
|
-
planned.expects(:trigger).with
|
47
|
+
planned.expects(:trigger).with { |*args| args[0] == Actions::RemoteExecution::RunHostJob }
|
48
48
|
planned.create_sub_plans
|
49
49
|
end
|
50
50
|
|
@@ -0,0 +1,20 @@
|
|
1
|
+
require 'test_plugin_helper'
|
2
|
+
|
3
|
+
class ForemanRemoteExecutionForemanTasksCleanerExtensionsTest < ActiveSupport::TestCase
|
4
|
+
it 'tries to delete associated job invocations' do
|
5
|
+
job = FactoryGirl.create(:job_invocation, :with_task)
|
6
|
+
ForemanTasks::Cleaner.new(:filter => "id = #{job.task.id}").delete
|
7
|
+
JobInvocation.where(:id => job.id).must_be :empty?
|
8
|
+
end
|
9
|
+
|
10
|
+
it 'removes orphaned job invocations' do
|
11
|
+
job = FactoryGirl.create(:job_invocation, :with_task)
|
12
|
+
JobInvocation.where(:id => job.id).count.must_equal 1
|
13
|
+
job.task.delete
|
14
|
+
job.reload
|
15
|
+
job.task.must_be :nil?
|
16
|
+
job.task_id.wont_be :nil?
|
17
|
+
ForemanTasks::Cleaner.new(:filter => 'id = 1').delete
|
18
|
+
JobInvocation.where(:id => job.id).must_be :empty?
|
19
|
+
end
|
20
|
+
end
|
@@ -147,9 +147,9 @@ class InputTemplateRendererTest < ActiveSupport::TestCase
|
|
147
147
|
end
|
148
148
|
|
149
149
|
let(:package_template) do
|
150
|
-
FactoryGirl.build(:job_template, :name => 'package action', :template =>
|
151
|
-
<%= render_template("command action", "command" => "yum -y \#{ input("action") } \#{ input('package') }") -%>
|
152
|
-
TEMPLATE
|
150
|
+
FactoryGirl.build(:job_template, :name => 'package action', :template => <<-TEMPLATE.strip_heredoc) do |template|
|
151
|
+
<%= render_template("command action", "command" => "yum -y \#{ input("action") } \#{ input('package') }") -%>
|
152
|
+
TEMPLATE
|
153
153
|
template.template_inputs << FactoryGirl.build(:template_input, :name => 'package', :input_type => 'user')
|
154
154
|
template.template_inputs << FactoryGirl.build(:template_input, :name => 'action', :input_type => 'user')
|
155
155
|
template.foreign_input_sets << FactoryGirl.build(:foreign_input_set, :target_template => command_template, :include_all => true, :exclude => 'command')
|
@@ -464,8 +464,7 @@ TEMPLATE
|
|
464
464
|
puppetclass
|
465
465
|
end
|
466
466
|
let(:lookup_key) do
|
467
|
-
|
468
|
-
FactoryGirl.create(lookup_key_factory,
|
467
|
+
FactoryGirl.create(:variable_lookup_key,
|
469
468
|
:key => 'client_key',
|
470
469
|
:puppetclass => puppet_class,
|
471
470
|
:overrides => {"fqdn=#{renderer.host.fqdn}" => 'RSA KEY'})
|
@@ -550,8 +549,7 @@ TEMPLATE
|
|
550
549
|
puppetclass
|
551
550
|
end
|
552
551
|
let(:lookup_key) do
|
553
|
-
|
554
|
-
FactoryGirl.create(lookup_key_factory, :as_smart_class_param,
|
552
|
+
FactoryGirl.create(:puppetclass_lookup_key, :as_smart_class_param,
|
555
553
|
:key => 'version',
|
556
554
|
:puppetclass => puppet_class,
|
557
555
|
:path => 'fqdn',
|
@@ -22,13 +22,13 @@ class JobTemplateImporterTest < ActiveSupport::TestCase
|
|
22
22
|
{ 'name' => 'verbose', 'input_type' => 'user' }
|
23
23
|
]
|
24
24
|
}
|
25
|
-
text = <<-END_TEMPLATE
|
26
|
-
<%#
|
27
|
-
#{YAML.dump(metadata)}
|
28
|
-
%>
|
25
|
+
text = <<-END_TEMPLATE.strip_heredoc
|
26
|
+
<%#
|
27
|
+
#{YAML.dump(metadata)}
|
28
|
+
%>
|
29
29
|
|
30
|
-
service <%= input("service_name") %> restart
|
31
|
-
END_TEMPLATE
|
30
|
+
service <%= input("service_name") %> restart
|
31
|
+
END_TEMPLATE
|
32
32
|
|
33
33
|
JobTemplateImporter.import!(name, text, metadata)
|
34
34
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: foreman_remote_execution
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.3.
|
4
|
+
version: 1.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Foreman Remote Execution team
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-07-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: deface
|
@@ -56,16 +56,16 @@ dependencies:
|
|
56
56
|
name: foreman-tasks
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- - "
|
59
|
+
- - ">="
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: 0.9
|
61
|
+
version: '0.9'
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- - "
|
66
|
+
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: 0.9
|
68
|
+
version: '0.9'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: rubocop
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -181,6 +181,7 @@ files:
|
|
181
181
|
- app/models/concerns/foreman_remote_execution/bookmark_extensions.rb
|
182
182
|
- app/models/concerns/foreman_remote_execution/errors_flattener.rb
|
183
183
|
- app/models/concerns/foreman_remote_execution/exportable.rb
|
184
|
+
- app/models/concerns/foreman_remote_execution/foreman_tasks_cleaner_extensions.rb
|
184
185
|
- app/models/concerns/foreman_remote_execution/foreman_tasks_task_extensions.rb
|
185
186
|
- app/models/concerns/foreman_remote_execution/foreman_tasks_triggering_extensions.rb
|
186
187
|
- app/models/concerns/foreman_remote_execution/host_extensions.rb
|
@@ -313,6 +314,7 @@ files:
|
|
313
314
|
- db/migrate/20160203104056_add_concurrency_options_to_job_invocation.rb
|
314
315
|
- db/migrate/20160926225841_update_template_input_value.rb
|
315
316
|
- db/migrate/20170110145641_add_host_action_button_to_remote_execution_feature.rb
|
317
|
+
- db/migrate/20170613101039_add_timeout_to_job_templates_and_job_invocations.rb
|
316
318
|
- db/seeds.d/60-ssh_proxy_feature.rb
|
317
319
|
- db/seeds.d/70-job_templates.rb
|
318
320
|
- db/seeds.d/90-bookmarks.rb
|
@@ -395,6 +397,7 @@ files:
|
|
395
397
|
- test/test_plugin_helper.rb
|
396
398
|
- test/unit/actions/run_hosts_job_test.rb
|
397
399
|
- test/unit/concerns/exportable_test.rb
|
400
|
+
- test/unit/concerns/foreman_tasks_cleaner_extensions_test.rb
|
398
401
|
- test/unit/concerns/host_extensions_test.rb
|
399
402
|
- test/unit/concerns/nic_extensions_test.rb
|
400
403
|
- test/unit/execution_task_status_mapper_test.rb
|
@@ -445,6 +448,7 @@ test_files:
|
|
445
448
|
- test/test_plugin_helper.rb
|
446
449
|
- test/unit/actions/run_hosts_job_test.rb
|
447
450
|
- test/unit/concerns/exportable_test.rb
|
451
|
+
- test/unit/concerns/foreman_tasks_cleaner_extensions_test.rb
|
448
452
|
- test/unit/concerns/host_extensions_test.rb
|
449
453
|
- test/unit/concerns/nic_extensions_test.rb
|
450
454
|
- test/unit/execution_task_status_mapper_test.rb
|