I’ve finally got time to play and install OpenShift Origin as my Personal PaaS. The installation went very smoothly except for a couple of hiccups. I’m using two CentOS VMs – one for broker and one for node. Apart from default cartridges for PHP, Python and NodeJS, I have also installed support for Clojure and Haskell apps. So I can have the nice workflow of git-push-to-deploy for my apps!
Now for the hiccups during installation:
After installing every app I created got into a redirect loop to getting_started.html. This was fixed by adding these lines:
# Set headers for the forward
RequestHeader set X-Forwarded-Proto "http"
RequestHeader set X-Forwarded-Port "80"
# Access the OpenShift mod_rewrite router
to *:80 vhost in /etc/httpd/conf.d/000001_openshift_origin_frontend_vhost.conf
I wasn’t able to create a new app using (e.g. clojure cartridge) manifest. This was fixed by installing unzip – which was apparently missing on the node server.
The Clojure/Java app won’t start and keeps throwing class not found exceptions Apparently Node CentOS VM was using gcj (WTF!!??). Installing OpenJDK fixed this.
I couldn’t delete any apps either using rhc or using oo-admin-* scripts. This fails with message : “Can only supply discovery data if direct_addressing is enabled”
This was fixed by adding the line
Hope this helps if someone is facing similar issues during installation.
After a recent update I was unable to login to Google Hangouts on iPhone. The app asks me for username and password and then shows a dialog with authentication error with “Remove this account” and other options. My account is a Google Apps based account and not a generic @gmail.com.
Here’s how I was able to fix it.
- Login to https://admin.google.com/AdminHome
- Click on “More Controls” at the bottom
- In the list at the bottom, click “Other Google Services”
- In “Other Google Services” click the filter icon on top left.
- Uncheck the “Show top featured services”
- Search for “Google Voice” and click on the link.
- In the “Settings for Google Voice” click the drop down under the icon and select “ON for everyone”
This should fix the login issues with Google Hangouts on iOS.
Here’s a cool trailer of a Clojure project I’m working on in collaboration with Bradley Pitts Studio. Stay tuned for more info!
Last saturday I participated in the first Edition of Dutch Clojure Day. I was not only attending the event I also helped a bit in organising the event, by creating the website.
It was a lot of fun with very interesting people with different levels of clojure experience – from the first timers to the companies who had their (pretty much) entire stack based on Clojure. I also gave a small lightening intro to Pedestal. We had great talks by Michał Marczyk about clojure.rrb-vector and a “live-action” core.async talk by Meikel Brandmeyer. Later in the evening Andrii Mishkovskyi from Screen6 explained the good and not-so-good parts of using Storm. The day ended with Adgoji CEO Alexander van Elsas gave an impression of clojure from the business point of view and their experience in moving to a complete Clojure stack. We intend to post the videos of all the talks very soon.
There was also an unconference where attendees split up into groups to discuss a variety of topics ranging from Clojure + Node Webkit, core.asnyc, javelin etc.
Here are some photos from the event.
Last weekend I participated in Clojure Cup 2013 – an online programming competition for Clojure/Clojure Script Programmers. My entry was a web application for browsing Datomic schema. It was built using Pedestal Framework – Here’s a screenshot of the application:
Though I didn’t achieve all the goals for the weekend, I made a decent progress by finishing:
• Frontend app using Pedestal.
• Designing FE using Bootstrap 3.
• Backend using Pedestal Service.
• Fetching Datomic attributes listing and rendering them in the FE using Server Sent Events.
• Package the app into a runnable JAR.
• Create a decent “marketing” site!
I’ve been learning Clojure for sometime now, and recently worked full-time on a real project, but Pedestal is a completely new framework for me. My initial plan was to create a “traditional” web application with Datomic browsing features, but I decided that it wasn’t challenging enough. So I started hacking using Pedestal, I followed the Pedestal tutorial and was able to make some good progress on the app.
Pedestal has been a completely different type of framework than the ones that I’m used to. It is optimised for highly interactive/collaborative applications. This was a completely new experience from me – since most of the applications that I built so far are request/response or (REST) based. One particular feature that blew me away was the recording functionality of Pedestal – which lets you record the “message flow” and replay to see how it effects the application. Also the complete decoupled workflow of the Frontend and Backend. While I was coding the front-end I didn’t write a single line of back-end code and kept working with simple simulated services. Once I was done with Frontend, switched to backend and linking them up was extremely easy.
There was one thing that tripped me off – templates in Pedestal. I think I need more time to grok it properly. Good part of my 48hours of hacking was spent making the tooling page not to throw NPE after I started slicing templates. But given that the framework is fairly new (v 0.2) I expect it will become more flexible and easy to work with down the lane.
Back to my app – it is named Vizier – named after Hindi-arabic-egyptian word for chief advisor to a king. Infact, in Chess the Queen is used to be a Vizier. I intend to continue developing the app and hopefully make it a complete Datomic management app. Checkout the Trello Board I used during the development of it.
Version 0.0.1 of Vizier is available for download – so checkout it out. If you like it, don’t forget to Vote for it on clojure cup!
I took my first flying lesson today at EHRD, I was able to keep the flight steady – my hours spent playing Flight simulator were helping more than I thought. I was a bit nervous while banking and wasn’t ready to go beyond 20 degrees – but overall the lesson was awesome and the instructor was re-assuring and patient. I intend to take more lessons and eventually get my PPL.