Webapp-Config: Difference between revisions

From Research
Jump to navigation Jump to search
(New page: Under Gentoo, installing a typcial web application is actually a two-step process: <br> 1) you '''emerge''' the application, which typically installs the app under '''/usr/share/webapps/'...)
 
No edit summary
Line 9: Line 9:
<br>
<br>
<br>
<br>
== Setting up Webapp-Config ==
First, we have the configuration-file '''/etc/vhosts/webapp-config''', which lets us specify the vhost-root (often simply '''/var/www/''<hostname>''''', but sometimes '''/srv/www/''<hostname>'''''.  The '''localhost''' will be different in the case where we actually use vhosts, which isn't too common for us; we tend to prefer individual, dedicated vserver-guests, with single-site web-serving in each).
First, we have the configuration-file '''/etc/vhosts/webapp-config''', which lets us specify the vhost-root (often simply '''/var/www/''<hostname>''''', but sometimes '''/srv/www/''<hostname>'''''.  The '''localhost''' will be different in the case where we actually use vhosts, which isn't too common for us; we tend to prefer individual, dedicated vserver-guests, with single-site web-serving in each).
<br>
<br>
Line 17: Line 18:
  vhost_server="apache"
  vhost_server="apache"
<br>
<br>
== Installing Applications ==
These commands will '''install''' apps under '''/var/www/localhost/htdocs/'''''<pkg_name>'', with the specific version mentioned at the end of command-line:
These commands will '''install''' apps under '''/var/www/localhost/htdocs/'''''<pkg_name>'', with the specific version mentioned at the end of command-line:


Line 24: Line 27:




Commands to upgrade (typical):
== Upgrading Installed Applications ==
 
Commands to '''upgrade''' (typical):


  webapp-config -U -d /gallery  gallery 2.2.5
  webapp-config -U -d /gallery  gallery 2.2.5
  webapp-config -U -d /mediawiki mediawiki 1.11.2
  webapp-config -U -d /mediawiki mediawiki 1.11.2
  webapp-config -U -d /awstats awstats 6.7-r2
  webapp-config -U -d /awstats awstats 6.7-r2
== Other webapp-config Commands ==
webapp-config --list-installs  ''can optionally follow this with <pkg_name., or <pkg_name pkg_version>''
webapp-config --list-unused-installs ''can optionally follow this with <pkg_name., or <pkg_name pkg_version>''
<br>

Revision as of 16:56, 4 December 2008

Under Gentoo, installing a typcial web application is actually a two-step process:
1) you emerge the application, which typically installs the app under /usr/share/webapps/<pkg_name>
2) you then perform a second-stage installation to your web-server doc-root, using webapp-config

Why? To support virtual-hosting, and multiple sites being served from a given host, where they may each require different package-versions. Here's how:

Setting up Webapp-Config

First, we have the configuration-file /etc/vhosts/webapp-config, which lets us specify the vhost-root (often simply /var/www/<hostname>, but sometimes /srv/www/<hostname>. The localhost will be different in the case where we actually use vhosts, which isn't too common for us; we tend to prefer individual, dedicated vserver-guests, with single-site web-serving in each).

Typical settings within the /etc/vhosts/webapp-config file:

vhost_root="/var/www/${vhost_hostname}"
vhost_hostname="localhost"
vhost_server="apache"


Installing Applications

These commands will install apps under /var/www/localhost/htdocs/<pkg_name>, with the specific version mentioned at the end of command-line:

webapp-config -I -h localhost -d /mediawiki  mediawiki 1.8.5
webapp-config -I -h localhost -d /gallery  gallery 2.2.3
webapp-config -I -h localhost -d /awstats awstats 6.5-r1


Upgrading Installed Applications

Commands to upgrade (typical):

webapp-config -U -d /gallery  gallery 2.2.5
webapp-config -U -d /mediawiki mediawiki 1.11.2
webapp-config -U -d /awstats awstats 6.7-r2

Other webapp-config Commands

webapp-config --list-installs  can optionally follow this with <pkg_name., or <pkg_name pkg_version>
webapp-config --list-unused-installs can optionally follow this with <pkg_name., or <pkg_name pkg_version>