Comments (5)
Good point - thanks! One fix is to just change env PATH=$(PATH)
to env PATH=$(PATH):/sbin
. That should only alter the PATH variable in the context of the sudo
command. However, I'm actually not sure now whether env PATH=$(PATH)
is needed in the first place, since we have absolute paths to the interpreter and reset.py
. It's pretty late here, so I'll think about what to do about this tomorrow, but happy to hear your thoughts too.
from chomper.
Another option is to use python library for interacting with iptables - https://github.com/ldx/python-iptables
btw, iptables could be located in /usr/sbin
too
from chomper.
Interesting library, but I'd rather not add on another dependency if it's not necessary.
Another idea: use which iptables
to figure out where iptables is located on the system, parse out the directory, and make sure it's on path during the sudo command. Specifically, add the following new variable to the top of the Makefile
IPTABLES_PATH = dirname $(which iptables)
and then modify the reset task as follows
reset:
sudo env PATH=$(PATH):$(IPTABLES_PATH) ${INTERPRETER}3.6m ${CURRENT_DIR}/chomper/reset.py
from chomper.
which
works by searching current PATH
. I suggest you to add /sbin:/usr/sbin
to env and forget about this ticket until someone reports it again.
from chomper.
Yeah you're right - which
isn't necessary if it's already on PATH. Let's just do what you're suggesting - add /sbin:/usr/sbin
to the env.
Could you make a PR? Thanks!
from chomper.
Related Issues (20)
- Deinstallation HOT 1
- Receive the following bug on running command.
- Accessing mitmproxy
- YouTube not blocked on Chrome HOT 3
- How do I uninstall? HOT 2
- Chomper never unblocks, requires reboot HOT 2
- Is this project dead or unmaitained? HOT 7
- Progressive block HOT 1
- Make use of online blacklists
- Add rule for word filtering in URL
- Bug: Error whon running block HOT 1
- Chomper prevents me from accessing *any* webpage
- Dropbox Sync issue: cannot establish secure internet connection HOT 2
- Arch Linux package (yay) HOT 1
- You were added to Awesome Humane Tech
- Blacklist blocked all access to internet (kind of)
- Site is down
- No virtualenv has been created for this project yet
- Add sponsor button for yourself and the project
- Install failed?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from chomper.