GithubHelp home page GithubHelp logo

Comments (6)

jacobsalmela avatar jacobsalmela commented on April 29, 2024

Yeah, that isn't good. I'll figure some way to better get the IP.

from pi-hole.

korhadris avatar korhadris commented on April 29, 2024

I don't know if the order is always IPV4, then IPV6 (which a cut or awk command would work), but the following sed would keep it regardless of order:
hostname -I | sed -r -e 's/.*(\b[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\b).*/\1/'

from pi-hole.

parnz avatar parnz commented on April 29, 2024

I'm also have this issue but I've only one IPv4.

pi@pidns ~ $ hostname -I |xargs
192.168.6.212
pi@pidns ~ $

I've to replace the whitespace with the IP manually in gravity.list about 1.6M lines (Thanks to Ctrl+H for that).

p.s RPi B+ running rasbian Jessie.

from pi-hole.

jacobsalmela avatar jacobsalmela commented on April 29, 2024

I restored the script to how it used to be until a better solution can be devised.

from pi-hole.

jacobsalmela avatar jacobsalmela commented on April 29, 2024

I started some changes on the development branch to address this issue. Any feedback is welcome.

from pi-hole.

mospaeda avatar mospaeda commented on April 29, 2024

The version in dev is working fine with me (dated 15 oct)
my hostname is :
192.168.1.55 2a01:e35:xxx:xxx:xxx:xxx:xxx:xxx 2a01:e35:yyy:yyy:yyy:yyy:yyy:yyy
therefore I have 1 IPV4 and 2 IPV6
script successfully extract the IPV4 and the 2nd IPV6
then accretion.txt is created with 2 lines per blocked site

it seems that if some sites are both in blacklist.txt and other lists then they are duplicate entries in accretion.txt (1IPV4 entry + 1 IPV6 entry twice)

note: I didn't checked yet whitelisting with this version.

from pi-hole.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.