diff --git a/README.md b/README.md index 4397126..58f21bb 100644 --- a/README.md +++ b/README.md @@ -2,4 +2,6 @@ Repository of workflows for the ISS beamline. -This repository superseded the [old workflows repo](https://github.com/NSLS-II-ISS/iss-workflows) and is meant to be used with the modern Prefect3 deployment. +This repository superseded the +[old workflows repo](https://github.com/NSLS-II-ISS/iss-workflows) and is meant +to be used with the modern Prefect3 deployment. diff --git a/data_validation.py b/data_validation.py index 5d1b697..afdbb8b 100644 --- a/data_validation.py +++ b/data_validation.py @@ -4,11 +4,9 @@ from prefect.blocks.system import Secret from tiled.client import from_profile -BEAMLINE_OR_ENDSTATION = "!!! Set the endstation or beamline_TLA here !!!" - @task(retries=2, retry_delay_seconds=10) -def read_all_streams(uid, beamline_acronym=BEAMLINE_OR_ENDSTATION): +def read_all_streams(uid, beamline_acronym="iss"): logger = get_run_logger() api_key = Secret.load(f"tiled-{beamline_acronym}-api-key", _sync=True).get() tiled_client = from_profile("nsls2", api_key=api_key) @@ -27,5 +25,5 @@ def read_all_streams(uid, beamline_acronym=BEAMLINE_OR_ENDSTATION): @flow(log_prints=True) -def data_validation(uid): - read_all_streams(uid) +def data_validation(uid, beamline_acronym="iss"): + read_all_streams(uid, beamline_acronym=beamline_acronym) diff --git a/pixi.toml b/pixi.toml index 73f5dd0..67fb3cb 100644 --- a/pixi.toml +++ b/pixi.toml @@ -6,6 +6,6 @@ platforms = ["linux-64"] [dependencies] prefect = "3.*" python = "<3.14" -tiled-client = ">=0.2.3" +tiled = ">=0.2.3" prefect-docker = "*" bluesky-tiled-plugins = ">=2" diff --git a/prefect.yaml b/prefect.yaml index a3d8e56..f529e93 100644 --- a/prefect.yaml +++ b/prefect.yaml @@ -1,4 +1,4 @@ -name: prefect-docker-pixi-tiled-tla +name: prefect-docker-pixi-tiled-iss prefect-version: 3.6.10 build: null @@ -9,14 +9,14 @@ pull: - prefect.deployments.steps.set_working_directory: directory: /repo - prefect.deployments.steps.git_clone: - repository: https://github.com/nsls2/nsls2-workflows-template.git + repository: https://github.com/nsls2/iss-workflows.git branch: main deployments: - - name: tla-end-of-run-workflow-docker + - name: iss-end-of-run-workflow-docker version: 0.1.1 tags: - - tla + - iss - main description: Deploy the updated Docker image entrypoint: end_of_run_workflow.py:end_of_run_workflow @@ -26,13 +26,16 @@ deployments: job_variables: env: TILED_SITE_PROFILES: /nsls2/software/etc/tiled/profiles - image: ghcr.io/nsls2/nsls2-workflows-template:main + image: ghcr.io/nsls2/iss-workflows:main image_pull_policy: Always network: slirp4netns volumes: - - /nsls2/data/tla/proposals:/nsls2/data/tla/proposals + - /nsls2/data/iss/proposals:/nsls2/data/iss/proposals + - /nsls2/data3/iss/proposals:/nsls2/data3/iss/proposals + - /nsls2/data/iss/legacy:/nsls2/data/iss/legacy # To be removed after data security work is completed + - /nsls2/data3/iss/legacy:/nsls2/data3/iss/legacy # To be removed after data security work is completed - /nsls2/software/etc/tiled:/nsls2/software/etc/tiled container_create_kwargs: - userns_mode: "keep-id:uid=402xxx,gid=402xxx" # workflow-tla:workflow-tla + userns_mode: "keep-id:uid=402955,gid=402955" # workflow-iss:workflow-iss auto_remove: true - name: tla-work-pool-docker + name: iss-work-pool-docker