Skip to content

Instantly share code, notes, and snippets.

View Mohitsharma44's full-sized avatar

Mohit Mohitsharma44

View GitHub Profile
@Mohitsharma44
Mohitsharma44 / blocklists.txt
Created March 29, 2021 08:28
Developer Dans blocklists
https://www.github.developerdan.com/hosts/lists/ads-and-tracking-extended.txt
https://www.github.developerdan.com/hosts/lists/facebook-extended.txt
https://www.github.developerdan.com/hosts/lists/amp-hosts-extended.txt
https://www.github.developerdan.com/hosts/lists/hate-and-junk-extended.txt
https://www.github.developerdan.com/hosts/lists/tracking-aggressive-extended.txt
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Mohitsharma44
Mohitsharma44 / whitelist.txt
Created May 24, 2020 20:22
Whitelist URLs to let devices work
# Amazon Alexa and Amazon Shopping app
device-metrics-us-2.amazon.com
device-metrics-us.amazon.com
# Netflix - Domains needed for netlix to work correctly
api-global.netflix.com
ichnaea.netflix.com
appboot.netflix.com
secure.netflix.com
@Mohitsharma44
Mohitsharma44 / adblock.txt
Last active May 29, 2020 07:20
Custom Ad Blocks
# Panasonic Viera & panny tv
0077777700140002.myhomescreen.tv
cert-test.sandbox.google.com
collect-us-fy2014.myhomescreen.tv
collect-us-fy2015.myhomescreen.tv
collect-us-fy2016.myhomescreen.tv
collect-us-fy2017.myhomescreen.tv
collect-us-fy2018.myhomescreen.tv
collect-us-fy2019.myhomescreen.tv
@Mohitsharma44
Mohitsharma44 / supervisord.sh
Last active March 11, 2019 20:54 — forked from danmackinlay/supervisord.sh
an init.d script for supervisord
#! /bin/sh
### BEGIN INIT INFO
# Provides: supervisord
# Required-Start: $remote_fs
# Required-Stop: $remote_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Example initscript
# Description: This file should be used to construct scripts to be
# placed in /etc/init.d.
Fri Feb 22 20:13:33 UTC 2019
@Mohitsharma44
Mohitsharma44 / prep.sh
Created November 10, 2018 23:57
Copying files from Master Pi to Client Pis
#!/bin/bash
echo -ne "Prepping CenterVizWall"
echo
echo -ne "Setting correct vizwall configuration options for all-screen-cast"
for dest in $(<destfile.txt); do scp .piwall listener.sh ${dest}:/home/pi/; done
@Mohitsharma44
Mohitsharma44 / loop.sh
Created November 10, 2018 23:48
Script to project video to Piwall
#!/bin/bash
echo -ne "CenterVizWall Starting Cast"
echo
echo -ne "Asking all tiles to start listening to the upcoming stream"
user=pi bash runon vizwall-00 vizwall-01 vizwall-02 vizwall-03 vizwall-04 vizwall-05 vizwall-06 vizwall-07 vizwall-08 vizwall-09 vizwall-10 vizwall-11 vizwall-12 vizwall-13 vizwall-14 'sudo nice -n -20 su -c "/bin/bash /home/pi/listener.sh > /dev/null 2>&1 &" pi'
while true;
do
sleep 2
echo -ne "(Re)Starting FFMPEG stream"
@Mohitsharma44
Mohitsharma44 / runon
Created November 10, 2018 23:46
Running (existing) bash scripts on remote servers
#!/bin/bash
if [ $# = 0 ]
then
self=`basename $0`
echo "Execute a command on multiple servers."
echo
echo "1. Basic Usage"
echo
echo " $self server1 [server2 ...] command"