Error: [Errno 13] Permission denied: '/home/ansible/.ansible'

Bug #1592268 reported by Christian Berendt
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
kolla
Fix Released
High
Christian Berendt
Liberty
Fix Released
High
Mohammed Salih
Mitaka
Fix Released
High
Mohammed Salih

Bug Description

Running Ansible commands inside the kolla_toolbox is current not possible:

fatal: [de-1-node-3]: FAILED! => {"changed": false, "cmd": ["docker", "exec", "-t", "kolla_toolbox", "/usr/bin/ansible", "localhost", "-m", "find_disks", "-a", "partition_name='KOLLA_CEPH_OSD_BOOTSTRAP' match_mode='prefix'"]
...
[Errno 13] Permission denied: '/home/ansible/.ansible'

I think the issue is caused by the copy of .ansible.cfg to /home/ansible/.ansible.cfg without creating the home directory first. The -m parameter should be added to the useradd command before the COPY command. This way the permissions of /home/ansible inside kolla_toolbox should be fine.

Changed in kolla:
importance: Undecided → High
assignee: nobody → Christian Berendt (berendt)
milestone: none → newton-2
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla (master)

Reviewed: https://review.openstack.org/329274
Committed: https://git.openstack.org/cgit/openstack/kolla/commit/?id=76f97b406735540eb86fb3f293343ed4803c45d7
Submitter: Jenkins
Branch: master

commit 76f97b406735540eb86fb3f293343ed4803c45d7
Author: Christian Berendt <email address hidden>
Date: Tue Jun 14 07:47:22 2016 +0200

    Create ansible home directory in kolla-toolbox container

    This solves the following issue when running an ansible command inside
    the kolla-toolbox container:

    [Errno 13] Permission denied: '/home/ansible/.ansible'

    Change-Id: I654d27c49b7fcc50e018b61146084660894352aa
    Closes-bug: #1592268

Changed in kolla:
status: New → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to kolla (stable/liberty)

Fix proposed to branch: stable/liberty
Review: https://review.openstack.org/334237

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to kolla (stable/mitaka)

Fix proposed to branch: stable/mitaka
Review: https://review.openstack.org/334239

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla (stable/mitaka)

Reviewed: https://review.openstack.org/334239
Committed: https://git.openstack.org/cgit/openstack/kolla/commit/?id=518e14e2943a9a53ed402cdcb080f1b1259944a4
Submitter: Jenkins
Branch: stable/mitaka

commit 518e14e2943a9a53ed402cdcb080f1b1259944a4
Author: Christian Berendt <email address hidden>
Date: Tue Jun 14 07:47:22 2016 +0200

    Create ansible home directory in kolla-toolbox container

    This solves the following issue when running an ansible command inside
    the kolla-toolbox container:

    [Errno 13] Permission denied: '/home/ansible/.ansible'

    Change-Id: I654d27c49b7fcc50e018b61146084660894352aa
    Closes-bug: #1592268
    (cherry picked from commit 76f97b406735540eb86fb3f293343ed4803c45d7)

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla (stable/liberty)

Reviewed: https://review.openstack.org/334237
Committed: https://git.openstack.org/cgit/openstack/kolla/commit/?id=a9a5a01a89511fb10f5f1dd04263413fa9d45ad3
Submitter: Jenkins
Branch: stable/liberty

commit a9a5a01a89511fb10f5f1dd04263413fa9d45ad3
Author: Christian Berendt <email address hidden>
Date: Tue Jun 14 07:47:22 2016 +0200

    Create ansible home directory in kolla-toolbox container

    This solves the following issue when running an ansible command inside
    the kolla-toolbox container:

    [Errno 13] Permission denied: '/home/ansible/.ansible'

    Change-Id: I654d27c49b7fcc50e018b61146084660894352aa
    Closes-bug: #1592268
    (cherry picked from commit 76f97b406735540eb86fb3f293343ed4803c45d7)

Revision history for this message
Doug Hellmann (doug-hellmann) wrote : Fix included in openstack/kolla 3.0.0.0b2

This issue was fixed in the openstack/kolla 3.0.0.0b2 development milestone.

Revision history for this message
Doug Hellmann (doug-hellmann) wrote : Fix included in openstack/kolla 2.0.2

This issue was fixed in the openstack/kolla 2.0.2 release.

Revision history for this message
Davanum Srinivas (DIMS) (dims-v) wrote : Fix included in openstack/kolla 1.1.2

This issue was fixed in the openstack/kolla 1.1.2 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

This issue was fixed in the openstack/kolla 1.1.2 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.