【发布时间】:2021-02-24 18:07:59
【问题描述】:
我目前正在尝试在 debian10 虚拟机上安装 AWX。 我遵循了很多教程,总是说同样的话,但我无法安装 AWX。 似乎 17.0.1 版本仅安装在 Openshift 或 Kubernetes 集群上。 在我这边,我只希望它在本地 docker 上运行(我安装了先决条件:docker-ce,docker-compose via pip3,ansible 2.10 with community-docker collection,...)
通过 ansible-playbook -i inventory install.yml 启动安装时,它会跳过所有 kubernetes 步骤并完成如下:
*TASK [kubernetes : update django super user password] ***************************************************************************************************************************************************************************************
skipping: [localhost]
TASK [kubernetes : Create the default organization if it is needed.] ************************************************************************************************************************************************************************
skipping: [localhost]
TASK [kubernetes : Delete management pod] ***************************************************************************************************************************************************************************************************
skipping: [localhost]
TASK [kubernetes : Scale up deployment] *****************************************************************************************************************************************************************************************************
skipping: [localhost]
PLAY RECAP **********************************************************************************************************************************************************************************************************************************
localhost : ok=2 changed=0 unreachable=0 failed=0 skipped=49 rescued=0 ignored=0*
我在文档中看到了这个东西:
Choose a deployment platform
We currently support running AWX as a containerized application using Docker images deployed to either an OpenShift cluster or a Kubernetes cluster. The remainder of this document will walk you through the process of building the images, and deploying them to either platform.
The installer directory contains an inventory file, and a playbook, install.yml. You'll begin by setting variables in the inventory file according to the platform you wish to use, and then you'll start the image build and deployment process by running the playbook.
In the sections below, you'll find deployment details and instructions for each platform:
OpenShift
Kubernetes
这是否意味着我们不能再使用 ansible 将它安装在本地 docker 上? 感谢您的帮助
[ 编辑 25/02 ] 我更深入地研究了这个问题,发现了一些奇怪的东西。 我通过 git clone (git clone https://github.com/ansible/awx.git) 得到了代码,这是我的 install.yml 文件内容:
---
- name: Build and deploy AWX
hosts: all
roles:
- {role: check_vars}
- {role: kubernetes, when: "openshift_host is defined or kubernetes_context is defined"}
与 local_docker 无关
但是当我在 github 上直接查看最后一个版本的源代码时,我看到的 install.yml 如下:
---
- name: Build and deploy AWX
hosts: all
roles:
- {role: check_vars}
- {role: image_build, when: "dockerhub_base is not defined"}
- {role: image_push, when: "docker_registry is defined and dockerhub_base is not defined"}
- {role: kubernetes, when: "openshift_host is defined or kubernetes_context is defined"}
- {role: local_docker, when: "openshift_host is not defined and kubernetes_context is not defined"}
所以我知道为什么 awx 没有安装,但我不知道为什么我的 git clone 没有检索到“好”代码。
【问题讨论】:
标签: docker ansible debian ansible-awx