A few days ago I received an email notifying Aptana Cloud Service Termination at midnight on October 31, 2010.
Period. Sigh. :(
As early adopter (2008) about Jaxer technology and team supporter in the old forum (1000+ posts), I am quite sad.
However the show must go on and I found some hints in Aptana Cloud Migration Notes.
In this post I am glad to give you a feedback about the first steps of my migration experience.
My Cloud Server configuration is quite simple: Subversion repository, Apache HTTP Server and Jaxer JavaScript server. I have one main application deployed and other stuff I consider secondary. Fortunately I have been using an external CouchDB instance as persistence layer.
The migration approach has only one principle: moving off in time minimizing the problems. After the migration I will have plenty of time to do the things with bells and whistles.
The repository is the first target. I have no secrets in the source code, but I cannot share a few api keys contained in the backend. Maybe I will change it, but, in the meantime, I cannot use a public repository.
Because I have been developing with Yahoo! User Interface (YUI) library and I intend to contribute to the YUI gallery, I have a GitHub account. I upgraded my free plan to micro one (7$/month) to create private repositories.
How to import a Subversion Repository?
GitHub offers some solutions, but I have the following thought: in the last two years I didn't compare any trunk version with a tagged one. In that case I might browse my backups. So I preferred to take the latest status of svn repo and to push it to git one. Fast, simple and no problems.
Repository issue is gone. Now I have Apache and Jaxer issues.
I have been looking for a VPS hosting. I spent a lot of time comparing VPS hosting providers and reading reviews. I am not a VPS expert and my needs are simple.
I would be oriented about Webbynode provider: 9.99$/month for Webby 256 plan. Please no flame, there are many good solutions. :) I can always change in the future and, at the moment, I need something cheap and simple to manage.
Before to buy the plan, I would like to replicate on a local machine my configuration.
I have a Windows 7 box. It comes with Windows Virtual PC installed. I suppose you could use Virtual Box too.
I downloaded the PC (Intel x86) server install CD (10.04.1) from Ubuntu. I created a virtual machine with 256Mb of memory and installed the server image. Don't forget to set correctly the network adapter in the settings. There is no integration components for Linux guest, allowing disk sharing, but I don't need it: I have to simulate a VPS hosting box.
The installation had no issues, but when I rebooted for the first time I could not see the login prompt, because the display was scrambled. I rebooted and pressed left shift to enter in Grub menu: I added at the end of kernel line "vga=785" (without quotes, it means 640x480 with depth 16) and rebooted. The display was nice and after the logon I added "vga=785" in GRUB_CMDLINE_LINUX variable contained in "/etc/default/grub" file.
Of course this change is only for the local machine, no need for a remote machine. I will login to the VPS hosting box with a terminal emulator.
I upgraded to the latest fixes with "apt-get upgrade" and rebooted.
An Ubuntu server box was up and running with 256Mb RAM and networking capabilities.
I enabled the firewall and opened a few ports, remembering if you enable the firewall before allowing ssh port you are lock out:
sudo ufw allow 22
sudo ufw enable
sudo ufw allow 8081
sudo ufw allow 80
I installed the ssh server (I imagine in the VPS hosting box it is installed):
sudo apt-get install openssh-server
I installed "firefox" package (server side?) because Jaxer needs many shared libraries contained in that package:
sudo apt-get install firefox
Please, you should create a directory structure you like: I don't annoy you with change directory commands. I hope the context is clear for the following commands.
I downloaded the latest Jaxer version (1.0.3.4547):
wget http://release.aptana.com/jaxer-standalone/latest/linux32/Jaxer_package_withApache.tar.gz
Unpacked Jaxer:
tar xvf Jaxer_package_withApache.tar.gz
I changed directory to "AptanaJaxer/scripts" directory and started Apache and Jaxer instances:
./start.sh
I opened the browser in Windows and tested the server installation:
http://ip_address_of_the_server:8081
It should be redirected to
http://ip_address_of_the_server:8081/aptana/
Aptana Jaxer homepage is displayed.
Then in "AptanaJaxer/Apache22/conf/httpd.conf" file I changed the port from 8081 to 80 and added the User directive:
... Listen 80
... ServerName localhost:80
... User www-data
I stopped the instances. Then I restarted Apache and Jaxer instance with root permission because a user without admin rights could not bind 80 port:
sudo ./start.sh
"http://ip_address_of_the_server" should work nice.
You can logout: Apache and Jaxer instances continue running correctly.
This is the end of story.
I deployed my application to local box using rsync and, adding a coherent symbolic link in "AptanaJaxer/public" directory to the application one, I could use the same url of my actual Aptana Cloud instance (but ip address, of course).
Mission accomplished.
It is not the professional configuration you can find in Aptana Cloud instance, but it works nice.
The next step would be replicate the above steps in the VPS hosting box, adding a few security steps and changing the DNS.
That's all, folks.
Eventually we added a Dashboard tab.
There are stats of all portfolios created by the users: last created portfolios, best/worst performing, high/low risk profile and high/low return profile portfolios. Every time a portfolio is optimized, it is added to the repository. You can refresh the Dashboard switching to Basket tab and coming back again.
Hovering on the portfolio id, a tooltip is displayed, containing performance, risk (the standard deviation of the portfolio returns) and return of the portfolio.
Enjoy!
After two years of development, ConPA, an asset allocation application, achieves the stable state.
The main features are portfolio optimization with constraints, portfolio simulation, pie and performance charts, year to date graph, key statistics and implied volatility graph. Thanks to Yahoo! User Interface library and Yahoo! Finance.