diff options
author | jessib <jessib@riseup.net> | 2014-02-04 10:33:27 -0800 |
---|---|---|
committer | jessib <jessib@riseup.net> | 2014-02-04 10:33:27 -0800 |
commit | c7f376cdc02fe10c7e2a51c7d52475ab34451577 (patch) | |
tree | 75c52cbbd43bb55d155c301855677fcba123a2c7 /test/setup_couch.sh | |
parent | cda7ebacf35bcc0fcf233e5a23b958ed751fb108 (diff) | |
parent | c3cb71ca5e6d32960e4493d85799f3706ea91fe8 (diff) |
Merge pull request #9 from azul/test/integration-with-travis
Test/integration with travis
Diffstat (limited to 'test/setup_couch.sh')
-rw-r--r-- | test/setup_couch.sh | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/test/setup_couch.sh b/test/setup_couch.sh new file mode 100644 index 0000000..c11993d --- /dev/null +++ b/test/setup_couch.sh @@ -0,0 +1,13 @@ +#!/bin/bash + +HOST="http://localhost:5984" +echo "couch version :" +curl -X GET $HOST +echo "creating unprivileged user :" +curl -HContent-Type:application/json -XPUT $HOST/_users/org.couchdb.user:me --data-binary '{"_id": "org.couchdb.user:me","name": "me","roles": [],"type": "user","password": "pwd"}' +echo "creating database to watch:" +curl -X PUT $HOST/tapicero_test_users +echo "restricting database access :" +curl -X PUT $HOST/tapicero_test_users/_security -Hcontent-type:application/json --data-binary '{"admins":{"names":[],"roles":[]},"members":{"names":["me"],"roles":[]}}' +echo "adding admin :" +curl -X PUT $HOST/_config/admins/anna -d '"secret"' |