Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
..
Failed to load latest commit information.
bin/ext
classes
images
pages
script
style
CloudSidekick.sln
Default.aspx
Default.aspx.cs
Default.aspx.designer.cs
INSTALL
LICENSE
NOTICE
README
TODO
Web.config
Web.csproj
buildcato.sh
default.htm
login.aspx
login.aspx.cs
login.aspx.designer.cs

README

Cloud Sidekick Cato Web Application

------------------------------------------
Description
------------------------------------------

The Cato automation toolkit consists of 3 major components: webserver, 
database and task engine. This document covers the Web Application component.  

The Cato Web Application allows a user to manage the Cato configuration, including:
- creation and scheduling Cato Tasks
- management of Cloud Ecosystems and Templates
- management of Cloud Accounts
- management of Users

The Cato Web Application is written in C#, making extensive use of the jQuery javascript library.

This document will cover:
- opening, building and debugging the project using the MonoDevelop IDE
- building the project at the command line
- installing the web application in Apache

------------------------------------------
Repository and Download
------------------------------------------

https://github.com/cloudsidekick/cato

------------------------------------------
Bug and Feature Requests
------------------------------------------

https://github.com/cloudsidekick/cato/issues

------------------------------------------
Requirements
------------------------------------------

The Cato Web Application requires the Mono to be installed and configured on 
the target machine.  The current Mono version as of this writing is 2.10.5.  
While the Cato Web Application may build with previous versions of Mono, 
it has been tested using 2.10.5.

For Ubuntu / Debian linux, to install the minimum Mono requires to build, perform 
the following command:

	sudo apt-get update
	sudo apt-get install mono-devel mono-gmcs

Other Linux distributions may have Mono pre-installed or prebuilt packages.  
The latest Mono can be downloaded from:

http://www.go-mono.com/mono-downloads/download.html

Mono sources can be obtained at the following location:

http://origin-download.mono-project.com/sources/mono/

Build and/or install Mono according to the instructions for your platform.

While the Web Application can be modified and built from the command line, 
since it is an ASP.NET application, it is strongly recommended that any 
changes be made using MonoDevelop - the Mono IDE.  Using MonoDevelop 
ensures all project references and .aspx/.cs "codebehind" references 
remain intact, and that collaborative efforts are uniform.

MonoDevelop can be downloaded from:
http://www.mono-project.com


------------------------------------------
Building at the Command Line
------------------------------------------

See the Requirements section above first for the Mono install instructions. 

For building a run time installation of Cato hosted with Apache, the 
MonoDevelop IDE is not required.  If it is desired to make changes to the 
Web Application source code, skip this section and follow the steps for 
Building and Testing in MonoDevelop.

1. Confirm Mono installation and version.

At the command line, type:

	which mono

Typical installation will be in /usr/bin/mono.  Verify the version using:

	mono --version

Confirm the version is at least 2.10.5.

2. Prepare the build using the configure command:

	cd <source location>/web

3. Build the solution:

	./buildcato.sh

4. Confirm the build was successful by verifying the existence and timestamp of bin/Web.dll:
	
	ls -l bin/Web.dll

5. Either proceed with the services build or perform the installation steps 
found in the INSTALL file found in the base install directory. 

------------------------------------------
Additional Information: Configuring Apache for Mono Applications
------------------------------------------

A typical Cato install will make use of the Apache v2 web server to host the Cato Web Application.
By default, Apache does not include the Mono "module" called mod_mono.

If the build steps above were successful then Mono is installed on the system, but that doesn't necessarily
mean the Apache mod_mono module is installed.

1. Confirm the mod_mono module is installed.  mon_mono is a library that may reside in different locations
depending on how Mono was installed.  Rather than look for mod_mono.so, it's easier to just look 
at the Apache configuration files and ensure it is enabled.

Find the Apache 2 configuration files, typically in /etc/apache2.  In either apache2.conf (possibly httpd.conf),
there should be a line similar to this:

	LoadModule mono_module /usr/libexec/apache2/mod_mono.so

Note: on some Mono installations, all the Mono configuration is in a separate file called mod_mono.conf.  If that file
exists, it will take care of all the necessary configuration, provided it is Included in the apache2.conf (or httpd.conf).
Apache typically includes optional .conf files with a line similar to this:

	Include /etc/apache2/other/*.conf

2. Apache needs to be told exactly where the Cato Web Application files are, as well as how to handle them.
Assuming Cato Web is in /opt/cato/web, add the following entries to the bottom of the apache2.conf (or httpd.conf) file.

	MonoApplications "/cloudsidekick:/opt/cato/web"
	<Location /cloudsidekick>
	      SetHandler mono
	</Location>

------------------------------------------
Additional Information: Building and Testing in MonoDevelop
------------------------------------------

For working with the source code to make enhancements or fix reported issues, an Apache/mod_mono configuration 
is not required.  Development and testing can be done entirely in MonoDevelop.

MonoDevelop has an integrated test web server called XSP, so the Application can be tested 
with no additional requirements.

The Web Application shares the same cato.conf configuration file as the Cato services.  This file
is located outside the web root, so a symbolic link must be created to access it.

(Assuming Cato source was unpacked into <home>/cato)

1. If you have not already done so, follow the steps in the main INSTALL document to create
your specific cato.conf file. 

2. Create a symbolic directory link using the following command:

	ln -s <home>/cato/conf <home>/cato/web/conf

3. Open <home>/cato/web/CloudSidekick.sln in the MonoDevelop IDE.

4. From the "Build" menu, select "Build All".  The solution should build without errors.
Build success can be determined by the creation of the Web.dll file in <home>/cato/web/bin.

5. To test the Application, select "Run" from the menu.  The XSP web server process will start,
and MonoDevelop should open an instance of the default web browser configured on your system.

If all is well, the Cato login page will appear.  For this initial login, use "Administrator"
as the Username, and the password that was selected during the steps of the main INSTALL document.