Exit Print View

Sun GlassFish Enterprise Server v3 Scripting Framework Guide

  This Document Entire Library
Print View

Document Information

Preface

1.  Using JRuby on Rails With Sun GlassFish Enterprise Server

2.  Developing Grails Applications

Introduction to Groovy and Grails

Installing Grails

To Install the Grails Module

Creating a Simple Grails Application

To Create the helloworld Application

To Create the hello Controller

Deploying and Running a Grails Application

To Run a Grails Application Using Standard Deployment

3.  Jython on Django

4.  Scala and Lift

5.  PHP

Installing Grails

Grails is available as an IPS package from GlassFish Update Center. To develop and deploy Grails applications on the Enterprise Server, you must first install the Grails module.

To Install the Grails Module

  1. Install the Grails add-on component that is available from the Update Tool.

    For information about the Update Tool, see the Sun GlassFish Enterprise Server v3 Installation Guide.

  2. Create a GRAILS_HOME environment variable that points to the Grails directory, as-install/grails.

  3. Add the as-install/grails/bin directory to the PATH environment variable.

Setting UNIX Environment Variables

On Solaris, Linux, and other operating systems related to UNIX, use the following commands for Steps 2 and 3 from the above procedure:

set GRAILS_HOME=as-install/glassfish/grails
export GRAILS_HOME
cd $GRAILS_HOME
set PATH=$GRAILS_HOME/bin:$PATH
export PATH
chmod a+x $GRAILS_HOME/bin/*
Setting Windows Environment Variables

On the Windows operating system, use the following commands for Steps 2 and 3 from the above procedure:

set GRAILS_HOME=C:\GlassFish\grails
set PATH=%GRAILS_HOME%\bin;%PATH%