Complete sources for a monero webminer.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

33 lines
922 B

#!/usr/bin/env bash
# Check if $DOMAIN is set
if [ -z $DOMAIN ]; then
echo -e "You need to set \$DOMAIN variable at run time\n"
echo -e "For example: docker run -d -p 80:80 -p 443:443 -e\n"
exit 1
# Install
apt-get -qq update
apt-get install -qq \
cron \
openssl \
curl \
coreutils \
socat \
git clone /root/ && \
cd /root/ && \
git checkout 2.7.8 && \
/root/ --install
# Generate SSL cert
/root/ --issue --standalone -d ${DOMAIN} -d www.${DOMAIN}
# Generate pfx
openssl pkcs12 -export -out /webminerpool/certificate.pfx -inkey /root/${DOMAIN}/${DOMAIN}.key -in /root/${DOMAIN}/${DOMAIN}.cer -certfile /root/${DOMAIN}/fullchain.cer -passin pass:miner -passout pass:miner
# Start server
pushd /webminerpool
exec /usr/bin/mono server.exe