Wiki source code of Debug Proxy Configuration
Last modified by Eleni Cojocariu on 2026/08/14 17:53
Show last authors
| author | version | line-number | content |
|---|---|---|---|
| 1 | To check that your proxy configuration is properly read by XWiki and confirm whether the server can access the Internet: | ||
| 2 | |||
| 3 | 1. [[Create a Page>>documentation.xs.user.base.page.create.WebHome]] (for example: ##Sandbox.ProxyDebug##). | ||
| 4 | 1. [[Edit the Page with the Wiki editor>>documentation.xs.user.base.page.edit-page.edit-wiki-editor.WebHome]]. | ||
| 5 | 1. Insert the following Groovy script to list environment variables and Java system properties:((( | ||
| 6 | {{code language="groovy"}} | ||
| 7 | {{groovy}} | ||
| 8 | println "== Environment Variables ==" | ||
| 9 | System.getenv().each { name, value -> println "Name: {{{$name}}} = Value {{{$value}}}" } | ||
| 10 | println "" | ||
| 11 | println "== Java System Properties ==" | ||
| 12 | System.getProperties().each { name, value -> println "Name: {{{$name}}} = Value {{{$value}}}" } | ||
| 13 | {{/groovy}} | ||
| 14 | {{/code}} | ||
| 15 | ))) | ||
| 16 | 1. Insert the following Velocity test to check HTTP connectivity and if your XWiki instance is able to access the Internet:((( | ||
| 17 | {{code language="velocity"}} | ||
| 18 | == Test HTTP Access == | ||
| 19 | Your XWiki server's IP is: | ||
| 20 | {{velocity}} | ||
| 21 | $xwiki.getURLContent("http://httpbin.org/ip") | ||
| 22 | {{/velocity}} | ||
| 23 | |||
| 24 | == Test HTTPS Access == | ||
| 25 | Your XWiki server's IP is: | ||
| 26 | {{velocity}} | ||
| 27 | $xwiki.getURLContent("https://httpbin.org/ip") | ||
| 28 | {{/velocity}} | ||
| 29 | |||
| 30 | {{/code}} | ||
| 31 | ))) | ||
| 32 | 1. Save the Page and notice the information on the Page. |