-
Notifications
You must be signed in to change notification settings - Fork 154
/
create_dev_user
executable file
·32 lines (26 loc) · 1.04 KB
/
create_dev_user
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/sh
SUBDOMAIN="dev"
PASSWORD="pass"
ADMIN_PASSWORD="pass"
EMAIL="[email protected]"
echo "--- Creating databases"
bundle exec rake cartodb:db:setup --trace SUBDOMAIN="${SUBDOMAIN}" \
PASSWORD="${PASSWORD}" ADMIN_PASSWORD="${ADMIN_PASSWORD}" \
EMAIL="${EMAIL}"
if test $? -ne 0; then exit 1; fi
# # Update your quota to 100GB
echo "--- Updating quota to 100GB"
bundle exec rake cartodb:db:set_user_quota["${SUBDOMAIN}",102400]
if test $? -ne 0; then exit 1; fi
# # Allow unlimited tables to be created
echo "--- Allowing unlimited tables creation"
bundle exec rake cartodb:db:set_unlimited_table_quota["${SUBDOMAIN}"]
if test $? -ne 0; then exit 1; fi
# # Allow user to create private tables in addition to public
echo "--- Allowing private tables creation"
bundle exec rake cartodb:db:set_user_private_tables_enabled["${SUBDOMAIN}",'true']
if test $? -ne 0; then exit 1; fi
# # Set the account type
echo "--- Setting cartodb account type"
bundle exec rake cartodb:db:set_user_account_type["${SUBDOMAIN}",'[DEDICATED]']
if test $? -ne 0; then exit 1; fi