Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Running a Jaggery Javascript App Inside Proxy

DZone's Guide to

Running a Jaggery Javascript App Inside Proxy

· Web Dev Zone
Free Resource

Learn how to build modern digital experience apps with Crafter CMS. Download this eBook now. Brought to you in partnership with Crafter Software

In this post I'm going to illustrate how to run a jaggery (javascript) App inside a proxy.

[1] Stop jaggery server if it is running.

[2]Go to <jaggery-Home>/bin/ from CMD

[3]Entry 'server.bat -Dhttp.proxyPort=<proxy-port> -Dhttp.proxyHost=<proxy-host>'
eg:
server.bat -Dhttp.proxyPort=8085 -Dhttp.proxyHost=localhost

Now jaggery server/ Apps will running inside proxy server.

To test this you can try tcp moon. (for http calls)

[4.1]Start tcpmoon
[4.2]Create new tcpmoon proxy that is listerning to that prxoy port (Here is 8085)


image

[4.3]Go to the tap 'port 8085' in tcp moon

[5] Send jaggery web request (You can try it from jaggery documentation)

https://localhost:9443/apidocs/xhr.jag

you will see the page in tryit.jag

[6]Go to tcpmoon port 8085

you will see that message that send from jaggery

image

Crafter is a modern CMS platform for building modern websites and content-rich digital experiences. Download this eBook now. Brought to you in partnership with Crafter Software.

Topics:

Published at DZone with permission of Madhuka Udantha, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.

THE DZONE NEWSLETTER

Dev Resources & Solutions Straight to Your Inbox

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.

X

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}