Skip to main content

Command Palette

Search for a command to run...

Bypass Proxy for Composer/NPM/Apt

Updated
1 min read
Bypass Proxy for Composer/NPM/Apt
M

DevOps Engineer | Kubernetes | Python | Terraform | AWS | GCP

While working in a restricted on-prem network, popular package managers like Composer or NPM may not properly work. Thanks to the proxy filtering technologies at the internet gateway end.

These package managers often download files over an unencrypted HTTP connection and verify the binaries using a checksum or GPG signature. However, in some cases, it is possible to bypass the filtering by enforcing HTTPS so these tools use an encrypted connection to fetch and download artifacts.

Composer

composer config --global disable-tls
composer config --global secure-http

NPM

npm config set registry https://registry.npmjs.org/
npm config set ssl-strict=false

Apt

sed -i s/http/https/g /etc/apt/sources.list

More from this blog

M

Minhaz's Blog

111 posts