You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by Apache Wiki <wi...@apache.org> on 2006/01/18 03:45:15 UTC

[Myfaces Wiki] Update of "Apache Server" by schof

Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Myfaces Wiki" for change notification.

The following page has been changed by schof:
http://wiki.apache.org/myfaces/Apache_Server

New page:
=== Apache Server Configuration (Solaris Zone) ===

* The zone comes with apache2 already available
* Follow the initial setup instructions from the ASF zone page (http://www.apache.org/dev/solaris-zones.html)
* Create a SMF manifest for apache (so it can run as a service)

# mkdir /var/svc/manifest/application/web
# vi /var/svc/manifest/application/web/apache.xml

* Add the following text

<?xml version="1.0"?>
<!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">

<service_bundle type='manifest' name='apache'>

<service name='application/web/apache' type='service' version='1'>
   <create_default_instance enabled="true"/>
   <single_instance />

   <dependency
      name='filesystem'
      grouping='require_all'
      restart_on='none'
      type='service'>
      <service_fmri value='svc:/system/filesystem/local' />
   </dependency>

   <exec_method
      type='method'
      name='start'
      exec='/usr/apache2/bin/apachectl start'
      timeout_seconds='120' />

   <exec_method
      type='method'
      name='stop'
      exec='/usr/apache2/bin/apachectl stop'
      timeout_seconds='120' />

   <exec_method
      type='method'
      name='restart'
      exec='/usr/apache2/bin/apachectl restart'
      timeout_seconds='120' />

   <stability value='Unstable' />

   <template>
      <common_name>
         <loctext xml:lang='C'>Apache2(httpd)</loctext>
      </common_name>
      <documentation>
         <manpage title='httpd' section='8'/>
      </documentation>
   </template>

</service>
</service_bundle>

* Verify the validity of the xml file (command should run with no errors)

# svccfg -v validate apache.xml

* If you get a cryptic parse error you can try running the following to track it down

# xmllint --valid apache.xml

* Now import the manifest

# svccfg -v import apache.xml

* Check that the service was added (it should show it as disabled)

# svcs -v apache

* Now enable the service

# svcadm enable apache

* Verify that everything is started

# svcs -v apache ''should show enabled''

* Check http://zones.myfaces.apache.org/