From 76c59ce7451e88cb1e1d4e4f01067d8cea853f6d Mon Sep 17 00:00:00 2001 From: Daniel Molina Date: Tue, 23 Jun 2015 13:28:30 +0200 Subject: [PATCH] feature #3748: Define dev and prod envs for sunstone prod will pull the minified app.js dev will pull all the modules one by one --- src/sunstone/etc/sunstone-server.conf | 6 ++++++ src/sunstone/views/index.erb | 7 +++++++ 2 files changed, 13 insertions(+) diff --git a/src/sunstone/etc/sunstone-server.conf b/src/sunstone/etc/sunstone-server.conf index 3aa2fdd836..3703733768 100644 --- a/src/sunstone/etc/sunstone-server.conf +++ b/src/sunstone/etc/sunstone-server.conf @@ -44,6 +44,12 @@ :memcache_port: 11211 :memcache_namespace: opennebula.sunstone +# Excution environment for Sunstone +# dev, Instead of pulling the minified js all the files will be pulled (app/main.js) +# NOTE. src/sunstone/public must be symlinked to /var/lib/one/ruby/sunstone/public +# prod, the minified js will be used (dist/main.js) +:env: 'prod' + ################################################################################ # Log ################################################################################ diff --git a/src/sunstone/views/index.erb b/src/sunstone/views/index.erb index ec9ab57876..e536f316e7 100644 --- a/src/sunstone/views/index.erb +++ b/src/sunstone/views/index.erb @@ -158,5 +158,12 @@
+ + + <% if $conf[:env] == 'dev' %> + + <% else %> + + <% end %>