Permalink
Browse files

Merge pull request #1 from elbaschid/master

Added missing requirement and removed hardcoded landmark path
  • Loading branch information...
2 parents 0c54084 + 6d29973 commit 1dad1ca11d00a13ed59de03fda1ef557d327b28f @codeinthehole codeinthehole committed May 15, 2012
Showing with 7 additions and 5 deletions.
  1. +1 −0 fabconfig.py
  2. +5 −5 fabfile.py
  3. +1 −0 www/deploy/requirements.txt
View
@@ -21,6 +21,7 @@
# Environment-agnostic folders
env.project_dir = '/var/www/%(client)s/%(project_code)s' % env
+env.static_dir = '/mnt/static/%(client)s/%(project_code)s' % env
env.builds_dir = '%(project_dir)s/builds' % env
def _configure(build_name):
View
@@ -204,13 +204,13 @@ def set_robots_and_sitemaps():
notify("Setting robots.txt and sitemaps")
with cd(env.builds_dir):
# create the proper symlinks to sitemaps and robots.txt
- sudo("mkdir -p /mnt/static/landmark/%(build)s/sitemaps" % env)
- sudo("""if [ -d /mnt/static/landmark/%(build)s/robots.txt ]; then
- cp %(build_dir)s/static/robots.txt /mnt/static/landmark/%(build)s/;
+ sudo("mkdir -p %(static_dir)s/%(build)s/sitemaps" % env)
+ sudo("""if [ -d %(static_dir)s/%(client)s/%(build)s/robots.txt ]; then
+ cp %(build_dir)s/static/robots.txt %(static_dir)s/%(client)s/%(build)s/;
fi;""" % env)
with cd("%(build_dir)s/public/static/" % env):
- sudo("rm -rf sitemaps && ln -s /mnt/static/landmark/%(build)s/sitemaps sitemaps" % env)
- sudo("rm robots.txt && ln -s /mnt/static/landmark/%(build)s/robots.txt robots.txt" % env)
+ sudo("rm -rf sitemaps && ln -s %(static_dir)s/%(build)s/sitemaps sitemaps" % env)
+ sudo("rm robots.txt && ln -s %(static_dir)s/%(/%(build)s/robots.txt robots.txt" % env)
def update_virtualenv():
"""
@@ -5,3 +5,4 @@ django-debug-toolbar==0.9.4
django-extensions==0.7.1
python-memcached==1.47
Fabric==1.4.0
+django_compressor==1.1.2

0 comments on commit 1dad1ca

Please sign in to comment.