Getting error running ansible-playbook -i environments/mac/ initdb.yml
Running on a mac
getting red letters with fatal and failed
fatal: [ansible]: FAILED! => {"changed": false, "content": "", "failed": true, "msg": "Status code was not [200, 404]: Request failed:
look below
$ ansible-playbook -i environments/mac/ initdb.yml
PLAY [ansible] *****************************************************************
TASK [setup] *******************************************************************
Friday 10 June 2016 20:48:58 -0400 (0:00:00.014) 0:00:00.014 ***********
ok: [ansible]
TASK [include] *****************************************************************
Friday 10 June 2016 20:48:58 -0400 (0:00:00.578) 0:00:00.592 ***********
included: /Users/csantana23/Documents/dev/whisk/git/openwhisk/ansible/tasks/initdb.yml for ansible
TASK [check if the immortal subjects db with CouchDB exists?] ******************
Friday 10 June 2016 20:48:58 -0400 (0:00:00.043) 0:00:00.636 ***********
fatal: [ansible]: FAILED! => {"changed": false, "content": "", "failed": true, "msg": "Status code was not [200, 404]: Request failed: <urlopen error timed out>", "redirected": false, "status": -1, "url": "http://172.17.0.1:5984/subjects"}
PLAY RECAP *********************************************************************
ansible : ok=2 changed=0 unreachable=0 failed=1
Friday 10 June 2016 20:49:28 -0400 (0:00:30.182) 0:00:30.819 ***********
===============================================================================
TASK: check if the immortal {{ db.auth }} db with {{ db_provider }} exists? -- 30.18s
TASK: setup ------------------------------------------------------------- 0.58s
TASK: include ----------------------------------------------------------- 0.04s
did you deploy the ephemeral couch at first?
I think I try both CouchDB and Cloudant
pull 605 is merged, can you pls try again or reproduce the issue?
I tried persistent CouchDB case ,I use windows platform and I got error
vagrant@vagrant-ubuntu-trusty-64:~/openwhisk/ansible$ ansible-playbook -i envir onments/local initdb.yml
PLAY [ansible] *****************************************************************
TASK [setup] *******************************************************************
Thursday 16 June 2016 11:26:46 +0000 (0:00:00.040) 0:00:00.041 *********
ok: [ansible]
TASK [include] *****************************************************************
Thursday 16 June 2016 11:26:49 +0000 (0:00:03.138) 0:00:03.180 *********
included: /home/vagrant/openwhisk/ansible/tasks/initdb.yml for ansible
TASK [check if the immortal subjects db with CouchDB exists?] ******************
Thursday 16 June 2016 11:26:49 +0000 (0:00:00.044) 0:00:03.225 *********
fatal: [ansible]: FAILED! => {"changed": false, "content": "", "failed": true, " msg": "Status code was not [200, 404]: Request failed: <urlopen error [Errno 111 ] Connection refused>", "redirected": false, "status": -1, "url": "http://172.17 .0.2:6000/subjects"}
PLAY RECAP *********************************************************************
ansible : ok=2 changed=0 unreachable=0 failed=1
Thursday 16 June 2016 11:26:50 +0000 (0:00:00.310) 0:00:03.535 *********
setup ------------------------------------------------------------------- 3.14s check if the immortal subjects db with CouchDB exists? ------------------ 0.31s include ----------------------------------------------------------------- 0.04s
I set couchdb param like this
- vagrant up
- vagrant ssh
- in the virtual env, execute:
export OW_DB=CouchDB export OW_DB_USERNAME=admin export OW_DB_PASSWORD=86889125 export OW_DB_PROTOCOL=http export OW_DB_HOST=172.17.0.2 export OW_DB_PORT=6000
ansible-playbook setup.yml
- execute
cd openwhisk_home gradle distDocker cd ansible ansible-playbook -i environments/local couchdb.yml ansible-playbook -i environments/local initdb.yml -> where error comes from
Is there anything wrong with my param setting?
you are not using a persistent couch, aren"t you. Just deploy the ephemeral couch.
Pls do it as follows
export OW_DB=CouchDB
export OW_DB_USERNAME=admin
export OW_DB_PASSWORD=86889125
export OW_DB_PROTOCOL=http
export OW_DB_HOST=172.17.0.2
export OW_DB_PORT=6000
ansible-playbook -i environments/local setup.yml
after that, ensure you have a file called db_local.ini in the ansible folder. Pls compare the credentials there with your credentials that are exported via bash above.
Then
ansible-playbook -i environments/local couchdb.yml
ansible-playbook -i environments/local initdb.yml
ansible-playbook -i environments/local openwhisk
Ok, but doc https://github.com/openwhisk/openwhisk/blob/master/ansible/README.md#persistent-couchdb
writes: ansible-playbook setup.yml whitout "-i environments/local"
you're rite, there is a bug in doc. this pull: https://github.com/openwhisk/openwhisk/pull/686 will fix it
you're rite, there is a bug in doc. this pull: #686 will fix it #686 is closed and problem is not fix, do you have a new PR with the fix
@csantanapr is this issue still valid?
Not anymore