Hi,
There are some issues with using CommandBox in my office. I know another user had this issue but wanted to highlight it as a separate post to see how many people have this problem.
For example, I cannot reach forgebox
struct
Charset [empty string]
ErrorDetail Connect Exception: Connection refused: connect
Filecontent Connection Failure
Header [empty string]
Mimetype Unable to determine MIME type of file.
Responseheader
struct [empty]
Statuscode Connection Failure. Status code unavailable.
Text YES
If I add my proxy information, I receive a reply, note that I’m calling this from outside of command box to show results in a simple test to it returns error, but as you can see I receive a valid reply back from your site.
struct
Charset utf-8
ErrorDetail [empty string]
Filecontent <?xml version="1.0" encoding="utf-8"?>trueInvalid ForgeBox resource
I did a quick search and seems like forgebox.cfc was the only function making a cfhttp call so I updated this function and restarted box and was able to call “forgebox show new interceptors”
<cffunction name=“makeRequest”…
Of course this is not enough as I found out by trying another command - install commandbox-cuck-norris
Fails again so I opened ProgressableDownloader.cfc
// Get connection following redirects
private function resolveConnection( required string downloadURL, redirectUDF ) {
var proxy = new proxy(Proxy.Type.HTTP, new InetSocketAddress(“proxy.corp.net”,8888));
var netURL = createObject( ‘java’, ‘java.net.URL’ ).init( arguments.downloadURL );
var connection = netURL.openConnection(proxy);
connection.setInstanceFollowRedirects( false );
I haven’t used this java version before and it doesn’t seem to like my proxy address but I figure there are a bunch of these as well to review if I were to get this working on my workstation.
I have a work around which is to tether my phone if I need to do some of these cfhttp related functions but others may not have that ability.
Just wondering how many other corporate overlords also make you go through a stupid proxy?