← Back to team overview

ubuntu-accomplishments-contributors team mailing list archive

Re: Server Issue

 

It makes sense to copy just the icons if that's all we are using.
Put me a card on trello and I'll read more about these collect static
scripts and fix it.



2012/8/14, Janos Gyerik <info@xxxxxxxxxxx>:
> Hey Mike,
>
> As a follow up, I made Jono kill the settings.py, sorry about that.
>
> So it seems the collectstatic command is running heavy sometimes. It's hard
> to tell why, because it's supposed to be a pretty harmless thing, it just
> copies files, doesn't even go near the database.
>
> However, I did notice something not good in the sample settings, namely the
> project's directory (in the DIRNAME) variable was in the list of
> STATICFILES_DIRS, and as a result the entire project would be copied to
> whatever you configured in STATIC_ROOT. This is bad. I removed it from the
> sample and please remove it from the server.
>
> I hope this improves things, and hopefully collectstatic will run lighter
> now. Please give it a try. *And please wipe out the STATIC_ROOT first to
> remove unnecessary files.*
>
> Gabriel, we should improve the sample setup, because it is still copying
> too many files. I see the entire *-accomplishments collections are copied
> there, when the gallery only needs the trophyimages subdir. I'm thinking
> that maybe we can implement a
> django.contrib.staticfiles.finders.FileSystemFinder which will find
> ACCOMPLISHMENTS_ROOT/**/ubuntu-*/trophyimages and copy the
> ubuntu-*/trophyimages part only. What do you think?
>
> Thanks,
> Janos
>
>
> On Tue, Aug 14, 2012 at 6:32 AM, Janos Gyerik <info@xxxxxxxxxxx> wrote:
>> Hey Jono,
>>
>> 40 * * * * cd /var/www/gallery/; python manage.py collectstatic
>> --noinput --settings settings > /dev/$
>>
>> Is that the complete line?
>> Are you sure the process eating up so much resources was "python
>> manage.py collectstatic" and not some other "python manage.py"
>> command? I cannot think of anything with collectstatic, it should be
>> really harmless. On the other some other commands might be heavier,
>> like import_accomplishments or import_trophies, though I'm surprised a
>> server should break a sweat...
>>
>> In any case hard to say much without access to the server, so Mike is
>> in the best position to investigate.
>>
>> Janos
>> --
>> Janos Gyerik
>> http://titan2x.com/
>
>
>
> --
> Janos Gyerik
> http://titan2x.com/
>

-- 
Enviado desde mi dispositivo móvil

Gabriel E. Patiño
http://about.me/gepatino


Follow ups

References