diff --git a/actions/utils/copy_template/action.yml b/actions/utils/copy_template/action.yml index 16e13592..f62bf221 100644 --- a/actions/utils/copy_template/action.yml +++ b/actions/utils/copy_template/action.yml @@ -12,5 +12,5 @@ inputs: description: "A string of the base image name for the deployed code location image." runs: using: "docker" - image: "docker://ghcr.io/dagster-io/dagster-cloud-action:dev" + image: "docker://ghcr.io/dagster-io/dagster-cloud-action:debugging" entrypoint: "/copy_template.sh" diff --git a/actions/utils/deploy/action.yml b/actions/utils/deploy/action.yml index 8469dc9b..00fb3acb 100644 --- a/actions/utils/deploy/action.yml +++ b/actions/utils/deploy/action.yml @@ -39,7 +39,7 @@ outputs: description: "The Cloud deployment associated with this branch." runs: using: "docker" - image: "docker://ghcr.io/dagster-io/dagster-cloud-action:dev" + image: "docker://ghcr.io/dagster-io/dagster-cloud-action:debugging" entrypoint: "/deploy.sh" args: - ${{ inputs.pr }} diff --git a/actions/utils/get_branch_deployment/action.yml b/actions/utils/get_branch_deployment/action.yml index f2cd7aeb..36ec7f69 100644 --- a/actions/utils/get_branch_deployment/action.yml +++ b/actions/utils/get_branch_deployment/action.yml @@ -15,5 +15,5 @@ outputs: description: "The Cloud deployment associated with this branch." runs: using: "docker" - image: "docker://ghcr.io/dagster-io/dagster-cloud-action:dev" + image: "docker://ghcr.io/dagster-io/dagster-cloud-action:debugging" entrypoint: "/get_branch_deployment.sh" diff --git a/actions/utils/notify/action.yml b/actions/utils/notify/action.yml index d4d4fe90..e4acb945 100644 --- a/actions/utils/notify/action.yml +++ b/actions/utils/notify/action.yml @@ -30,7 +30,7 @@ inputs: runs: using: "docker" - image: "docker://ghcr.io/dagster-io/dagster-cloud-action:dev" + image: "docker://ghcr.io/dagster-io/dagster-cloud-action:debugging" entrypoint: "/notify.sh" args: - ${{ inputs.pr }} diff --git a/actions/utils/registry_info/action.yml b/actions/utils/registry_info/action.yml index 7df26a1f..d558a47e 100644 --- a/actions/utils/registry_info/action.yml +++ b/actions/utils/registry_info/action.yml @@ -12,5 +12,5 @@ inputs: description: "Alternative to providing organization ID. The URL of your Dagster Cloud organization." runs: using: "docker" - image: "docker://ghcr.io/dagster-io/dagster-cloud-action:dev" + image: "docker://ghcr.io/dagster-io/dagster-cloud-action:debugging" entrypoint: "/registry_info.sh" diff --git a/actions/utils/run/action.yml b/actions/utils/run/action.yml index 92b229ea..3532e82f 100644 --- a/actions/utils/run/action.yml +++ b/actions/utils/run/action.yml @@ -42,7 +42,7 @@ outputs: description: "The ID of the launched run." runs: using: "docker" - image: "docker://ghcr.io/dagster-io/dagster-cloud-action:dev" + image: "docker://ghcr.io/dagster-io/dagster-cloud-action:debugging" entrypoint: "/run.sh" args: - ${{ inputs.pr }} diff --git a/generated/gha/dagster-cloud.pex b/generated/gha/dagster-cloud.pex index 3b633b02..48ca43b7 100755 Binary files a/generated/gha/dagster-cloud.pex and b/generated/gha/dagster-cloud.pex differ diff --git a/gitlab/dbt/serverless-ci-dbt.yml b/gitlab/dbt/serverless-ci-dbt.yml index b91cb190..5fb45077 100644 --- a/gitlab/dbt/serverless-ci-dbt.yml +++ b/gitlab/dbt/serverless-ci-dbt.yml @@ -12,7 +12,7 @@ deploy-branch: stage: deploy rules: - if: $CI_PIPELINE_SOURCE == 'merge_request_event' - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: # first create the branch deployment - export PR_TIMESTAMP=$(git log -1 --format='%cd' --date=unix) @@ -51,7 +51,7 @@ deploy-branch: close_branch: stage: deploy - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging when: manual only: - merge_requests @@ -76,7 +76,7 @@ deploy: stage: deploy rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: # install dbt package - pip install pip --upgrade diff --git a/gitlab/hybrid-ci.yml b/gitlab/hybrid-ci.yml index 7b555f7f..a336509e 100644 --- a/gitlab/hybrid-ci.yml +++ b/gitlab/hybrid-ci.yml @@ -29,7 +29,7 @@ workflow: initialize: stage: setup - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: - export - dagster-cloud ci check --project-dir=$DAGSTER_PROJECT_DIR --dagster-cloud-yaml-path=$DAGSTER_CLOUD_YAML_PATH @@ -75,7 +75,7 @@ deploy-docker: dependencies: - build-image - initialize - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: - dagster-cloud ci set-build-output --image-tag=$IMAGE_TAG - dagster-cloud ci deploy @@ -87,7 +87,7 @@ deploy-docker-branch: dependencies: - build-image - initialize - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: - dagster-cloud ci set-build-output --image-tag=$IMAGE_TAG - dagster-cloud ci deploy @@ -97,7 +97,7 @@ deploy-docker-branch: close-branch: stage: deploy - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging when: manual only: - merge_requests diff --git a/gitlab/serverless-ci.yml b/gitlab/serverless-ci.yml index 20c18781..46d045a0 100644 --- a/gitlab/serverless-ci.yml +++ b/gitlab/serverless-ci.yml @@ -9,7 +9,7 @@ deploy-branch: stage: deploy rules: - if: $CI_PIPELINE_SOURCE == 'merge_request_event' - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: # first create the branch deployment - export PR_TIMESTAMP=$(git log -1 --format='%cd' --date=unix) @@ -37,7 +37,7 @@ deploy-branch: close_branch: stage: deploy - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging when: manual only: - merge_requests @@ -62,6 +62,6 @@ deploy: stage: deploy rules: - if: $CI_COMMIT_BRANCH == $CI_DEFAULT_BRANCH - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: - /gitlab_action/deploy.py ./dagster_cloud.yaml diff --git a/gitlab/serverless-legacy-ci.yml b/gitlab/serverless-legacy-ci.yml index db127142..46f51707 100644 --- a/gitlab/serverless-legacy-ci.yml +++ b/gitlab/serverless-legacy-ci.yml @@ -10,7 +10,7 @@ workflow: parse-workspace: stage: setup - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: - python /gitlab_action/parse_workspace.py dagster_cloud.yaml >> build.env - cp /Dockerfile.template . @@ -23,7 +23,7 @@ parse-workspace: fetch-registry-info: stage: setup - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: dagster-cloud serverless registry-info --url $DAGSTER_CLOUD_URL/prod --api-token $DAGSTER_CLOUD_API_TOKEN | grep '=' >> registry.env artifacts: reports: @@ -53,7 +53,7 @@ deploy-docker: - build-image - parse-workspace - fetch-registry-info - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: - dagster-cloud workspace add-location --url $DAGSTER_CLOUD_URL/prod @@ -74,7 +74,7 @@ deploy-docker-branch: - build-image - parse-workspace - fetch-registry-info - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging script: - export PR_TIMESTAMP=$(git log -1 --format='%cd' --date=unix) - export PR_MESSAGE=$(git log -1 --format='%s') @@ -109,7 +109,7 @@ deploy-docker-branch: close_branch: stage: deploy - image: ghcr.io/dagster-io/dagster-cloud-action:dev + image: ghcr.io/dagster-io/dagster-cloud-action:debugging when: manual only: - merge_requests diff --git a/scripts/release.py b/scripts/release.py index bd6ff1e4..f3652e11 100755 --- a/scripts/release.py +++ b/scripts/release.py @@ -86,7 +86,9 @@ def build_docker_action(version_tag: str, publish_docker_action: bool = True): print(output) -@app.command(help="Build dagster-cloud.pex - invoked by the dagster-cloud-pex-builder image") +@app.command( + help="Build dagster-cloud.pex - invoked by the dagster-cloud-pex-builder image" +) def build_dagster_cloud_pex( dagster_oss_branch: Optional[str] = DAGSTER_OSS_BRANCH_OPTION, dagster_oss_version: Optional[str] = DAGSTER_OSS_VERSION_OPTION, @@ -117,7 +119,9 @@ def build_dagster_cloud_pex( "aarch64_312.json", # ubuntu-24.04-arm action runner "manylinux_2_28_x86_64.json", # used by the distributed Dockerfile }: - with open(os.path.join(os.path.dirname(__file__), "complete_platforms", json_file)) as f: + with open( + os.path.join(os.path.dirname(__file__), "complete_platforms", json_file) + ) as f: complete_platform = f.read() complete_platform_args.append(f"--complete-platform={complete_platform}") @@ -132,6 +136,7 @@ def build_dagster_cloud_pex( dagster_shared_pkg, "PyGithub", "pex>=2.1.132,<3", + "pip", "-o=dagster-cloud.pex", *complete_platform_args, "--pip-version=23.0", @@ -157,7 +162,9 @@ def update_dagster_cloud_pex( dagster_oss_version: Optional[str] = DAGSTER_OSS_VERSION_OPTION, ): # Map /generated on the docker image to our local generated folder - map_folders = {"/generated": os.path.join(os.path.dirname(__file__), "..", "generated")} + map_folders = { + "/generated": os.path.join(os.path.dirname(__file__), "..", "generated") + } env_args = [] if dagster_oss_branch: @@ -168,7 +175,9 @@ def update_dagster_cloud_pex( mount_args = [] for target_folder, source_folder in map_folders.items(): - mount_args.extend(["--mount", f"type=bind,source={source_folder},target={target_folder}"]) + mount_args.extend( + ["--mount", f"type=bind,source={source_folder},target={target_folder}"] + ) cmd = [ "docker", @@ -242,7 +251,9 @@ def create_rc( def ensure_clean_workdir(): - proc = subprocess.run(["git", "status", "--porcelain"], capture_output=True, check=False) + proc = subprocess.run( + ["git", "status", "--porcelain"], capture_output=True, check=False + ) if proc.stdout or proc.stderr: error("ERROR: Git working directory not clean:") error((proc.stdout + proc.stderr).decode("utf-8")) diff --git a/src/Dockerfile b/src/Dockerfile index a9a047da..29452ad3 100644 --- a/src/Dockerfile +++ b/src/Dockerfile @@ -6,10 +6,10 @@ RUN yum update -y & yum install -y git RUN /opt/python/cp311-cp311/bin/python -m pip install pex # RUN /opt/python/cp38-cp38/bin/python -m pip install dagster-cloud-cli -RUN /opt/python/cp39-cp39/bin/python -m pip install dagster-cloud-cli -RUN /opt/python/cp310-cp310/bin/python -m pip install dagster-cloud-cli -RUN /opt/python/cp311-cp311/bin/python -m pip install dagster-cloud-cli -RUN /opt/python/cp312-cp312/bin/python -m pip install dagster-cloud-cli +# RUN /opt/python/cp39-cp39/bin/python -m pip install dagster-cloud-cli +# RUN /opt/python/cp310-cp310/bin/python -m pip install dagster-cloud-cli +# RUN /opt/python/cp311-cp311/bin/python -m pip install dagster-cloud-cli +RUN /opt/python/cp312-cp312/bin/python -m pip install git+https://github.com/dagster-io/dagster.git@al/09-08-temp-pin#subdirectory=python_modules/libraries/dagster-cloud-cli # Create virtual environment using PEX COPY generated/gha/dagster-cloud.pex /dagster-cloud.pex @@ -45,4 +45,4 @@ COPY src/get_branch_deployment.sh /get_branch_deployment.sh COPY src/gitlab_action gitlab_action # Use the venv python as the command -CMD venv-dagster-cloud/bin/python3 \ No newline at end of file +CMD venv-dagster-cloud/bin/python3