From 6c9d59d7c069f32ac74844f3326524511a4b6e18 Mon Sep 17 00:00:00 2001 From: javi Date: Wed, 24 Feb 2016 11:54:55 +0100 Subject: [PATCH 1/2] add some local steps --- README.md | 46 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/README.md b/README.md index 0159356..5a58a4b 100644 --- a/README.md +++ b/README.md @@ -20,3 +20,49 @@ Steps to deploy a new Geocoder API version : - `RAILS_ENV=production bundle exec rake cartodb:db:configure_geocoder_extension_for_organizations['', true]` - `RAILS_ENV=production bundle exec rake cartodb:db:configure_geocoder_extension_for_non_org_users['', true]` - Freeze the generated SQL file for the version. Eg. cdb_dataservices_server--0.0.1.sql + +### Local install instructions + +- install data services extension + + ``` + git clone git@github.com:CartoDB/data-services.git + data-services/geocoder/extension + sudo make install + ``` + +- install server and client extensions + + ``` + cd client && sudo make install + cd server && sudo make install + ``` + +- install python library + + ``` + cd server/lib/python/cartodb_services && python setup.py install + ``` + +- install extensions in user database + + ``` + create extension cdb_geocoder; + create extension plproxy; + create extension cdb_dataservices_server; + create extension cdb_dataservices_client; + ``` + +- add configuration for different services in user database + + + ``` + # select CDB_Conf_SetConf('redis_medatada_config', '{"sentinel_host": "localhost", "sentinel_port": 26379, "sentinel_master_id": "mymaster", "timeout": 0.1, "redis_db": 5}'); + # select CDB_Conf_SetConf('heremaps_conf', '{"app_id": "APP_ID", "app_code": "APP_CODE"}'); + ``` + +- congigure plproxy to point to the same user database (you could do in a different one) + + ``` + select CDB_Conf_SetConf('geocoder_server_config', '{ "connection_str": "host=localhost port=5432 dbname=cartodb_dev_user_accf0647-d942-4e37-b129-8287c117e687_db user=postgres"}'); + ``` From 0ab255eb9374eb1085fd6082c9ecc97366011c37 Mon Sep 17 00:00:00 2001 From: javi Date: Wed, 24 Feb 2016 11:58:46 +0100 Subject: [PATCH 2/2] missing confi --- README.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 5a58a4b..0ec20f6 100644 --- a/README.md +++ b/README.md @@ -57,8 +57,11 @@ Steps to deploy a new Geocoder API version : ``` - # select CDB_Conf_SetConf('redis_medatada_config', '{"sentinel_host": "localhost", "sentinel_port": 26379, "sentinel_master_id": "mymaster", "timeout": 0.1, "redis_db": 5}'); + # select CDB_Conf_SetConf('redis_metadata_config', '{"sentinel_host": "localhost", "sentinel_port": 26379, "sentinel_master_id": "mymaster", "timeout": 0.1, "redis_db": 5}'); + # select CDB_Conf_SetConf('redis_metrics_config', '{"sentinel_host": "localhost", "sentinel_port": 26379, "sentinel_master_id": "mymaster", "timeout": 0.1, "redis_db": 5}'); + # select CDB_Conf_SetConf('heremaps_conf', '{"app_id": "APP_ID", "app_code": "APP_CODE"}'); + # select CDB_Conf_SetConf('user_config', '{"is_organization": false, "entity_name": "geocoder"}') ``` - congigure plproxy to point to the same user database (you could do in a different one)