[racket] RedHat OpenShift

24 views
Skip to first unread message

Ray Racine

unread,
May 15, 2012, 1:49:31 PM5/15/12
to Racket
Just noticed that Redhat's OpenShift (their cloud thingy) has released a DIY v0.1 cartrige to their PAAS offering.  You can run up to 3 applications free and while it's not official, they have specifically said that they intend have a free offering indefinitely.

The DIY offering has all the machinery to create a Racket cartridge.  They already have a JBoss,Ruby,Python, JSNode offerings.

Conceptually you write your code, then using git push the code, and use the console to launch it using the Racket (webserver) cartridge or some sort of SIGHUP your server to load the new code etc.

The DIY offering is pretty new with limited doc.

https://openshift.redhat.com/community/blogs/new-openshift-release-march-22-2012-nodejs-diy-cartridge-new-website-and-more

https://openshift.redhat.com/community/blogs/a-paas-that-runs-anything-http-getting-started-with-diy-applications-on-openshift

I'll create a github project and post it this evening if anyone wants to assist in creating a Racket Cartridge for OpenShift.

Ray Racine

unread,
May 15, 2012, 2:15:21 PM5/15/12
to Racket

Danny Yoo

unread,
May 15, 2012, 6:02:46 PM5/15/12
to Ray Racine, Racket

The DIY offering is pretty new with limited doc.

https://openshift.redhat.com/community/blogs/new-openshift-release-march-22-2012-nodejs-diy-cartridge-new-website-and-more

https://openshift.redhat.com/community/blogs/a-paas-that-runs-anything-http-getting-started-with-diy-applications-on-openshift

I'll create a github project and post it this evening if anyone wants to assist in creating a Racket Cartridge for OpenShift.

Oh!  Definitely interested! 

John Clements

unread,
May 15, 2012, 6:10:58 PM5/15/12
to Danny Yoo, Racket
Yes, I would love the ability to transparently deploy Racket servers. Here's the list of things that I can come up with off the top of my head:

- handin server
- grade server
- evaluation server for use with WebIDE

John Clements

Ray Racine

unread,
May 16, 2012, 9:53:50 PM5/16/12
to John Clements, Racket
Quick update.

I have a rough and simple bootstrap working.

Here to see it running. http://test-rpr.rhcloud.com/
Read the README here about the DIY scripts.  https://github.com/RayRacine/rackos
Read here if you want to bring run Racket's default page on OpenShift.  https://github.com/RayRacine/rackos/wiki/Quick-Start

Basically OpenShift's DIY is a v0.1 of a lifecycle of shell script hooks that are called whenever you push changes to your website/code via GIT to OpenShift.

One of the hooks is the pre_build script (called when you push new code, before the build script is called).
In pre_build, if Racket is NOT installed, Racket is auto downloaded rom racket-lang.org, installed it and started on your cloud instance. At the moment all you get is the default Racket WebServer home up and running.

See https://github.com/RayRacine/rackos/wiki/Quick-Start

Next step (not yet done) is to configure the Racket WebServer to servlet code location to some distinguished directory in the repository structure. 

Then you develop and test your web code locally and when ready Git commit and push it to OpenShift.  As soon as the push happens the scripts will restart the Racket Webserver auto-magically. Just keep pushing changes and they take effect immediately.

Tada your newly changed Racket web app is up and running on the internet. 

Ray Racine

unread,
May 16, 2012, 10:10:51 PM5/16/12
to Racket
One more thing of note.  Since the pre_build script is always run first in the cycle, one can assume that racket is installed and working henceforth.  So the rest of RackOS system, scripts, and hooks such 'start', 'stop', 'deploy' etc.. can be written in Racket.  Putting together the Bash script to bootstrap Racket was torture.  Should be easier now.

Sam Tobin-Hochstadt

unread,
May 17, 2012, 8:53:47 AM5/17/12
to Ray Racine, Racket, John Clements
Let me be the first to say that this is really cool!

On Wed, May 16, 2012 at 9:53 PM, Ray Racine <ray.r...@gmail.com> wrote:
> Tada your newly changed Racket web app is up and running on the internet.



--
sam th
sa...@ccs.neu.edu
____________________
Racket Users list:
http://lists.racket-lang.org/users

John Clements

unread,
May 17, 2012, 2:54:33 PM5/17/12
to Sam Tobin-Hochstadt, Racket

On May 17, 2012, at 5:53 AM, Sam Tobin-Hochstadt wrote:

> Let me be the first to say that this is really cool!

DItto. Followed instructions, got blank server running at

http://test-rackjbc.rhcloud.com

Neat!


Next step… understanding rhc.

Well, I just figured one thing out, which is that you need to configure ~/.openshift/express.conf to contain the name of the key you provided to the web interface. Should I add this to the github wiki?

John Clements

Reply all
Reply to author
Forward
0 new messages