A playbook works locally but fails in AWX with `couldn't resolve module/action 'community.mysql.mysql_db'`
IntermediateTroubleshootingCloud, AWX, Windows and Molecule
Answer
Likely causes → AWX runs jobs inside an execution environment container, not with your laptop's collections. The EE does not include community.mysql, and the project has no collections/requirements.yml for AWX to install during project sync.
Fix → Choose one of these:
- Add
collections/requirements.ymlto the project. AWX installs it on project sync if collection installs are allowed. - Build a custom EE:
# execution-environment.yml (ansible-builder v3)
version: 3
images:
base_image:
name: quay.io/ansible/awx-ee:latest
dependencies:
galaxy: requirements.yml
python: requirements.txt
system: bindep.txt
ansible-builder build -t registry.internal/acme-ee:1.4.0
Prevent → Test locally with ansible-navigator run --eei registry.internal/acme-ee:1.4.0 so local runs match AWX.
More on Cloud, AWX, Windows and Molecule
`Failed to import the required Python library (botocore and boto3) on web01's Python /usr/bin/python3.`Beginner`[WARNING]: * Failed to parse inventory/aws.yml with auto plugin: inventory source 'inventory/aws.yml' could not be verified by inventory plugin 'amazon.aws.aws_ec2'`IntermediateThe `aws_ec2` inventory parses without errors but returns zero hostsIntermediate`Failed to describe instances: An error occurred (UnauthorizedOperation) when calling the DescribeInstances operation` or `(ExpiredToken)`IntermediateDynamic inventory finds the instances, but every host is `UNREACHABLE`IntermediateUsing the SSM connection plugin fails with `SessionManagerPlugin is not found` or hangs on file transferAdvanced