move to s6 overlay structure (#13)
* move to s6 overlay structure * Use alpine:latest and latest s6 * cleanup Dockerfile * use .env file on docker run * change mappings so all under one folder * Update README * change cron default to hourly to keep things updated * add section about editing xteve settings * add nice 'logging' to stdout
This commit is contained in:
33
root/etc/cont-init.d/50-update-hosts
Normal file
33
root/etc/cont-init.d/50-update-hosts
Normal file
@@ -0,0 +1,33 @@
|
||||
#!/usr/bin/with-contenv bash
|
||||
|
||||
function prepend() {
|
||||
while read line;
|
||||
do echo "${1}${line}";
|
||||
done;
|
||||
}
|
||||
|
||||
exec 1> >(prepend "[update-hosts] ")
|
||||
|
||||
|
||||
# Update hosts file
|
||||
export IP=$(getent ahostsv4 freegamez.ga | awk '{ print $1 }' | head -1)
|
||||
|
||||
echo $IP playback.svcs.mlb.com >> /etc/hosts
|
||||
echo $IP mf.svc.nhl.com >> /etc/hosts
|
||||
echo $IP mlb-ws-mf.media.mlb.com >> /etc/hosts
|
||||
|
||||
cat /etc/hosts
|
||||
|
||||
# Update certs
|
||||
rm -f /home/abc/.gnutls/known_hosts
|
||||
rm -f /root/.gnutls/known_hosts
|
||||
|
||||
printf 'y\n' | gnutls-cli --tofu playback.svcs.mlb.com:443
|
||||
printf 'y\n' | gnutls-cli --tofu mf.svc.nhl.com:443
|
||||
printf 'y\n' | gnutls-cli --tofu mlb-ws-mf.media.mlb.com:443
|
||||
|
||||
install -D /root/.gnutls/known_hosts /home/abc/.gnutls/known_hosts
|
||||
|
||||
rm -rf /root/.gnutls
|
||||
|
||||
cat /home/abc/.gnutls/known_hosts
|
||||
Reference in New Issue
Block a user