Browse code

use the current user instead of stack for dash

Jesse Andrews authored on 2011/09/28 10:26:27
Showing 2 changed files
... ...
@@ -1,8 +1,8 @@
1 1
 <VirtualHost *:80>
2 2
     WSGIScriptAlias / %DASH_DIR%/openstack-dashboard/dashboard/wsgi/django.wsgi
3
-    WSGIDaemonProcess dashboard user=stack group=stack processes=3 threads=10
4
-    SetEnv APACHE_RUN_USER stack
5
-    SetEnv APACHE_RUN_GROUP stack
3
+    WSGIDaemonProcess dashboard user=%USER% group=%USER% processes=3 threads=10
4
+    SetEnv APACHE_RUN_USER %USER%
5
+    SetEnv APACHE_RUN_GROUP %USER%
6 6
     WSGIProcessGroup dashboard
7 7
 
8 8
     DocumentRoot %DASH_DIR%/.blackhole/
... ...
@@ -241,6 +241,7 @@ if [[ "$ENABLED_SERVICES" =~ "dash" ]]; then
241 241
 
242 242
     ## Configure apache's 000-default to run dashboard
243 243
     sudo cp $FILES/000-default.template /etc/apache2/sites-enabled/000-default
244
+    sudo sed -e "s,%USER%,$USER,g" -i /etc/apache2/sites-enabled/000-default
244 245
     sudo sed -e "s,%DASH_DIR%,$DASH_DIR,g" -i /etc/apache2/sites-enabled/000-default
245 246
 fi
246 247