Host file.

Discussion in 'all things UNIX' started by The Red Moon, Sep 28, 2019.

  1. The Red Moon

    The Red Moon Registered Member

    Joined:
    May 17, 2012
    Posts:
    4,038
    I use puppy linux and have done for quite a while now.i would like to use the hosts file for system wide ad blocking if possible.
    Is there any guide on how to achieve this please.?

    Thank you.
     
  2. 1PW

    1PW Registered Member

    Joined:
    Apr 2, 2010
    Posts:
    807
    Location:
    North of the 38th parallel.
  3. summerheat

    summerheat Registered Member

    Joined:
    May 16, 2015
    Posts:
    1,722
    Just add the following line to /etc/crontab:
    Code:
    @daily /usr/bin/wget -O /etc/hosts https://raw.githubusercontent.com/StevenBlack/hosts/master/alternates/fakenews-gambling-porn-social/hosts
    This downloads that hosts file (you can choose another one, of course) once a day and saves it as /etc/hosts.
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.