add shell script and make cmd for posting onion address to monero.fail

tor
lza_menace 4 years ago
parent 096d969577
commit c550bdee04

@ -33,3 +33,6 @@ logs-full: ## Get logs from the containers
tor: ## Get onion address for the Monero node
docker-compose -f docker-compose.yaml exec tor cat /var/lib/tor/monero/hostname
post: ## Post onion address to monero.fail
docker-compose -f docker-compose.yaml exec tor bash /post.sh

@ -0,0 +1,6 @@
#!/bin/bash
ONION_ADDR=$(cat /var/lib/tor/monero/hostname)
ONION_URL="http://${ONION_ADDR}:18081"
curl -q -X POST https://monero.fail/add -d node_url=${ONION_URL}

@ -1,6 +1,6 @@
FROM ubuntu:20.04
RUN apt-get update && apt-get install tor -y
RUN apt-get update && apt-get install tor curl -y
RUN mkdir -p /run/tor \
&& chown -R debian-tor:debian-tor /run/tor \
@ -8,6 +8,8 @@ RUN mkdir -p /run/tor \
COPY conf/torrc /etc/tor/torrc
COPY conf/post.sh /post.sh
USER debian-tor
EXPOSE 9050

Loading…
Cancel
Save