Interesting, I didn't have to chgrp to get it to work here, I kinda thought 
the directory info in the .conf file handled that.  Anyway, glad it's 
working for you!

Adam

On Tuesday, September 15, 2015 at 12:15:12 PM UTC-5, Angela Labrador wrote:
>
> Amazingly helpful -- thank you! 
>
> Once I followed these instructions (and chgrp to www-data on the new 
> static dir) the install was golden and I no longer have the jquery error.
>
> Looking back, I think I was just missing this step all along and had 
> bungled things by doing the work of collectstatic manually by copying files 
> to my local custom media dir (although not completely, hence the error). 
>
> Thanks again,
> Angela
>
> On Tue, Sep 15, 2015 at 1:01 PM, Adam Cox <[email protected] 
> <javascript:>> wrote:
>
>> Hi Angela, you'll need to do a little bit of set up, and then run *(ENV)*
>>  *python manage.py collectstatic*.  What will be happening is
>>
>>    - Django collects all of the files from all of the STATICFILES_DIRS 
>>    and puts them into one new STATIC_ROOT directory
>>    - Django creates a new url prefix every time a static file is 
>>    requested
>>    - Apache is configured to take that url and point it to the new 
>>    directory that is now holding all of the static files
>>
>> Here's are steps to accomplish this:
>>
>> 1. in settings.py:
>> (leave STATICFILES_DIRS as it is)
>> STATIC_ROOT = os.path.join(PACKAGE_ROOT, 'static')
>> STATIC_URL = "/static/"
>>
>> 2. create that directory (inside your app):
>> *mkdir /srv/crhim/my_hip_app/my_hip_app/static*
>>
>> 3. run the collectstatic command (with virtual environment activated!)
>> *(ENV) cd /srv/crhim/my_hip_app/ && python manage.py collectstatic*
>>
>> 4. tell apache where to find the files, and give it access to the 
>> directory
>>
>> add these lines to your httpd file (or 000-default.conf on ubuntu):
>>
>> Alias /static/ /srv/crhim/my_hip_app/my_hip_app/static
>>
>> <Directory /srv/crhim/my_hip_app/>
>>         Options Indexes FollowSymLinks
>>         AllowOverride None
>>         Require all granted
>> </Directory>
>>
>> 5. restart apache
>>
>> Once you've done this, you'll need to run collect static any time you 
>> change a file that resides in your media directory (images, .css, or .js).  
>> It's necessary to set things up like this anyway, because after you've set 
>> DEBUG = False django will no longer serve those static files--it is left up 
>> to apache.
>>
>> Good luck!
>>
>> On Tuesday, September 15, 2015 at 11:20:57 AM UTC-5, Angela Labrador 
>> wrote:
>>>
>>> Thanks, Adam. I started over in order to test all this: 
>>>
>>>    - Reinstalled all dependencies using the bash script at 
>>>    http://arches3.readthedocs.org/en/latest/installing-dependencies-linux/
>>>    - Ran through all installation instructions for arches and arches_hip
>>>    - Opened the firewall to allow temp remote access to django 
>>>    development server
>>>
>>> NO ERRORS when using the django dev server! Hooray!
>>>
>>> However, when I host through apache, none of the contents of the arches 
>>> or arches_hip media directories (e.g. css, js, etc.) are being hosted. I'm 
>>> assuming this is related to 
>>> STATICFILES_DIRS = (os.path.join(PACKAGE_ROOT, 'media'),) + 
>>> STATICFILES_DIRS
>>> in settings.py. 
>>>
>>> In my apache host conf, I have media successfully aliased to my app's 
>>> specific media directory (the one where I would put my custom files like 
>>> package.css). But, it is not aggregating the other sources for these static 
>>> files. 
>>>
>>> What is the best way to edit settings.py and/or httpd.conf to make sure 
>>> that the media directories under arches/ and arches_hip/ are also being 
>>> hosted? Are people hardcoding this into settings.py? Using symlinks from 
>>> /var/www?
>>>
>>> Many thanks,
>>> Angela
>>>
>>>
>>>
>>>
>>>
>>>
>>> On Friday, September 11, 2015 at 3:59:55 PM UTC-4, Adam Cox wrote:
>>>>
>>>> Well, to check if it's a problem in your virtual environment, you could 
>>>> just make a new one (called ENV2 or something), install arches-hip there, 
>>>> and use it instead.  Activate it, reinstall the package and then run the 
>>>> dev server and see if the problem persists (you'd have to reconfigure the 
>>>> virtual host if you want apache to use the new virtual environment).  Make 
>>>> sure that your settings.py points to the defaults in arches-hip, i.e. 
>>>> comment out both the RESOURCE_GRAPH_LOCATIONS and CONCEPT_SCHEME_LOCATIONS 
>>>> variables so your app will use the defaults.
>>>>
>>>>
>>>> On Fri, Sep 11, 2015 at 2:16 PM, Angela Labrador <[email protected]> 
>>>> wrote:
>>>>
>>>>> Great catch, Adam.
>>>>>
>>>>> Good news: I rebuilt the database and reloaded the sample authority 
>>>>> files -- now I'm at 1221 concepts (I must have added one while poking 
>>>>> around).
>>>>>
>>>>> Not so great news: I disabled apache, edited iptables, ran the django 
>>>>> development server on 0.0.0.0:8000, pointed the web browser to the 
>>>>> new port, and... still got the error.
>>>>>
>>>>> It sounds like it must be something local to my environment, and 
>>>>> likely a path missing in my settings file or local env. I'll comb through 
>>>>> the docs again and my logs to see if I can track it down. If any other 
>>>>> ideas occur to anyone, I'm all ears!
>>>>>
>>>>> Thanks,
>>>>> Angela 
>>>>>
>>>>> On Fri, Sep 11, 2015 at 1:49 PM, Adam Cox <[email protected]> wrote:
>>>>>
>>>>>> Hi Angela, you could run the development server just to make sure 
>>>>>> that apache isn't giving you trouble (though it doesn't really seem like 
>>>>>> that kind of error).  Just make sure port 8000 is accessible and use 
>>>>>> *python 
>>>>>> manage.py runserver 0:8000*.
>>>>>>
>>>>>> I've tried a fresh install of Arches and didn't encounter the errors 
>>>>>> you found. I have in the past however, and not having loaded the concept 
>>>>>> schemes is generally the problem.  Have you modified any of them (or the 
>>>>>> resource graphs)?  I noticed that on my fresh install there were 1221 
>>>>>> concepts, not 1222.
>>>>>>
>>>>>> On Friday, September 11, 2015 at 12:12:23 PM UTC-5, Angela Labrador 
>>>>>> wrote:
>>>>>>>
>>>>>>> HI Alexei,
>>>>>>>
>>>>>>> Thanks for looking into this. Yes, I did load the sample data with 
>>>>>>> no errors reported while running load_concept_scheme. RDM shows 43 
>>>>>>> collections, 2 schemes, 136 entity types, and 1222 concepts.
>>>>>>>
>>>>>>> I should have mentioned that this is on Ubuntu Trusty 14.04.3 and 
>>>>>>> using Apache2 (I believe I have mod_wsgi set up correctly, but that's 
>>>>>>> another variable to throw in the mix as it could be a path missing in 
>>>>>>> my 
>>>>>>> vhost conf file).
>>>>>>>
>>>>>>> Thanks again,
>>>>>>> Angela
>>>>>>>
>>>>>>> On Fri, Sep 11, 2015 at 12:15 PM, Alexei Peters <[email protected]> 
>>>>>>> wrote:
>>>>>>>
>>>>>>>> Hi Angela,
>>>>>>>> I'll take a look at this this morning and let you know what I find 
>>>>>>>> out.
>>>>>>>> Did you happen to load the sample data?
>>>>>>>> Cheers,
>>>>>>>> Alexei 
>>>>>>>>
>>>>>>>> Sent from my Windows Phone
>>>>>>>> ------------------------------
>>>>>>>> From: Angela Labrador
>>>>>>>> Sent: ‎9/‎11/‎2015 7:25 AM
>>>>>>>> To: Arches Project
>>>>>>>> Subject: [Arches] jQuery error on fresh install of 3.0.4 and hip 
>>>>>>>> 1.0.3
>>>>>>>>
>>>>>>>> Hello, 
>>>>>>>>
>>>>>>>> I'm really enjoying learning and working with Arches so far. I have 
>>>>>>>> run into a jQuery error on a clean install of Arches 3.0.4 and 
>>>>>>>> Arches-Hip 
>>>>>>>> 1.0.3 that I could use some help with:
>>>>>>>>
>>>>>>>> When I go to the Resource Manager form for historic resource or 
>>>>>>>> historic district (resources/HERITAGE_RESOURCE.E18/summary/ 
>>>>>>>> or resources/HERITAGE_RESOURCE_GROUP.E27/summary/) I get the following:
>>>>>>>> Uncaught TypeError: Cannot read property 'undefined' of undefined 
>>>>>>>> /media/js/views/forms/sections/branch-list.js:20 
>>>>>>>> and "Date Type" and "Keyword" is in red. (When I go to any of the 
>>>>>>>> other items in the Resource Manager, these fields are in gray and no 
>>>>>>>> error 
>>>>>>>> is thrown.)
>>>>>>>>
>>>>>>>> I am wondering if...
>>>>>>>>
>>>>>>>> 1) This is an expected error and is due to not having something set 
>>>>>>>> up correctly within my data model or not having a particular 
>>>>>>>> vocabulary set 
>>>>>>>> up yet. (I get the error regardless of whether I load the sample 
>>>>>>>> authority 
>>>>>>>> files or not.) 
>>>>>>>>
>>>>>>>> 2) This is an unexpected error and I am missing a js file, have 
>>>>>>>> some issue with my jQuery version, have a permissions issue or... 
>>>>>>>> something 
>>>>>>>> else...?
>>>>>>>>
>>>>>>>> Many thanks for any advice or feedback and great work,
>>>>>>>> Angela
>>>>>>>>
>>>>>>>>
>>>>>>>> -- 
>>>>>>>> -- To post, send email to [email protected]. To 
>>>>>>>> unsubscribe, send email to [email protected]. For 
>>>>>>>> more information, visit 
>>>>>>>> https://groups.google.com/d/forum/archesproject?hl=en
>>>>>>>> --- 
>>>>>>>> You received this message because you are subscribed to the Google 
>>>>>>>> Groups "Arches Project" group.
>>>>>>>> To unsubscribe from this group and stop receiving emails from it, 
>>>>>>>> send an email to [email protected].
>>>>>>>>
>>>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>>>
>>>>>>>
>>>>>>> -- 
>>>>>> -- To post, send email to [email protected]. To 
>>>>>> unsubscribe, send email to [email protected]. For 
>>>>>> more information, visit 
>>>>>> https://groups.google.com/d/forum/archesproject?hl=en
>>>>>> --- 
>>>>>> You received this message because you are subscribed to a topic in 
>>>>>> the Google Groups "Arches Project" group.
>>>>>> To unsubscribe from this topic, visit 
>>>>>> https://groups.google.com/d/topic/archesproject/xDQ22ydcNXk/unsubscribe
>>>>>> .
>>>>>> To unsubscribe from this group and all its topics, send an email to 
>>>>>> [email protected].
>>>>>>
>>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>>>
>>>>>
>>>>>
>>>> -- 
>> -- To post, send email to [email protected] <javascript:>. To 
>> unsubscribe, send email to [email protected] <javascript:>. 
>> For more information, visit 
>> https://groups.google.com/d/forum/archesproject?hl=en
>> --- 
>> You received this message because you are subscribed to a topic in the 
>> Google Groups "Arches Project" group.
>> To unsubscribe from this topic, visit 
>> https://groups.google.com/d/topic/archesproject/xDQ22ydcNXk/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to 
>> [email protected] <javascript:>.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
-- To post, send email to [email protected]. To unsubscribe, send 
email to [email protected]. For more information, 
visit https://groups.google.com/d/forum/archesproject?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Arches Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to