Rename authenticated postgresql user configuration setting
See issue #49
This commit is contained in:
parent
5ca84d9ffc
commit
b469d5eabf
@ -4,10 +4,10 @@ var config = {
|
|||||||
,host: '127.0.0.1'
|
,host: '127.0.0.1'
|
||||||
,enable_cors: true
|
,enable_cors: true
|
||||||
,cache_enabled: false
|
,cache_enabled: false
|
||||||
|
,postgres_auth_user: 'development_cartodb_user_<%= user_id %>'
|
||||||
,postgres: {
|
,postgres: {
|
||||||
type: "postgis",
|
type: "postgis",
|
||||||
user: "publicuser",
|
user: "publicuser",
|
||||||
db_user: 'development_cartodb_user_<%= user_id %>',
|
|
||||||
host: '127.0.0.1',
|
host: '127.0.0.1',
|
||||||
port: 5432,
|
port: 5432,
|
||||||
extent: "-20005048.4188,-20005048.4188,20005048.4188,20005048.4188",
|
extent: "-20005048.4188,-20005048.4188,20005048.4188,20005048.4188",
|
||||||
|
@ -4,9 +4,9 @@ var config = {
|
|||||||
,host: '127.0.0.1'
|
,host: '127.0.0.1'
|
||||||
,enable_cors: true
|
,enable_cors: true
|
||||||
,cache_enabled: true
|
,cache_enabled: true
|
||||||
|
,postgres_auth_user: 'cartodb_user_<%= user_id %>'
|
||||||
,postgres: {
|
,postgres: {
|
||||||
user: "publicuser",
|
user: "publicuser",
|
||||||
db_user: 'cartodb_user_<%= user_id %>',
|
|
||||||
host: '127.0.0.1',
|
host: '127.0.0.1',
|
||||||
port: 6432,
|
port: 6432,
|
||||||
extent: "-20005048.4188,-20005048.4188,20005048.4188,20005048.4188",
|
extent: "-20005048.4188,-20005048.4188,20005048.4188,20005048.4188",
|
||||||
|
@ -4,9 +4,9 @@ var config = {
|
|||||||
,host: '127.0.0.1'
|
,host: '127.0.0.1'
|
||||||
,enable_cors: true
|
,enable_cors: true
|
||||||
,cache_enabled: true
|
,cache_enabled: true
|
||||||
|
,postgres_auth_user: 'cartodb_staging_user_<%= user_id %>'
|
||||||
,postgres: {
|
,postgres: {
|
||||||
user: "publicuser",
|
user: "publicuser",
|
||||||
db_user: 'cartodb_staging_user_<%= user_id %>',
|
|
||||||
host: '127.0.0.1',
|
host: '127.0.0.1',
|
||||||
port: 6432,
|
port: 6432,
|
||||||
extent: "-20005048.4188,-20005048.4188,20005048.4188,20005048.4188",
|
extent: "-20005048.4188,-20005048.4188,20005048.4188,20005048.4188",
|
||||||
|
@ -4,9 +4,9 @@ var config = {
|
|||||||
,host: '127.0.0.1'
|
,host: '127.0.0.1'
|
||||||
,enable_cors: true
|
,enable_cors: true
|
||||||
,cache_enabled: false
|
,cache_enabled: false
|
||||||
|
,postgres_auth_user: 'test_cartodb_user_<%= user_id %>'
|
||||||
,postgres: {
|
,postgres: {
|
||||||
user: "publicuser",
|
user: "publicuser",
|
||||||
db_user: 'test_cartodb_user_<%= user_id %>',
|
|
||||||
host: '127.0.0.1',
|
host: '127.0.0.1',
|
||||||
port: 5432,
|
port: 5432,
|
||||||
srid: 4326,
|
srid: 4326,
|
||||||
|
@ -89,7 +89,7 @@ module.exports = function() {
|
|||||||
// authorized by key, login as db owner
|
// authorized by key, login as db owner
|
||||||
that.getId(req, function(err, user_id) {
|
that.getId(req, function(err, user_id) {
|
||||||
if (err) throw new Error(err);
|
if (err) throw new Error(err);
|
||||||
var dbuser = _.template(global.settings.postgres.db_user, {user_id: user_id});
|
var dbuser = _.template(global.settings.postgres_auth_user, {user_id: user_id});
|
||||||
_.extend(req, {dbuser:dbuser});
|
_.extend(req, {dbuser:dbuser});
|
||||||
callback(err, true);
|
callback(err, true);
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user