diff options
Diffstat (limited to 'roles/sublab_web')
-rw-r--r-- | roles/sublab_web/handlers/as_webuser.yaml | 2 | ||||
-rw-r--r-- | roles/sublab_web/templates/website-rebuild.sh.j2 | 7 |
2 files changed, 6 insertions, 3 deletions
diff --git a/roles/sublab_web/handlers/as_webuser.yaml b/roles/sublab_web/handlers/as_webuser.yaml index 11e8074..48f2765 100644 --- a/roles/sublab_web/handlers/as_webuser.yaml +++ b/roles/sublab_web/handlers/as_webuser.yaml @@ -1,5 +1,5 @@ --- - name: Rebuild subweb website - shell: ./website-rebuild.sh + shell: ./website-rebuild.sh -l args: chdir: "/var/www/{{sublab_web_server_name}}" diff --git a/roles/sublab_web/templates/website-rebuild.sh.j2 b/roles/sublab_web/templates/website-rebuild.sh.j2 index 1e4bc0b..ac29e3d 100644 --- a/roles/sublab_web/templates/website-rebuild.sh.j2 +++ b/roles/sublab_web/templates/website-rebuild.sh.j2 @@ -4,8 +4,11 @@ # cd /var/www/{{sublab_web_server_name}}/htdocs -git fetch git://{{ groups['gitservers'][0] }}/website.git master -git reset --hard FETCH_HEAD + +if [ x"$1" != x"-l" ]; then + git fetch git://{{ groups['gitservers'][0] }}/website.git master + git reset --hard FETCH_HEAD +fi cd scripts python template.py python wikitemplate.py > ../../wiki-page.tmpl |