Awx: fatal: [localhost]: FAILED! => {"changed": false, "msg": "can not use content with a dir as dest"}

Created on 3 Sep 2019  路  10Comments  路  Source: ansible/awx

ISSUE TYPE
  • Bug Report
SUMMARY

During the installation process the script throws the following error:

fatal: [localhost]: FAILED! => {"changed": false, "msg": "can not use content with a dir as dest"}
ENVIRONMENT
  • AWX version: Latest from repo
  • AWX install method: docker on linux
  • Ansible version: 2.8.4-1ppa~bionic
  • Operating System: Ubuntu 18.04
  • Web Browser: Chrome, Firefox
STEPS TO REPRODUCE

Used the latest inventory file template

cd //
git reset --hard HEAD
git pull
cd installer
cp to
ansible-playbook -i inventory install.yml

EXPECTED RESULTS

Succesful install

ACTUAL RESULTS
PLAY [Build and deploy AWX] *************************************************************************************************************************************************************************************************************************************************************************************************

TASK [Gathering Facts] ******************************************************************************************************************************************************************************************************************************************************************************************************
ok: [localhost]

TASK [check_vars : include_tasks] *******************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [check_vars : include_tasks] *******************************************************************************************************************************************************************************************************************************************************************************************
included: /home/ubuntu/awx/installer/roles/check_vars/tasks/check_docker.yml for localhost

TASK [check_vars : postgres_data_dir should be defined] *********************************************************************************************************************************************************************************************************************************************************************
ok: [localhost] => {
    "changed": false,
    "msg": "All assertions passed"
}

TASK [check_vars : host_port should be defined] *****************************************************************************************************************************************************************************************************************************************************************************
ok: [localhost] => {
    "changed": false,
    "msg": "All assertions passed"
}

TASK [image_build : Set global version if not provided] *********************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Verify awx-logos directory exists for official install] *************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Copy logos for inclusion in sdist] **********************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Set sdist file name] ************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : AWX Distribution] ***************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stat distribution file] *********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Clean distribution] *************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Build sdist builder image] ******************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Build AWX distribution using container] *****************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Build AWX distribution locally] *************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Set docker build base path] *****************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Set awx_web image name] *********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Set awx_task image name] ********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Ensure directory exists] ********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage sdist] ********************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Template web Dockerfile] ********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Template task Dockerfile] *******************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage launch_awx] ***************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage launch_awx_task] **********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage nginx.conf] ***************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage supervisor.conf] **********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage supervisor_task.conf] *****************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage settings.py] **************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage requirements] *************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage config watcher] ***********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage Makefile] *****************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage ansible repo] *************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Stage ansible repo key] *********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Build base web image] ***********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Build base task image] **********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Tag task and web images as latest] **********************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_build : Clean docker base directory] ****************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_push : Authenticate with Docker registry if registry password given] ********************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_push : Remove web image] ****************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_push : Remove task image] ***************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_push : Tag and push web image to registry] **********************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_push : Tag and push task image to registry] *********************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [image_push : Set full image path for Registry] ************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : fail] ****************************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : include_tasks] *******************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost] => (item=openshift_auth.yml)
skipping: [localhost] => (item=openshift.yml)

TASK [kubernetes : include_tasks] *******************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost] => (item=kubernetes_auth.yml)
skipping: [localhost] => (item=kubernetes.yml)

TASK [kubernetes : Use kubectl or oc] ***************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : set_fact] ************************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Record deployment size] **********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Set expected post-deployment Replicas value] *************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Delete existing Deployment] ******************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Get Postgres Service Detail] *****************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Template PostgreSQL Deployment (OpenShift)] **************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Deploy and Activate Postgres (OpenShift)] ****************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Template PostgreSQL Deployment (Kubernetes)] *************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Deploy and Activate Postgres (Kubernetes)] ***************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Set postgresql hostname to helm package service (Kubernetes)] ********************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Wait for Postgres to activate] ***************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Set task image name] *************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Set web image name] **************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Render deployment templates] *****************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost] => (item=None)
skipping: [localhost] => (item=None)
skipping: [localhost] => (item=None)
skipping: [localhost]

TASK [kubernetes : Apply Deployment] ****************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Delete any existing management pod] **********************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Template management pod] *********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Create management pod] ***********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Wait for management pod to start] ************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Migrate database] ****************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : Check for Tower Super users] *****************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [kubernetes : create django super user if it does not exist] ***********************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

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]

