-
Notifications
You must be signed in to change notification settings - Fork 38
Expand file tree
/
Copy pathrun-apache.sh
More file actions
31 lines (25 loc) · 820 Bytes
/
run-apache.sh
File metadata and controls
31 lines (25 loc) · 820 Bytes
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
#!/bin/bash
if ! [ -f "/root/.datacoin" ]; then
mkdir /root/.datacoin
fi
CONF_FNAME=/root/.datacoin/datacoin.conf
if ! [ -f "$CONF_FNAME" ]; then
cp /var/www/html/.dockerize/datachain/datacoin.conf "$CONF_FNAME"
fi
POLYCASH_CONF_FNAME=/var/www/html/src/config/config.json
if ! [ -f "$POLYCASH_CONF_FNAME" ]; then
cp /var/www/html/.dockerize/polycash/example-config.json "$POLYCASH_CONF_FNAME"
chmod 666 "$POLYCASH_CONF_FNAME"
fi
if ! [ -f "/var/www/html/datacoind" ]; then
wget https://poly.cash/binaries/debian/datacoind -P /var/www/html
chmod 755 /var/www/html/datacoind
fi
if ! [ -f "/var/www/html/datacoin-cli" ]; then
wget https://poly.cash/binaries/debian/datacoin-cli -P /var/www/html
chmod 755 /var/www/html/datacoin-cli
fi
/var/www/html/datacoind &
cron
a2enmod headers rewrite
apache2-foreground