Ansible-playbook: returned non-zero exit status 2 (again)

I see that there’s another question of, I think, the same error. I’m getting:

nicholas $ 
nicholas $ pwd
/home/nicholas/bench
nicholas $ 
nicholas $ wget https://raw.githubusercontent.com/frappe/bench/develop/install.py
--2020-09-22 19:59:20--  https://raw.githubusercontent.com/frappe/bench/develop/install.py
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 151.101.192.133, 151.101.128.133, 151.101.64.133, ...
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|151.101.192.133|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 16341 (16K) [text/plain]
Saving to: ‘install.py’

install.py                       100%[==========================================================>]  15.96K  --.-KB/s    in 0.02s   

2020-09-22 19:59:20 (762 KB/s) - ‘install.py’ saved [16341/16341]

nicholas $ 
nicholas $ python3 install.py --production
Please run this script as a non-root user with sudo privileges
nicholas $ 
nicholas $ sudo python3 install.py --production
[sudo] password for nicholas: 
Logs are saved under /tmp/logs/easy-install__2020-09-23__02-59.log
curl already installed!
wget already installed!
git already installed!
pip3 already installed!
pip3 already installed!
Checking System Compatibility...
ubuntu 20 is compatible!
Bench's CLI needs these to be defined!
Run the following commands in shell: 
export LC_ALL=C.UTF-8
nicholas $ 
nicholas $ export LC_ALL=C.UTF-8
nicholas $ 
nicholas $ sudo python3 install.py --production
Logs are saved under /tmp/logs/easy-install__2020-09-23__03-00.log
curl already installed!
wget already installed!
git already installed!
pip3 already installed!
pip3 already installed!
Checking System Compatibility...
ubuntu 20 is compatible!
Input MySQL and Frappe Administrator passwords:
Passwords saved at ~/passwords.txt
 [WARNING]: Could not find aptitude. Using apt-get instead
Traceback (most recent call last):
  File "install.py", line 472, in <module>
    install_bench(args)
  File "install.py", line 264, in install_bench
    run_playbook('site.yml', sudo=True, extra_vars=extra_vars)
  File "install.py", line 388, in run_playbook
    success = subprocess.check_call(args, cwd=playbooks_folder, stdout=log_stream, stderr=sys.stderr)
  File "/usr/lib/python3.8/subprocess.py", line 364, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['ansible-playbook', '-c', 'local', 'site.yml', '-vvvv', '-e', '@/tmp/extra_vars.json', '--become', '--become-user=frappe']' returned non-zero exit status 2.
nicholas $ 
nicholas $ uname -a
Linux doge 5.4.0-47-generic #51-Ubuntu SMP Fri Sep 4 19:50:52 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux
nicholas $ 
nicholas $ lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 20.04 LTS
Release:	20.04
Codename:	focal
nicholas $ 

but don’t see how to fix the problem.

I also get:

nicholas $ 
nicholas $ ansible-playbook -c local site.yml -vvvv -e @/tmp/extra_vars.json –become –become-user=frappe
ansible-playbook 2.8.5
  config file = /etc/ansible/ansible.cfg
  configured module search path = ['/home/nicholas/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/local/lib/python3.8/dist-packages/ansible
  executable location = /usr/local/bin/ansible-playbook
  python version = 3.8.2 (default, Jul 16 2020, 14:00:26) [GCC 9.3.0]
Using /etc/ansible/ansible.cfg as config file
ERROR! the playbook: site.yml could not be found
nicholas $ 

but already knew that. I’ll look at the logs as well.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.