From 13887340d4dc482d79c87a831e83fdebf2552ddf Mon Sep 17 00:00:00 2001 From: "Petr \"Stone\" Hracek" Date: Mon, 16 Sep 2024 15:17:04 +0200 Subject: [PATCH] Update Dockerfile is needed. We do not need upstream FROM Signed-off-by: Petr "Stone" Hracek --- .github/workflows/build-and-push.yml | 2 +- container_workflow_tool/distgit.py | 6 ++++++ setup.py | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-and-push.yml b/.github/workflows/build-and-push.yml index b34213e..91f7a8f 100644 --- a/.github/workflows/build-and-push.yml +++ b/.github/workflows/build-and-push.yml @@ -20,7 +20,7 @@ jobs: with: dockerfiles: ./Dockerfile.generator image: cwt-generator - tags: latest 1 ${{ github.sha }} 1.5.7 + tags: latest 1 ${{ github.sha }} 1.5.8 - name: Push cwt-generator image to Quay.io id: push-to-quay diff --git a/container_workflow_tool/distgit.py b/container_workflow_tool/distgit.py index 6334806..19318e0 100644 --- a/container_workflow_tool/distgit.py +++ b/container_workflow_tool/distgit.py @@ -74,6 +74,12 @@ def dist_git_merge_changes(self, images, rebase=False): pull_upstr = image.get("pull_upstream", True) repo = self._clone_downstream(component, branch) df_path = os.path.join(component, "Dockerfile") + downstream_from = self.df_handler.get_from_df(df_path) + self.logger.debug(f"Downstream_from: {downstream_from}\n") + from_tag = self.conf.get("from_tag", "latest") + self.df_handler.update_dockerfile( + df_path, from_tag, downstream_from=downstream_from + ) if rebase or not pull_upstr: # It is possible for the git repository to have no changes if repo.is_dirty(): diff --git a/setup.py b/setup.py index f9227e0..f33f494 100755 --- a/setup.py +++ b/setup.py @@ -58,7 +58,7 @@ def get_dir(system_path=None, virtual_path=None): setup( name='container-workflow-tool', - version="1.5.7", + version="1.5.8", description='A python3 tool to make rebuilding images easier by automating several steps of the process.', long_description=long_description, long_description_content_type='text/markdown',