From 52c331cdc4439444264080f3f3ef36bbf66db1c4 Mon Sep 17 00:00:00 2001 From: Charlotte Hausman <chausman@nrao.edu> Date: Wed, 19 Oct 2022 18:20:58 -0400 Subject: [PATCH] fix image caching submit file to not transfer out to removed directory --- .../submit/99-workspaces-submit.prod.conf | 2 +- docker.properties | 2 +- .../alembic/versions/022dfde2d95f_.py | 22 +++++ .../2c28308c24cd_fix_img_caching_templates.py | 81 +++++++++++++++++++ 4 files changed, 105 insertions(+), 2 deletions(-) create mode 100644 shared/workspaces/alembic/versions/022dfde2d95f_.py create mode 100644 shared/workspaces/alembic/versions/2c28308c24cd_fix_img_caching_templates.py diff --git a/config/htcondor/submit/99-workspaces-submit.prod.conf b/config/htcondor/submit/99-workspaces-submit.prod.conf index bc67fadf7..e41607dfe 100644 --- a/config/htcondor/submit/99-workspaces-submit.prod.conf +++ b/config/htcondor/submit/99-workspaces-submit.prod.conf @@ -6,7 +6,7 @@ use ROLE : Submit PRIVATE_NETWORK_NAME = nrao.edu # Use mcilroy's correct network interface -NETWORK_INTERFACE = 146.88.1.66 +NETWORK_INTERFACE = 146.88.10.66 BIND_ALL_INTERFACES = False # while not in production yet diff --git a/docker.properties b/docker.properties index cc9bb27a3..ae4ec668b 100644 --- a/docker.properties +++ b/docker.properties @@ -24,7 +24,7 @@ edu.nrao.workspaces.CapabilitySettings.externalServiceUrl = http://capability:34 edu.nrao.workspaces.ProcessingSettings.useCasa = false edu.nrao.workspaces.ProcessingSettings.rootDirectory = /lustre/aoc/cluster/pipeline/docker/workspaces/spool edu.nrao.workspaces.ProcessingSettings.scriptLocation = /lustre/aoc/cluster/pipeline/docker/workspaces/sbin -edu.nrao.workspaces.ProcessingSettings.ramInGb = 0.21G +edu.nrao.workspaces.ProcessingSettings.ramInGb = 0.2G edu.nrao.workspaces.ProcessingSettings.CasaVersion.vlass = /home/casa/packages/pipeline/casa-6.1.3-3-pipeline-2021.1.1.32 edu.nrao.archive.workflow.config.CasaVersions.homeForReprocessing = /home/casa/packages/pipeline/current diff --git a/shared/workspaces/alembic/versions/022dfde2d95f_.py b/shared/workspaces/alembic/versions/022dfde2d95f_.py new file mode 100644 index 000000000..7cb8118fa --- /dev/null +++ b/shared/workspaces/alembic/versions/022dfde2d95f_.py @@ -0,0 +1,22 @@ +"""empty message + +Revision ID: 022dfde2d95f +Revises: af13ebf9e040, 2c28308c24cd +Create Date: 2022-10-19 09:36:31.925615 + +""" + + +# revision identifiers, used by Alembic. +revision = '022dfde2d95f' +down_revision = ('af13ebf9e040', '2c28308c24cd') +branch_labels = None +depends_on = None + + +def upgrade(): + pass + + +def downgrade(): + pass diff --git a/shared/workspaces/alembic/versions/2c28308c24cd_fix_img_caching_templates.py b/shared/workspaces/alembic/versions/2c28308c24cd_fix_img_caching_templates.py new file mode 100644 index 000000000..b044c87ea --- /dev/null +++ b/shared/workspaces/alembic/versions/2c28308c24cd_fix_img_caching_templates.py @@ -0,0 +1,81 @@ +"""fix img caching templates + +Revision ID: 2c28308c24cd +Revises: 2b6fb28c98cb +Create Date: 2022-10-19 08:33:38.168474 + +""" +from alembic import op + + +# revision identifiers, used by Alembic. +revision = "2c28308c24cd" +down_revision = "2b6fb28c98cb" +branch_labels = None +depends_on = None + +new_condor = """executable = vlass_image_caching.sh +arguments = {{calibration_name}} {{phase_center}} {{vlass_relative_path}} {{qa_status}} + +output = image_caching.out +error = image_caching.err +log = condor.log + +SBIN_PATH = /lustre/aoc/cluster/pipeline/$ENV(CAPO_PROFILE)/workspaces/sbin +PIMS_PATH = /lustre/aoc/cluster/pipeline/vlass_{{vlass_env}}/workspaces/bin + +should_transfer_files = yes +transfer_input_files = $ENV(HOME)/.ssh/condor_transfer, nraorsync://$(SBIN_PATH)/pycapo, nraorsync://$(PIMS_PATH)/pimscache, nraorsync://$(PIMS_PATH)/cacheImagingProducts.sh + +getenv = True +environment = "CAPO_PATH=/home/casa/capo" +requirements = (VLASS == True) && (HasLustre == True) ++partition = "VLASS" + +queue + +""" + +old_condor = """executable = vlass_image_caching.sh +arguments = {{calibration_name}} {{phase_center}} {{vlass_relative_path}} {{qa_status}} + +output = image_caching.out +error = image_caching.err +log = condor.log + +SBIN_PATH = /lustre/aoc/cluster/pipeline/$ENV(CAPO_PROFILE)/workspaces/sbin +PIMS_PATH = /lustre/aoc/cluster/pipeline/vlass_{{vlass_env}}/workspaces/bin +VLASS_DIR = {{data_location}} +should_transfer_files = yes +transfer_input_files = $ENV(HOME)/.ssh/condor_transfer, nraorsync://$(SBIN_PATH)/pycapo, nraorsync://$(PIMS_PATH)/pimscache, nraorsync://$(PIMS_PATH)/cacheImagingProducts.sh +when_to_transfer_output = ON_EXIT +transfer_output_files = .job.ad +output_destination = nraorsync://$(VLASS_DIR) ++WantIOProxy = True + +getenv = True +environment = "CAPO_PATH=/home/casa/capo" +requirements = (VLASS == True) && (HasLustre == True) ++partition = "VLASS" + +queue + +""" + + +def upgrade(): + op.execute( + f""" + UPDATE workflow_templates + SET content=E'{new_condor}' WHERE filename='vlass_image_caching.condor' + """ + ) + + +def downgrade(): + op.execute( + f""" + UPDATE workflow_templates + SET content=E'{old_condor}' WHERE filename='vlass_image_caching.condor' + """ + ) -- GitLab