To check out this repository please hg clone the following URL, or open the URL using EasyMercurial or your preferred Mercurial client.
root / deploy / provision.d / 040-hg-dir.sh @ 1598:073a75bf07fb
History | View | Annotate | Download (497 Bytes)
| 1 | 1577:e38eee2e1d47 | Chris | #!/bin/bash |
|---|---|---|---|
| 2 | |||
| 3 | set -e |
||
| 4 | |||
| 5 | 1589:94669513c53c | Chris | # In a real deployment, /var/hg is probably mounted from somewhere |
| 6 | # else. But in an empty deployment we need to create it, and in both |
||
| 7 | # cases we set up the config files with their current versions here. |
||
| 8 | |||
| 9 | 1577:e38eee2e1d47 | Chris | if [ ! -f /var/hg/index.cgi ]; then |
| 10 | mkdir -p /var/hg |
||
| 11 | fi |
||
| 12 | 1589:94669513c53c | Chris | |
| 13 | cp /var/www/code/deploy/config/index.cgi /var/hg/ |
||
| 14 | cp /var/www/code/deploy/config/hgweb.config /var/hg/ |
||
| 15 | |||
| 16 | chmod +x /var/hg/index.cgi |
||
| 17 | |||
| 18 | 1590:c18460da6620 | Chris | chown -R www-data.code /var/hg |
| 19 | 1589:94669513c53c | Chris | find /var/hg -type d -exec chmod g+s \{\} \;
|