From 902685a0dbaddfc34d162205271d9d74287f781c Mon Sep 17 00:00:00 2001 From: wangruidong <940853815@qq.com> Date: Wed, 10 Jun 2026 10:19:09 +0800 Subject: [PATCH] perf: update image tags for ansible executor in CI workflow and runner script --- .github/workflows/build-jms-ansible-ee.yml | 4 ++-- apps/ops/ansible/runner.py | 6 ++++-- utils/ansible_executor/build.sh | 2 +- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build-jms-ansible-ee.yml b/.github/workflows/build-jms-ansible-ee.yml index 108e157f9..3bd08e122 100644 --- a/.github/workflows/build-jms-ansible-ee.yml +++ b/.github/workflows/build-jms-ansible-ee.yml @@ -71,11 +71,11 @@ jobs: push: true context: utils/ansible_executor/context file: utils/ansible_executor/context/Dockerfile - tags: jumpserver/jms_ansible_ee:${{ env.IMAGE_TAG }} + tags: jumpserver/ansible-executor:${{ env.IMAGE_TAG }} - name: Update runner.py run: | - sed -i "s|ANSIBLE_EE_IMAGE = .*|ANSIBLE_EE_IMAGE = 'jumpserver/jms_ansible_ee:${{ env.IMAGE_TAG }}'|" apps/ops/ansible/runner.py + sed -i "s|ANSIBLE_EE_IMAGE = .*|ANSIBLE_EE_IMAGE = 'jumpserver/ansible-executor:${{ env.IMAGE_TAG }}'|" apps/ops/ansible/runner.py - name: Commit changes run: | diff --git a/apps/ops/ansible/runner.py b/apps/ops/ansible/runner.py index d1f8bc242..44951b657 100644 --- a/apps/ops/ansible/runner.py +++ b/apps/ops/ansible/runner.py @@ -6,14 +6,15 @@ from django.conf import settings from django.utils._os import safe_join from common.utils import is_macos + +from ..utils import get_ansible_log_verbosity from .callback import DefaultCallback from .exception import CommandInBlackListException from .interface import interface -from ..utils import get_ansible_log_verbosity __all__ = ['AdHocRunner', 'PlaybookRunner', 'SuperPlaybookRunner', 'UploadFileRunner'] -ANSIBLE_EE_IMAGE = 'jms_ansible_ee:latest' +ANSIBLE_EE_IMAGE = 'jumpserver/ansible-executor:latest' def use_ansible_docker_isolation(): @@ -228,3 +229,4 @@ class UploadFileRunner: except OSError as e: print(f"del upload tmp dir {self.share_src_dir} failed! {e}") return self.cb + return self.cb diff --git a/utils/ansible_executor/build.sh b/utils/ansible_executor/build.sh index 3a4014ea1..1ac6bb3d7 100755 --- a/utils/ansible_executor/build.sh +++ b/utils/ansible_executor/build.sh @@ -5,7 +5,7 @@ set -euo pipefail SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)" cd "$SCRIPT_DIR" -IMAGE_TAG="${IMAGE_TAG:-jms_ansible_ee:latest}" +IMAGE_TAG="${IMAGE_TAG:-jumpserver/ansible-executor:latest}" EE_FILE="${EE_FILE:-execution-environment.yml}" GITHUB_MIRROR="${GITHUB_MIRROR:-https://ghfast.top/}" USE_CHINA_MIRROR="${USE_CHINA_MIRROR:-1}"