Completing the AWX Operator installation

Hi

I’ve followed the excellent and detailed instructions for installing AWX Operator at https://github.com/ansible/awx-operator#basic-install. But the instructions don’t say what to do after the following command returns a URL:

minikube service -n awx awx-demo-service --url

http://192.168.49.2:31287

I want to be able to access AWX by connecting to a URL on this system. Where are the instructions that explain how to do this?

Looking at https://github.com/ansible/awx, I see a link to the Red Hat Tower site. Is that the correct place for AWX getting started information?

Thanks!
tl

You need to configure your cluster to know where to route the traffic coming in via a hostname.

The term you are looking for is “ingress”.

Keep reading the documentation on, there is a link to a demo video just below where you stopped reading. :wink:

Hi

Thanks very much for the reply. I didn’t realize that the demo video contained needed documentation - hm :).

I watched the video and followed along, typing the commands on my system. But things stopped working when I tried to execute these commands, seen in the video:

ldpdd042:/tmp # kubectl get pods -l “app.kubernetes.io/managed-by=awx-operator
NAME READY STATUS RESTARTS AGE
awx-demo-postgres-13-0 1/1 Running 0 23h
awx-demo-task-59869fb77d-vmsw9 4/4 Running 0 23h
awx-demo-web-86644d58d9-ks9xj 3/3 Running 0 23h
ldpdd042:/tmp # kubectl get svc -l “app.kubernetes.io/managed-by=awx-operator
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
awx-demo-postgres-13 ClusterIP None 5432/TCP 23h
awx-demo-service NodePort 10.102.50.41 80:31287/TCP 23h

ldpdd042:/tmp # kubectl iexec awx-demo /bin/bash
error: unknown command “iexec” for “kubectl”

Did you mean this?
exec

ldpdd042:/tmp # kubectl exec awx-demo /bin/bash
kubectl exec [POD] [COMMAND] is DEPRECATED and will be removed in a future version. Use kubectl exec [POD] – [COMMAND] instead.
Error from server (NotFound): pods “awx-demo” not found

ldpdd042:/tmp # awx-manage version
-bash: awx-manage: command not found
ldpdd042:/tmp #

Perhaps the video uses commands that have been replaced in the latest AWX?

Thanks for any thoughts.
tl

I stepped around the video’s kukectl exec step, followed along in the video and was able to get the expected response from the curl command.

I did not, as the video described, deploy a second AWX instance with a NGINX Ingress Controller, because the basic install already seemed to provide this:

ldpdd042:/tmp # minikube service list

---------------|-------------------------------------------------|--------------|---------------------------|

NAMESPACE NAME TARGET PORT URL
awx awx-demo-postgres-13 No node port
awx awx-demo-service http/80 http://192.168.49.2:31287
awx awx-operator-controller-manager-metrics-service No node port
default kubernetes No node port
ingress-nginx ingress-nginx-controller http/80 http://192.168.49.2:30906

https/443 | http://192.168.49.2:32371 |
ingress-nginx | ingress-nginx-controller-admission | No node port | |
kube-system | kube-dns | No node port | |
---------------|-------------------------------------------------|--------------|---------------------------|
ldpdd042:/tmp #

Though this looks good to me, the video’s ‘kubectl get ingresses’ command does not found any:

ldpdd042:/tmp # kubectl get ingresses
No resources found in awx namespace.
ldpdd042:/tmp #

Noticing that the ingress services are in not in the default namespace, I appended the --namespace qualifier, but still didn’t

ldpdd042:/tmp # kubectl get ingresses --namespace ingress-nginx
No resources found in ingress-nginx namespace.
ldpdd042:/tmp #

Thoughts?

Thanks
tl

Hi

Any suggestion on how the instructions in the demo aren’t working in my environment?

Thanks

Hi

Any change to the installation instructions for AWX Operator 2.5.0?

Thanks
tl

are you having problems using operator 2.5? there is nothing special about 2.5 in terms of installation

AWX Team

Not yet. For the previous AWX Operator release, I followed the instructions (including the demo) for installing/configuring AWX Operator, but never got it to work. So I think I’ll start fresh with AWX Operator 2.5.

I just went to https://github.com/ansible/awx-operator, clicked on ‘Basic Install’ as I did before, and now get a 404 File not found error.

we were changing around the links yesterday, should work now https://github.com/ansible/awx-operator/blob/devel/docs/installation/basic-install.md

Hi

