“致命:无法创建'/home/odoo/pyenv'的前导目录:权限被拒绝”

问题描述

我在运行剧本时使用了这个 ansible odoo-role,它有如下任务在 pyenv.yml 文件中安装 PyEnv。 我正在从本地 ansible master 到远程 linux 18.04 节点执行此剧本。

- name: Install PyEnv
  become: true
  become_user: "{{ odoo_role_odoo_user }}"
  git:
    repo: https://github.com/pyenv/pyenv.git
    dest: "/home/{{ odoo_role_odoo_user }}/pyenv"
    update: no

我收到以下错误

[WARNING]: Module remote_tmp /opt/odoo/.ansible/tmp did not exist and was created with a mode of 0700,this may cause issues when running as another user. To avoid this,create the remote_tmp dir with the correct permissions manually
fatal: [remote-server]: Failed! => {"changed": false,"cmd": "/usr/bin/git clone --origin origin https://github.com/pyenv/pyenv.git /home/odoo/pyenv","msg": "fatal: Could not create leading directories of '/home/odoo/pyenv': Permission denied","rc": 128,"stderr": "fatal: Could not create leading directories of '/home/odoo/pyenv': Permission denied\n","stderr_lines": ["fatal: Could not create leading directories of '/home/odoo/pyenv': Permission denied"],"stdout": "","stdout_lines": []}

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)