Skip to content
Snippets Groups Projects
Commit 2e11c652 authored by Charlotte Hausman's avatar Charlotte Hausman
Browse files

fix single image carta crashing

parent cb53de56
No related branches found
No related tags found
3 merge requests!499Fixing pulling images out of subdirectories for REAL,!498WS-645: Move images out of subdirectories,!497fix single image carta crashing
Pipeline #2856 passed
"""fix single image carta
Revision ID: 01de4f42cf27
Revises: b3667e00ef4a
Create Date: 2021-09-13 11:39:00.808773
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = "01de4f42cf27"
down_revision = "b3667e00ef4a"
branch_labels = None
depends_on = None
script_content = """#!/bin/sh
set -o errexit
export HOME=$TMPDIR
{{#need_data}}
./framework.sh -r .
chmod 770 .
cd rawdata/
../productfetcher{{product_locator}} {{^single_image}}&{{/single_image}}
.{{/need_data}}./carta_envoy {{#need_data}}--parallel{{/need_data}} {{#single_image}}--single -i {{imageName}}{{/single_image}} -d $1 -n $2 -wf $3 -r $4
{{#need_data}}wait{{/need_data}}
"""
old_content = """#!/bin/sh
set -o errexit
export HOME=$TMPDIR
{{#need_data}}
./framework.sh -r .
chmod 770 .
cd rawdata/
../productfetcher{{product_locator}} &
.{{/need_data}}./carta_envoy {{#need_data}}--parallel{{/need_data}} {{#single_image}}--single -i {{imageName}}{{/single_image}} -d $1 -n $2 -wf $3 -r $4
{{#need_data}}wait{{/need_data}}
"""
def upgrade():
op.execute(
f"""
UPDATE workflow_templates
SET content=E'{script_content}' WHERE filename='carta.sh'
"""
)
def downgrade():
op.execute(
f"""
UPDATE workflow_templates
SET content=E'{old_content}' WHERE filename='carta.sh'
"""
)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment