Description of problem: Assets are not precompiled; production.log is full of INFO-level "Compiled XY" messages. Version-Release number of selected component (if applicable): 5.4.0.0.13 How reproducible: Always Steps to Reproduce: - Actual results: Assets are not precompiled. Expected results: Assets should be precompiled in the build. Additional info: ... [----] I, [2015-03-24T14:45:38.025683 #2284:130dea4] INFO -- : Compiled less.min.js (3ms) (pid 2284) [----] I, [2015-03-24T14:45:44.073037 #2284:130dea4] INFO -- : Compiled miq_jquery_ujs_rails3.js (0ms) (pid 2284) [----] I, [2015-03-24T14:45:44.297898 #2284:130dea4] INFO -- : Compiled jquery.form.js (0ms) (pid 2284) [----] I, [2015-03-24T14:45:44.680239 #2284:130dea4] INFO -- : Compiled jquery.cookie.js (0ms) (pid 2284) [----] I, [2015-03-24T14:45:44.869243 #2284:130dea4] INFO -- : Compiled dhtmlx_gpl_36/dhtmlxcontainer.js (1ms) (pid 2284) [----] I, [2015-03-24T14:45:45.552775 #2284:130dea4] INFO -- : Compiled dynatree_1.2.4/jquery.dynatree.js (1ms) (pid 2284) [----] I, [2015-03-24T14:45:46.365702 #2284:130dea4] INFO -- : Compiled miq_dynatree.js (0ms) (pid 2284) ...
Created attachment 1005996 [details] Precompile output in dev setup in production environment included/excluded assets from precompilation
According to this [1], we precompile all assets in app/assets to public/assets that are NOT *.js or *.css. The only .js or css that are precompiled are productization.js, productization.css, application.js, application.css. [1] https://github.com/ManageIQ/manageiq/blob/master/vmdb/lib/vmdb/productization.rb#L30-31 Dan, can you have someone confirm that none of the items excluded from precompile are needed to be precompiled? I don't know WHY all js and css are excluded but NOT application and productization. I ran this locally after linking in the cfme_productization master branch with my current upstream master and attached the output. DEBUG_PRECOMPILE=true RAILS_ENV=production be rake assets:clean assets:precompile
At this point, it appears the build rpm seems to be following the rule as mentioned in comment 3. Once we know what is supposed to be compiled, we can make sure the build results comply with any changes to the rules as to what gets precompiled.
New commit detected on manageiq/master: https://github.com/ManageIQ/manageiq/commit/1b2273f45111ff31e54758b054228e35f6a4a746 commit 1b2273f45111ff31e54758b054228e35f6a4a746 Author: Dávid Halász <dhalasz> AuthorDate: Tue Mar 31 15:31:31 2015 +0200 Commit: Dávid Halász <dhalasz> CommitDate: Tue Mar 31 15:35:20 2015 +0200 Moved separately included JS files into application.js with //= require https://bugzilla.redhat.com/show_bug.cgi?id=1205386 vmdb/app/assets/javascripts/application.js | 22 ++++++++++++++++++++ vmdb/app/views/layouts/_global_header.html.haml | 26 ------------------------ vmdb/app/views/layouts/application.html.haml | 1 - vmdb/app/views/layouts/login.html.haml | 16 --------------- vmdb/app/views/vm_common/console_spice.html.haml | 1 - vmdb/app/views/vm_common/console_vnc.html.haml | 1 - 6 files changed, 22 insertions(+), 45 deletions(-)
Verified in 5.4.0.0.24.20150427192818_1fd9e49
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHBA-2015-1100.html