Saturday, June 25, 2011

GRAILS Configuration -- Proxy Settings

There are two commands to set proxy in GRAILS.
  • Add Proxy - adds a proxy server setting in proxysettings.groovy file
  • Set Proxy - sets the current proxy in the proxysettings.groovy file.
grails add-proxy client --host=proxy-server --port=4300 --username=guest --password=guest
grails set-proxy client
For example:
grails add-proxy myproxy --host=internet --port=8085
grails set-proxy myproxy
If you are using windows console then you will need to enclose parameters with double quotes.
grails add-proxy myproxy "--host=internet" "--port=8085"
grails set-proxy myproxy
Settings can then be verified in the proxysettings.groovy file. This file can be located in the .grails folder.


  1. This is useful, however you ought to also post the resulting content of the proxysettnigs.groovy file. What you have here is direct from the Grails ref.

  2. This is failing on a Windows configuration.
    Also, can you please tell where the proxysettings.groovy file is stored? In the groovy directory or the application directory? TIA