foreman-tasks 9.0.0 → 9.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ruby_tests.yml +15 -63
- data/app/services/foreman_tasks/proxy_selector.rb +3 -3
- data/app/views/foreman_tasks/api/recurring_logics/base.json.rabl +1 -1
- data/lib/foreman_tasks/version.rb +1 -1
- data/lib/tasks/gettext.rake +10 -4
- data/locale/foreman_tasks.pot +5 -6
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8322a4e8ba0d11f3c42f280aac381bca0f7dd22acef9d5a8e97f5a423ff21abe
|
4
|
+
data.tar.gz: 3b629102e3cab124cce9ecb13b6c7da68861aa4761eb9269ec62ff548debe114
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a85e944aabed1bec415c23b7997104b1482e902f3f02f38afa054470967476e19e2524a6e0a7d7de2ab34e9b0e8a97c15d830f3063bf8dfffe70efc414356ca5
|
7
|
+
data.tar.gz: 6859b7ae41d57e95481f82d4d5c8716d79f292d4362fda88db5bd930127864c6d39a69e0a353a34e95e09f15518f46dd053e4dae9dd2b67f7f4bbf54641c1e9f
|
@@ -1,68 +1,20 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
DATABASE_CLEANER_ALLOW_REMOTE_DATABASE_URL: true
|
7
|
-
BUNDLE_WITHOUT: "journald:development:console:mysql2:sqlite:libvirt"
|
1
|
+
---
|
2
|
+
name: CI
|
3
|
+
|
4
|
+
on: pull_request
|
5
|
+
|
8
6
|
concurrency:
|
9
|
-
group: ${{ github.
|
7
|
+
group: ${{ github.ref_name }}-${{ github.workflow }}
|
10
8
|
cancel-in-progress: true
|
9
|
+
|
11
10
|
jobs:
|
12
11
|
rubocop:
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
with:
|
19
|
-
ruby-version: 2.7
|
20
|
-
bundler-cache: true
|
21
|
-
- name: Run rubocop
|
22
|
-
run: bundle exec rubocop
|
23
|
-
test_ruby:
|
24
|
-
runs-on: ubuntu-latest
|
12
|
+
name: Rubocop
|
13
|
+
uses: theforeman/actions/.github/workflows/rubocop.yml@v0
|
14
|
+
|
15
|
+
test:
|
16
|
+
name: Ruby
|
25
17
|
needs: rubocop
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
image: postgres:12.1
|
30
|
-
ports: ['5432:5432']
|
31
|
-
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
|
32
|
-
strategy:
|
33
|
-
fail-fast: false
|
34
|
-
matrix:
|
35
|
-
foreman-core-branch: [develop]
|
36
|
-
ruby-version: [2.7]
|
37
|
-
node-version: [12]
|
38
|
-
steps:
|
39
|
-
- run: sudo apt-get update
|
40
|
-
- run: sudo apt-get install build-essential libcurl4-openssl-dev zlib1g-dev libpq-dev
|
41
|
-
- uses: actions/checkout@v2
|
42
|
-
with:
|
43
|
-
repository: theforeman/foreman
|
44
|
-
ref: ${{ matrix.foreman-core-branch }}
|
45
|
-
- uses: actions/checkout@v2
|
46
|
-
with:
|
47
|
-
path: foreman-tasks
|
48
|
-
- name: Setup Plugin in Foreman
|
49
|
-
run: |
|
50
|
-
echo "gem 'foreman-tasks', path: './foreman-tasks'" > bundler.d/foreman-tasks.local.rb
|
51
|
-
echo "gem 'sqlite3'" >> bundler.d/foreman-tasks.local.rb
|
52
|
-
- name: Setup Ruby
|
53
|
-
uses: ruby/setup-ruby@v1
|
54
|
-
with:
|
55
|
-
ruby-version: ${{ matrix.ruby-version }}
|
56
|
-
bundler-cache: true
|
57
|
-
- name: Setup Node
|
58
|
-
uses: actions/setup-node@v1
|
59
|
-
with:
|
60
|
-
node-version: ${{ matrix.node-version }}
|
61
|
-
- name: Prepare test env
|
62
|
-
run: |
|
63
|
-
bundle exec rake db:create
|
64
|
-
bundle exec rake db:migrate
|
65
|
-
- name: Run plugin tests
|
66
|
-
run: |
|
67
|
-
bundle exec rake test:foreman_tasks
|
68
|
-
bundle exec rake test TEST="test/unit/foreman/access_permissions_test.rb"
|
18
|
+
uses: theforeman/actions/.github/workflows/foreman_plugin.yml@v0
|
19
|
+
with:
|
20
|
+
plugin: foreman-tasks
|
@@ -11,12 +11,12 @@ module ForemanTasks
|
|
11
11
|
[:subnet, :fallback, :global]
|
12
12
|
end
|
13
13
|
|
14
|
-
def available_proxies(*_args)
|
14
|
+
def available_proxies(*_args, **_kwargs)
|
15
15
|
raise NotImplementedError
|
16
16
|
end
|
17
17
|
|
18
|
-
def determine_proxy(*args)
|
19
|
-
available_proxies = self.available_proxies(*args)
|
18
|
+
def determine_proxy(*args, **kwargs)
|
19
|
+
available_proxies = self.available_proxies(*args, **kwargs)
|
20
20
|
return :not_defined if available_proxies.empty? || available_proxies.values.all?(&:empty?)
|
21
21
|
proxy = nil
|
22
22
|
|
@@ -6,4 +6,4 @@ attributes :id, :cron_line, :end_time, :iteration, :task_group_id, :state,
|
|
6
6
|
node(:task_count) { |rl| rl.tasks.count }
|
7
7
|
node(:action) { |rl| rl.tasks.first.try(:action) }
|
8
8
|
node(:last_occurence) { |rl| rl.last_task&.started_at }
|
9
|
-
node(:next_occurence) { |rl| rl.next_task&.start_at }
|
9
|
+
node(:next_occurence) { |rl| rl.next_task&.start_at if rl.state == 'active' }
|
data/lib/tasks/gettext.rake
CHANGED
@@ -10,12 +10,18 @@ if gettext_find_task
|
|
10
10
|
storage_file = "#{locale_path}/action_names.rb"
|
11
11
|
puts "writing action translations to: #{storage_file}"
|
12
12
|
|
13
|
+
klasses = Actions::EntryAction
|
14
|
+
.subclasses
|
15
|
+
.uniq
|
16
|
+
.select do |action|
|
17
|
+
src, = Object.const_source_location(action.to_s)
|
18
|
+
src.start_with? @engine.root.to_s
|
19
|
+
end
|
20
|
+
|
13
21
|
File.write storage_file,
|
14
22
|
"# Autogenerated!\n" +
|
15
|
-
|
16
|
-
.
|
17
|
-
.uniq
|
18
|
-
.map { |n| %[_("#{n}")] }
|
23
|
+
klasses
|
24
|
+
.map { |klass| %[_("#{klass.allocate.humanized_name}")] }
|
19
25
|
.sort
|
20
26
|
.join("\n") + "\n"
|
21
27
|
end
|
data/locale/foreman_tasks.pot
CHANGED
@@ -8,8 +8,8 @@ msgid ""
|
|
8
8
|
msgstr ""
|
9
9
|
"Project-Id-Version: foreman_tasks 1.0.0\n"
|
10
10
|
"Report-Msgid-Bugs-To: \n"
|
11
|
-
"POT-Creation-Date: 2023-11-
|
12
|
-
"PO-Revision-Date: 2023-11-
|
11
|
+
"POT-Creation-Date: 2023-11-28 22:09+0100\n"
|
12
|
+
"PO-Revision-Date: 2023-11-28 22:09+0100\n"
|
13
13
|
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
14
14
|
"Language-Team: LANGUAGE <LL@li.org>\n"
|
15
15
|
"Language: \n"
|
@@ -165,8 +165,7 @@ msgstr ""
|
|
165
165
|
#: ../db/seeds.d/30-notification_blueprints.rb:54
|
166
166
|
#: ../lib/foreman_tasks/engine.rb:25 ../lib/foreman_tasks/engine.rb:54
|
167
167
|
#: ../webpack/ForemanTasks/Components/TasksTable/SubTasksPage.js:10
|
168
|
-
#: ../webpack/ForemanTasks/Components/TasksTable/
|
169
|
-
#: ../webpack/ForemanTasks/Components/TasksTable/TasksTablePage.js:150
|
168
|
+
#: ../webpack/ForemanTasks/Components/TasksTable/TasksTablePage.js:151
|
170
169
|
msgid "Tasks"
|
171
170
|
msgstr ""
|
172
171
|
|
@@ -317,11 +316,11 @@ msgstr ""
|
|
317
316
|
msgid "Bulk action"
|
318
317
|
msgstr ""
|
319
318
|
|
320
|
-
#: ../app/lib/actions/bulk_action.rb:
|
319
|
+
#: ../app/lib/actions/bulk_action.rb:62
|
321
320
|
msgid "Empty bulk action"
|
322
321
|
msgstr ""
|
323
322
|
|
324
|
-
#: ../app/lib/actions/bulk_action.rb:
|
323
|
+
#: ../app/lib/actions/bulk_action.rb:64
|
325
324
|
msgid "The targets are of different types"
|
326
325
|
msgstr ""
|
327
326
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: foreman-tasks
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 9.0.
|
4
|
+
version: 9.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ivan Nečas
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-01-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dynflow
|
@@ -613,7 +613,7 @@ homepage: https://github.com/theforeman/foreman-tasks
|
|
613
613
|
licenses:
|
614
614
|
- GPL-3.0
|
615
615
|
metadata: {}
|
616
|
-
post_install_message:
|
616
|
+
post_install_message:
|
617
617
|
rdoc_options: []
|
618
618
|
require_paths:
|
619
619
|
- lib
|
@@ -628,8 +628,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
628
628
|
- !ruby/object:Gem::Version
|
629
629
|
version: '0'
|
630
630
|
requirements: []
|
631
|
-
rubygems_version: 3.
|
632
|
-
signing_key:
|
631
|
+
rubygems_version: 3.3.26
|
632
|
+
signing_key:
|
633
633
|
specification_version: 4
|
634
634
|
summary: Foreman plugin for showing tasks information for resources and users
|
635
635
|
test_files:
|