Tag Info

Hot answers tagged

31

The fastest and easiest is to use a version directory such as /var/www/version/01 /var/www/version/02 and use a current symbolic link as your html_root : /var/www/html -> /var/www/version/02 This technique integrate perfectly into a revision control system (svn, git, mercurial, ...) as you can checkout branches & tags, changes the symbolic link ...


13

Renaming the directories without shutting Apache down should work as well. That will shorten the window significantly. mv public_html public_html_old && mv public_html_new public_html should finish in a fraction of a second. A couple of drawbacks are that this approach will give a 404 to any request that still manage to happen during the window. And ...


12

Using a load balancer is a good idea. If the site is important enough to worry about a few seconds of downtime, it's important enough to worry about fault tolerance. That aside, if this is on a UNIX system you can put Apache on hold during the rename (or symlink update, etc.): killall -STOP httpd # Pause all httpd processes mv public_html public_html_orig ...


10

Symlinks and mv are your friends, however, if you really need to avoid end-users getting an error page while deploying a new version, you should have a reverse-proxy or a load-balancer in front of at least 2 backend servers (apache in your case). During the deploy, you just need to stop one backend at a time, deploy the new code, restart it and then iterate ...


9

If you are applying changes regularly on a production system, I would take care of a structured life cycle. A good practice is Capistrano http://capistranorb.com/. This is a an open source solution for deploying software on one or more servers on several platforms and configurations. For Magento there is even a plugin: ...


4

The way I do it is do commit my changes from my local dev environment to an online Git repository such as Github. My production environment runs off a remote repository so all I need to do is ssh to the server and run git pull to bring down the latest changes. No need to stop your webserver. If you have files in your project whose settings and/or content ...


3

You are trying to install the httpd package, containing version 2.2 of Apache, but you already have httpd24, containing version 2.4 of Apache, installed. Before doing anything else, first decide which version you actually want.


3

My first idea is: # deploy into public_html_new, and then: rsync -vaH --delete public_html_new/ public_html/ A good solution were to use rsync. It changed only the really changed files. Beware, the slashes at the end ot the pathes are here important. Normally apache don't need a restart, it is not the java world. It checks for the change of every php ...


2

You do not need it. I just checked on a server with over a hundred apache virtual domains, none of them have ServerAdmin defined. The ServerAdmin is commented out in the main config file (httpd.conf) and I guess there hasn't been a problem so far. In fact it seems like apache no longer displays the ServerAdmin in any event?


1

You have multiple options, none of which are ideal: Maybe you're lucky and only a couple of non-overlapping folders are used in the root of each application and you can simply add multiple ProxyPass directives. Redeploy ActiveMQ and Accumulo so that they're no longer installed in the root but in a subfolder. Use subdomains for each application such as ...


1

Moving/replacing the http_public folder can be achieved with simple mv or ln -s commands or equivalent while your http server keeps running. You can do some scripting to significantly reduce the downtime, but check carefully the return codes of your commands in the script if you automate the process. That said, if you want to achieve no downtime, you ...


1

According to the documentation on Apache....The directives you state will always result in denial..reasons: Directive order deny,allow analyzes deny directives FIRST then allow directives. Your deny from all directive matches everybody and thus due to #1 nobody gets access. Your 0.0.0.0 IP number will not match everybody, thus your allow statement is not ...



Only top voted, non community-wiki answers of a minimum length are eligible