|
@@ -299,11 +299,27 @@ function install_rethinkdb {
|
299
|
299
|
wget -qO- https://download.rethinkdb.com/apt/pubkey.gpg | apt-key add -
|
300
|
300
|
apt-get update
|
301
|
301
|
apt-get -yq install rethinkdb
|
302
|
|
- if [ ! -f /etc/rethinkdb/default.conf.sample ]; then
|
303
|
|
- echo $'rethinkdb example configuration not found'
|
304
|
|
- exit 78252
|
305
|
|
- fi
|
306
|
|
- cp /etc/rethinkdb/default.conf.sample /etc/rethinkdb/instances.d/default.conf
|
|
302
|
+
|
|
303
|
+ echo '# runuser=rethinkdb' > /etc/rethinkdb/instances.d/default.conf
|
|
304
|
+ echo '# rungroup=rethinkdb' >> /etc/rethinkdb/instances.d/default.conf
|
|
305
|
+ echo '# pid-file=/var/run/rethinkdb/rethinkdb.pid' >> /etc/rethinkdb/instances.d/default.conf
|
|
306
|
+ echo '# directory=/var/lib/rethinkdb/default' >> /etc/rethinkdb/instances.d/default.conf
|
|
307
|
+ echo 'log-file=/var/log/rethinkdb' >> /etc/rethinkdb/instances.d/default.conf
|
|
308
|
+ echo '# bind=127.0.0.1' >> /etc/rethinkdb/instances.d/default.conf
|
|
309
|
+ echo '# canonical-address=' >> /etc/rethinkdb/instances.d/default.conf
|
|
310
|
+ echo '# driver-port=28015' >> /etc/rethinkdb/instances.d/default.conf
|
|
311
|
+ echo '# cluster-port=29015' >> /etc/rethinkdb/instances.d/default.conf
|
|
312
|
+ echo '# join=example.com:29015' >> /etc/rethinkdb/instances.d/default.conf
|
|
313
|
+ echo '# port-offset=0' >> /etc/rethinkdb/instances.d/default.conf
|
|
314
|
+ echo '# reql-http-proxy=socks5://example.com:1080' >> /etc/rethinkdb/instances.d/default.conf
|
|
315
|
+ echo '# http-port=8080' >> /etc/rethinkdb/instances.d/default.conf
|
|
316
|
+ echo '# no-http-admin' >> /etc/rethinkdb/instances.d/default.conf
|
|
317
|
+ echo '# cores=2' >> /etc/rethinkdb/instances.d/default.conf
|
|
318
|
+ echo '# cache-size=1024' >> /etc/rethinkdb/instances.d/default.conf
|
|
319
|
+ echo '# io-threads=64' >> /etc/rethinkdb/instances.d/default.conf
|
|
320
|
+ echo '# direct-io' >> /etc/rethinkdb/instances.d/default.conf
|
|
321
|
+ echo '# server-name=server1' >> /etc/rethinkdb/instances.d/default.conf
|
|
322
|
+
|
307
|
323
|
systemctl restart rethinkdb
|
308
|
324
|
}
|
309
|
325
|
|