https://github.com/tkluck/pac4cli
Proxy-auto-discovery for command-line applications
https://github.com/tkluck/pac4cli
commandline networking proxy
Last synced: 4 months ago
JSON representation
Proxy-auto-discovery for command-line applications
- Host: GitHub
- URL: https://github.com/tkluck/pac4cli
- Owner: tkluck
- Created: 2017-05-12T05:48:36.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2020-08-08T02:32:38.000Z (almost 6 years ago)
- Last Synced: 2025-03-01T10:02:25.560Z (over 1 year ago)
- Topics: commandline, networking, proxy
- Language: Python
- Homepage:
- Size: 231 KB
- Stars: 25
- Watchers: 6
- Forks: 9
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Proxy-auto-discovery for command line applications (pac4cli)

### Introduction
On many corporate networks, applications need
[proxy-auto-discovery](https://en.wikipedia.org/wiki/Web_Proxy_Auto-Discovery_Protocol)
to know whether a certain URL is accessed either directly or through a web
proxy. Browsers can typically handle this, but many command line applications
(git, npm, apt, curl) rely on environment variable to hard-code a proxy
regardless of the destination URL.
This little daemon enables these applications for auto-discovery by:
- setting the `http_proxy` variable (and friends) to http://localhost:3128
- providing a simple proxy at that port that does proxy-auto-discovery and
connects accordingly.
System dependencies:
- systemd
- NetworkManager
Python library dependencies from PyPI can be installed through:
sudo pip3 install -r requirements.txt
### Installation instructions
#### Ubuntu
The latest builds are available through a PPA:
sudo add-apt-repository ppa:tkluck/pac4cli
sudo apt update
sudo apt install pac4cli
You'll need to restart your shell for the new environment variables to take effect.
This will install `pac4cli` for most of your command line tools. However, we
don't ship configuration for Apt. If you want to use `pac4cli` for software
updates, you'll need to run the following:
sudo tee /etc/apt/apt.conf.d/99pac4cli <