appsembler / configuration

a simple, but flexible, way for anyone to stand up an instance of the edX platform that is fully configured and ready-to-go
GNU Affero General Public License v3.0
15 stars 13 forks source link

customer_specific theme .git directory ownership getting set to root #114

Closed bryanlandia closed 6 years ago

bryanlandia commented 7 years ago

After a successful run of the appsemblerPlaybooks/update_theme.yml playbook, the ownership of the .git directory under the customer_specific theme is getting set to root. The next time I want to use the same playbook, I have to sudo chown -R edxapp:edxapp /edx/var/edxapp/themes/edx-theme-codebase/customer_specific/.git

(ax)[bryancw@appsembler]$ ./ax_provision.sh 
Ansible nginx ssl certificate []: foo
Ansible nginx ssl key []: foo
Ansible playbook: appsemblerPlaybooks/update_theme.yml
Edx release: ficus
DEBUG : Using requested root working directory: /opt/appsembler.
DEBUG : Changing directory to /opt/appsembler/configuration/playbooks
DEBUG : Running command: ansible-playbook --inventory-file="../../edx-configs/isc-cmc-ficus/staging/hosts/inventory" appsemblerPlaybooks/update_theme.yml --vault-password-file /keybase/team/appsembler_black/config-vault-pwds/isc-cmc-staging-vault-pwd --extra-vars "@../../edx-configs/isc-cmc-ficus/staging/files/vault/secrets.yml" --extra-vars "@../../edx-configs/isc-cmc-ficus/staging/files/server-vars.yml" --user bryan -vv --ask-sudo-pass --extra-vars="NGINX_SSL_CERTIFICATE=foo NGINX_SSL_KEY=foo"
SUDO password: Using /opt/appsembler/configuration/playbooks/ansible.cfg as config file
TASK [checkout customer override theme] ****************************************
task path: /opt/appsembler/configuration/playbooks/appsemblerPlaybooks/update_theme.yml:83
fatal: [35.197.221.123]: FAILED! => {"changed": false, "cmd": ["/usr/bin/git", "fetch", "--tags", "origin"], "failed": true, "msg": "Failed to download remote objects and refs:  error: insufficient permission for adding an object to repository database .git/objects\nfatal: failed to write object\nfatal: unpack-objects failed\n"}
    to retry, use: --limit @/opt/appsembler/configuration/playbooks/appsemblerPlaybooks/update_theme.retry

PLAY RECAP *********************************************************************
35.197.221.123             : ok=6    changed=1    unreachable=0    failed=1 
OmarIthawi commented 6 years ago

Should be closed by #120, however this, of course, won't help incorrect manual theme updates.