Skip to content

Commit 7706ca5

Browse files
authored
use Cardinal cluster for Maya jobs instead of Owens (#149)
Use Cardinal cluster for Maya jobs instead of Owens.
1 parent c91172f commit 7706ca5

File tree

3 files changed

+20
-3
lines changed

3 files changed

+20
-3
lines changed

app/models/maya_script.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def cluster
2626
end
2727

2828
def available_versions
29-
['2020', '2022', '2023']
29+
['2025']
3030
end
3131

3232
def job_name

config/configuration_singleton.rb

+2-2
Original file line numberDiff line numberDiff line change
@@ -92,11 +92,11 @@ def sftp_host
9292
end
9393

9494
def submit_cluster
95-
ENV['OOD_FRAME_RENDERER_CLUSTER'] || "owens"
95+
ENV['OOD_FRAME_RENDERER_CLUSTER'] || 'cardinal'
9696
end
9797

9898
def cores
99-
(ENV['OOD_FRAME_RENDERER_CORES'] || 28).to_i
99+
(ENV['OOD_FRAME_RENDERER_CORES'] || 48).to_i
100100
end
101101

102102
def maya_script_template
+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# frozen_string_literal: true
2+
3+
# When we migrated from Owens to Cardinal, the only version on
4+
# Cardinal is 2025, so update all the records for the user
5+
# as whatever version they have in the DB won't work.
6+
Rails.application.config.after_initialize do
7+
begin
8+
Script.all.each do |script|
9+
if script.is_a?(MayaScript)
10+
script.version = '2025' if script.version.to_s < '2025'
11+
script.save
12+
end
13+
end
14+
rescue
15+
# nothing to do, no database table exists.
16+
end
17+
end

0 commit comments

Comments
 (0)