mirror of
https://github.com/ansible/awx.git
synced 2026-02-26 07:26:03 -03:30
Add warning message for K8S deployment
Add warning message for K8S deployment
This commit is contained in:
@@ -78,6 +78,10 @@ class AnsibleInventoryLoader(object):
|
|||||||
bargs.extend(['-e', '{0}={1}'.format(key, value)])
|
bargs.extend(['-e', '{0}={1}'.format(key, value)])
|
||||||
ee = get_default_execution_environment()
|
ee = get_default_execution_environment()
|
||||||
|
|
||||||
|
if settings.IS_K8S:
|
||||||
|
logger.warn('This command is not able to run on kubernetes-based deployment. This action should be done using the API.')
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
if ee.credential:
|
if ee.credential:
|
||||||
process = subprocess.run(['podman', 'image', 'exists', ee.image], capture_output=True)
|
process = subprocess.run(['podman', 'image', 'exists', ee.image], capture_output=True)
|
||||||
if process.returncode != 0:
|
if process.returncode != 0:
|
||||||
|
|||||||
Reference in New Issue
Block a user