Running Google Chrome with custom Proxy on OSX

Since Lion, Safari has a painful memory leak issue that keeps filling up all of my Mac’s ram when I keep the browser open for a couple of days (closing tabs after use of course). Since this is incredibly annoying, I ended up switching to Google Chrome and … boy that thing is fast!

However, I ran into an issue when I tried using Chrome at work: We have very $*#(%#@_ Proxy settings here. Long story short: Chrome only works with one given set of proxy settings, and all other applications only work with another set of proxy settings. The fact that Chrome absolutely wants to use the OS Proxy settings (in fact, doesn’t even come with custom Proxy settings) was a killer and made the whole browser useless to me… at first ๐Ÿ™‚

I started looking into Chrome extensions that promised to switch proxies and use custom ones… It looked to me like they were trying to change the OS’ Proxy settings, which is totally not what I wanted.

After some Google’ing, I finally came across this OSX hint. And YES, it works! ๐Ÿ™‚ Together with a little bit of Automator magic, here’s what I ended up doing:

  1. ย Open Automator
  2. select to create an Application
  3. Double-click Run Shell Script in the Library/Utilities folder
  4. replace the text content โ€” cat โ€” with the following:
    open -a “Google Chrome” –argsย –proxy-server=host#:port#
    (Replace host# and port# with the host and port numbers that you need to use)
  5. Save as application somewhere and use it to launch Chrome with your specified proxy.
That’s it, works ๐Ÿ™‚
Advertisements