Studio site fails to load static elements after git pull from my own edx-platform fork

551 views
Skip to first unread message

Paras Doshi

unread,
Apr 10, 2014, 10:59:51 PM4/10/14
to edx-...@googlegroups.com
Hello,

I forked the edx repo and made some changes to it. When I pull that code on my production server the LMS works fine, but the studio fails to load static elements while rendering the page. If I change the code back to edx-platform master and restart LMS-CMS, things become fine again. My changes include adding some views for something that I am trying out. Nothing major. Can someone please let me know if they have faced a similar issue? 

Thanks,
Paras

Paras Doshi

unread,
Apr 14, 2014, 3:28:37 AM4/14/14
to edx-...@googlegroups.com
When I access the logs I get these messages after access the studio page. Static elements likess the css files are not getting resolved. 

==> /edx/var/log/nginx/access.log <==
202.177.243.230 - - [14/Apr/2014:07:24:32 +0000] "GET /img/hiw-feature1.png HTTP/1.1" 404 3555 "http://54.225.187.31:18010/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1847.116 Safari/537.36"

==> /edx/var/log/cms/edx.log <==
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][django.request][env:sandbox] WARNING [ip-10-184-146-250  9318] [base.py:142] - Not Found: /img/hiw-feature2.png
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9318] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-vendor.css: The file 'css/cms-style-vendor.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x57bd990>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9318] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-vendor-tinymce-content.css: The file 'css/cms-style-vendor-tinymce-content.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x57bd990>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9318] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-vendor-tinymce-skin.css: The file 'css/cms-style-vendor-tinymce-skin.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x57bd990>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9318] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-app.css: The file 'css/cms-style-app.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x57bd990>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9318] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-app-extend1.css: The file 'css/cms-style-app-extend1.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x57bd990>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9318] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-xmodule.css: The file 'css/cms-style-xmodule.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x57bd990>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][edxmako.shortcuts][env:sandbox] WARNING [ip-10-184-146-250  9318] [shortcuts.py:56] - Cannot find corresponding link for name: TOS
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][edxmako.shortcuts][env:sandbox] WARNING [ip-10-184-146-250  9318] [shortcuts.py:56] - Cannot find corresponding link for name: PRIVACY

==> /edx/var/log/nginx/access.log <==
202.177.243.230 - - [14/Apr/2014:07:24:32 +0000] "GET /img/hiw-feature2.png HTTP/1.1" 404 3555 "http://54.225.187.31:18010/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1847.116 Safari/537.36"

==> /edx/var/log/cms/edx.log <==
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][django.request][env:sandbox] WARNING [ip-10-184-146-250  9319] [base.py:142] - Not Found: /img/hiw-feature3.png
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9319] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-vendor.css: The file 'css/cms-style-vendor.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x58c3d90>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9319] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-vendor-tinymce-content.css: The file 'css/cms-style-vendor-tinymce-content.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x58c3d90>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9319] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-vendor-tinymce-skin.css: The file 'css/cms-style-vendor-tinymce-skin.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x58c3d90>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9319] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-app.css: The file 'css/cms-style-app.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x58c3d90>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9319] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-app-extend1.css: The file 'css/cms-style-app-extend1.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x58c3d90>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][static_replace][env:sandbox] WARNING [ip-10-184-146-250  9319] [__init__.py:40] - staticfiles_storage couldn't find path css/cms-style-xmodule.css: The file 'css/cms-style-xmodule.css' could not be found with <pipeline.storage.PipelineCachedStorage object at 0x58c3d90>.
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][edxmako.shortcuts][env:sandbox] WARNING [ip-10-184-146-250  9319] [shortcuts.py:56] - Cannot find corresponding link for name: TOS
Apr 14 07:24:32 ip-10-184-146-250 [service_variant=cms][edxmako.shortcuts][env:sandbox] WARNING [ip-10-184-146-250  9319] [shortcuts.py:56] - Cannot find corresponding link for name: PRIVACY

Paras Doshi

unread,
Apr 14, 2014, 4:15:10 AM4/14/14
to edx-...@googlegroups.com
Alright, I found the solution. I had to compile the static assets manually after changing the repo. FYI, the static assets reside in /edx/var/edxapp/staticfiles/
Here's how you do it
  • sudo -u edxapp bash
  • source /edx/app/edxapp/edxapp_env
  • cd /edx/app/edxapp/edx-platform
  • SERVICE_VARIANT=lms rake lms:gather_assets:aws
  • SERVICE_VARIANT=cms rake cms:gather_assets:aws

Ray Hooker

unread,
Apr 14, 2014, 4:56:53 PM4/14/14
to Paras Doshi, edx-...@googlegroups.com
Actually it is easier.  The command "paver devstack lms" does work but for some reason it requires an environment variable set to the service variant.   That probably needs to be fixed.

Ray
--
Ray Hooker

Yarko Tymciurak

unread,
Apr 17, 2014, 1:37:34 AM4/17/14
to Ray Hooker, Paras Doshi, edx-...@googlegroups.com
That's in PR #3094;  it's been in the hopper a while, waiting for people to try it / ok it.


Reply all
Reply to author
Forward
0 new messages