TASK [local_docker : Export Docker web image if it isnt local and there isnt a registry defined] ****************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [local_docker : Export Docker task image if it isnt local and there isnt a registry defined] ***************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [local_docker : Set docker base path] **********************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [local_docker : Ensure directory exists] *******************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [local_docker : Copy web image to docker execution] ********************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [local_docker : Copy task image to docker execution] *******************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [local_docker : Load web image] ****************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [local_docker : Load task image] ***************************************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [local_docker : Set full image path for local install] *****************************************************************************************************************************************************************************************************************************************************************
skipping: [localhost]

TASK [local_docker : Set DockerHub Image Paths] *****************************************************************************************************************************************************************************************************************************************************************************
ok: [localhost]

TASK [local_docker : Create /tmp/awxcompose directory] **********************************************************************************************************************************************************************************************************************************************************************
ok: [localhost]

TASK [local_docker : Create Docker Compose Configuration] *******************************************************************************************************************************************************************************************************************************************************************
ok: [localhost] => (item=environment.sh)
ok: [localhost] => (item=credentials.py)
ok: [localhost] => (item=docker-compose.yml)

TASK [local_docker : Render SECRET_KEY file] ********************************************************************************************************************************************************************************************************************************************************************************
fatal: [localhost]: FAILED! => {"changed": false, "msg": "can not use content with a dir as dest"}

PLAY RECAP ******************************************************************************************************************************************************************************************************************************************************************************************************************
localhost                  : ok=7    changed=0    unreachable=0    failed=1    skipped=78   rescued=0    ignored=0
ADDITIONAL INFORMATION

Requirements:

  • Ansible version: 2.8.4
  • Docker: Docker.io 18.09.7-0ubuntu1~18.04.4
  • Python Docker: docker-compose 1.24.1
  • Make:
dpkg -l | grep gcc
ii  gcc                               4:7.4.0-1ubuntu2.3                              amd64        GNU C compiler
ii  gcc-5                             5.5.0-12ubuntu1                                 amd64        GNU C compiler
ii  gcc-5-base:amd64                  5.5.0-12ubuntu1                                 amd64        GCC, the GNU Compiler Collection (base package)
ii  gcc-6-base:amd64                  6.5.0-2ubuntu1~18.04                            amd64        GCC, the GNU Compiler Collection (base package)
ii  gcc-7                             7.4.0-1ubuntu1~18.04.1                          amd64        GNU C compiler
ii  gcc-7-base:amd64                  7.4.0-1ubuntu1~18.04.1                          amd64        GCC, the GNU Compiler Collection (base package)
ii  gcc-8-base:amd64                  8.3.0-6ubuntu1~18.04.1                          amd64        GCC, the GNU Compiler Collection (base package)
ii  libgcc-5-dev:amd64                5.5.0-12ubuntu1                                 amd64        GCC support library (development files)
ii  libgcc-7-dev:amd64                7.4.0-1ubuntu1~18.04.1                          amd64        GCC support library (development files)
ii  libgcc1:amd64                     1:8.3.0-6ubuntu1~18.04.1                        amd64        GCC support library
  • GIT: 1:2.17.1-1ubuntu0.4
  • NodeJS: 10.16.3-1nodesource1
  • NPM: 6.9.0
bug

Most helpful comment

fixed it by removing '/tmp/awxcompose'

All 10 comments

Just discovered the cause of this issue. Have been using the standard docker install (docker.io) which comes along with Ubuntu 18.04 (Bionic). After installing Docker from the official site the script executed properly. Please follow these instructions if you encounter the same issue:

https://docs.docker.com/install/linux/docker-ce/ubuntu/

i have the same issue !!

@yasahmed did you try my solution? What docker version are you using?

@itcrowdsource im using Docker version 17.03.1-ce-rc1, build 3476dbf in mac osx host

I have the same problem, i cannot install AWX on Centos 7.

Latest Awx docker images (pulled from git today)
docker-ce installed from docker repository (https://download.docker.com/linux/centos/docker-ce.repo)
Docker version 19.03.3, build a872fc2f86
I've tried to delete all docker-ce packages with yum (and docker-py with pip) and reinstall everything but the error is the same

same here, centos 7, docker ce 19.03.4 9013bf583a

fixed it by removing '/tmp/awxcompose'

it seems like /tmp/awxcompose was created by a previous AWX installation interfered

@nomoresecrets I can confirm that removing '/tmp/awxcompose' is indeed the right solution for this issue.

rm -rf /tmp worked better for me than the preferred solution.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

grahamn-gr picture grahamn-gr  路  3Comments

pebbledavec picture pebbledavec  路  3Comments

gamuniz picture gamuniz  路  3Comments

cs35-owncloud picture cs35-owncloud  路  3Comments

shortsteps picture shortsteps  路  3Comments