Thanks for this information! I followed the steps in https://github.com/ansible/awx-operator/blob/devel/docs/installation/creating-a-minikube-cluster-for-testing.md and then in https://github.com/ansible/awx-operator/blob/devel/docs/installation/basic-install.md; all went well. I then moved on to the demo at https://asciinema.org/a/416946. Everything went great until time 1:51 of the demo. The demo describes use of the command ‘kubectl iexec awx-demo /bin/bash’. This failed on my system:

ldpdd042:/tmp # kubectl iexec awx-demo /bin/bash
error: unknown command “iexec” for “kubectl”

Did you mean this?
exec
ldpdd042:/tmp #

So, I guessed that the latest version of the command was ‘kubectl exec awx-demo – /bin/bash’, but this didn’t execute successfully:

ldpdd042:/tmp # kubectl exec awx-demo – /bin/bash
Error from server (NotFound): pods “awx-demo” not found
ldpdd042:/tmp #

even though the pods to seem to be available:

kubectl get pods -n awx
NAME READY STATUS RESTARTS AGE
awx-demo-postgres-13-0 1/1 Running 0 19m
awx-demo-task-748f66bfc7-bsgtt 4/4 Running 0 18m
awx-demo-web-56b6f8df8c-bxrpc 3/3 Running 0 17m
awx-operator-controller-manager-66c5b94884-m8xzb 2/2 Running 0 23m
ldpdd042:/tmp #

Any thoughts about what could be wrong? I’m trying to get AWX running so I can connect to its GUI.

Thanks!
tl

Can anyone tell me how to install AWX? The demo (which is part of the documentation) is out of date, and I don’t know how to create a working AWX environment. Thanks!

there is importatn part what you miss in commands " -n awx " is definicion of namespace. try kubectl exec -n awx awx-demo – /bin/bash. If you want to use command without -n awx use command " kubectl config set-context --current --namespace=awx" which set current session namespace to awx.

this guide is working for latest release: https://github.com/ansible/awx-operator/blob/devel/docs/installation/basic-install.md
Also there is information about namespace.

best,
Gertz

Dne pátek 11. srpna 2023 v 17:50:03 UTC+2 uživatel terry....@dell.com napsal:

Hi gertz

Thanks for the reply! I see now that I need to always specify the namespace (via ‘-n awx’) in kubectl commands. I was confused by the fact that, in https://github.com/ansible/awx-operator/blob/devel/docs/installation/basic-install.md, some kubectl commands use the option and some don’t.

Working through the demo, I tried your command, but found that it still didn’t work:

ldpdd042:/tmp # kubectl exec -n awx awx-demo – /bin/bash
Error from server (NotFound): pods “awx-demo” not found

even though awx pods are running:

ldpdd042:/tmp # kubectl get pods -n awx
NAME READY STATUS RESTARTS AGE
awx-demo-postgres-13-0 1/1 Running 0 35m
awx-demo-task-6d7b6489d-zrcqx 4/4 Running 0 35m
awx-demo-web-7b96744696-hl4sp 3/3 Running 0 33m
awx-operator-controller-manager-65ddfcbf7d-j4nzf 2/2 Running 0 40m
ldpdd042:/tmp #

I used the suggested contents of awx-demo.yaml:

cat awx-demo.yaml

You used awx-demo. Not awx-demo-task-6d7b6489d-zrcqx

Hi Wei-Yen

Ah, that makes sense, thanks! It’s necessary to add that the ‘task’ pod needs to be used in the ‘kubectl exec’ command to the documentation/demo (please).

But, I’m still not seeing the response shown in the demo (which is 2 years old, so maybe isn’t correct anymore)?

ldpdd042:~ # kubectl exec -n awx awx-demo-task-6d7b6489d-zrcqx – /bin/bash

ldpdd042:~ # awx-manage version

-bash: awx-manage: command not found

ldpdd042:~ #

Thoughts?

Thanks!

tl

Internal Use - Confidential

What is your goal. What are you trying to achieve?

I want to install AWX and use it to manage my team’s Ansible activities via its UI.

Internal Use - Confidential

No I mean why are you executing into containers. There should be no need for that

Oh. I’m just trying to follow the instructions to get a working AWX environment. When I completed the instructions in https://github.com/ansible/awx-operator/blob/devel/docs/installation/basic-install.md, there was no mention of how to USE the AWX environment. So I kept going with the demo, hoping the demo would tell me how to get a working AWX environment.

If there is any easier way to just get a working AWX environment, please tell me what it is.

Thanks

Internal Use - Confidential

Did you create a node port or ingress