Unverified Commit 3c48b844 by Vincent Martinez Committed by Paul B

[dev] update example files + cleaning files + init couchdb

parent 544053fa
Pipeline #822 failed with stage
in 12 seconds
...@@ -91,4 +91,4 @@ BRINKS_MUST_IDENTIFY = True ...@@ -91,4 +91,4 @@ BRINKS_MUST_IDENTIFY = True
ENTRANCE_FTOP_BUTTON_DISPLAY = False ENTRANCE_FTOP_BUTTON_DISPLAY = False
CUSTOM_CSS_FILES = {'all': ['common_lgds.css'], CUSTOM_CSS_FILES = {'all': ['common_lgds.css'],
'members': ['inscription_lgds.css']} 'members': ['inscription_lgds.css','member_lgds.css']}
{
"views": {
"by_fp": {
"map": "function(doc){emit(doc.fingerprint);}"
},
"by_completed": {
"map": "function(doc){emit(doc.completed);}"
},
"by_odoo_id": {
"map": "function(doc){emit(doc.odoo_id);}"
}
}
}
{
"views": {
"by_type": {
"map": "function(doc){emit(doc.type);}"
}
}
}
#!/usr/bin/env sh
sleep 3
curl -X PUT http://admin:123abc@couchdb:5984/coops
curl -X PUT http://admin:123abc@couchdb:5984/inventory
curl -X PUT http://admin:123abc@couchdb:5984/envelop
curl -X PUT http://admin:123abc@couchdb:5984/shopping_carts
curl -X PUT http://admin:123abc@couchdb:5984/coops/_design/index \
-d @couchdb-coops-init.json
curl -X PUT http://admin:123abc@couchdb:5984/envelop/_design/index \
-d @couchdb-envelop-init.json
...@@ -27,6 +27,17 @@ services: ...@@ -27,6 +27,17 @@ services:
volumes: volumes:
- "couchdb-data:/opt/couchdb/data" - "couchdb-data:/opt/couchdb/data"
initializer:
image: curlimages/curl
deploy:
restart_policy:
condition: on-failure
depends_on:
- couchdb
command: ["sh", "-c", "cd /tmp && ./couchdb-setup.sh"]
volumes:
- "./:/tmp"
database: database:
image: "postgres:10" image: "postgres:10"
env_file: .env env_file: .env
......
[couchdb]
single_node=true
[httpd] [httpd]
enable_cors = true enable_cors = true
[cors] [cors]
origins = * credentials = true
origins = http://127.0.0.1:8080
[replicator]
db = _replicator
[admins]
;admin = 123abc
admin = -pbkdf2-c5101d6618dfa702b4fb72b1ea0f335e1d1d84f9,506213b6a001da088296f40327cc2e86,10
...@@ -220,4 +220,6 @@ LOGGING = { ...@@ -220,4 +220,6 @@ LOGGING = {
# SECURITY WARNING: don't run with debug turned on in production! # SECURITY WARNING: don't run with debug turned on in production!
DEBUG = True DEBUG = True
CORS_ORIGIN_ALLOW_ALL = True # Needed to make dev test with different IP and ports CORS_ORIGIN_ALLOW_ALL = True # Needed to make dev test with different IP and ports
\ No newline at end of file
ADMIN_IDS = [1]
...@@ -3,12 +3,12 @@ ...@@ -3,12 +3,12 @@
ODOO = { ODOO = {
'url': 'http://odoo:8069', 'url': 'http://odoo:8069',
'user': 'api', 'user': 'api',
'passwd': 'changeme', 'passwd': 'foodcoops',
'db': 'foodcoops', 'db': 'foodcoops',
} }
COUCHDB = { COUCHDB = {
'url': 'http://couchdb:5984', 'url': 'http://127.0.0.1:5984',
'dbs': { 'dbs': {
'member': 'coops', 'member': 'coops',
'inventory': 'inventory', 'inventory': 'inventory',
...@@ -17,7 +17,7 @@ COUCHDB = { ...@@ -17,7 +17,7 @@ COUCHDB = {
} }
} }
""" To ignore """
SQL_OFF = { SQL_OFF = {
'db': 'open_food_facts', 'db': 'open_food_facts',
'user': 'off_user', 'user': 'off_user',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment