Re: [mezzanine-users] Images disappear when deployed
Hi Tran, the issue with doing this is that in any scalable environment you'll lose your files when nodes spin up/down. Media should be added after deployment, via upload. If you want the file to be persistent then you can put it in static (not media) files, do a `python manage.py collectstatic`. Static files can be added on your local server. Media files are volatile and should live elsewhere. Hope that helps. Ben On Sat, Jul 9, 2016 at 5:01 PM, Tranwrote: > I am using blog with feature image enabled. Whenever I deploy the > application, the feature image that I uploaded disappear. I think the > reason is because I don't have the right setup for the static media (I plan > to use the same server, not aws). Before I add the new change to the local > files, I do git pull (which always says the folder is up to date even > though I uploaded the img on the server). Anybody knows a good way to > correctly set up static media on the same server? Thanks > > -- > You received this message because you are subscribed to the Google Groups > "Mezzanine Users" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to mezzanine-users+unsubscr...@googlegroups.com. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Mezzanine Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to mezzanine-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: [mezzanine-users] Shout out to Mezzanine Gurus
Hi Steve, If you simply want to ask questions I suggest you do so on this wonderful group, for free. If you need a company to write the code for you please feel free to contact me directly via email. Our site: http://www.oceanatech.com/services/responsive-web-applications/ Cheers On Nov 10, 2014 11:59 PM, Steve Hobden hobbo...@gmail.com wrote: Hey Mezzaniners, I'm going to need a hand with a website so is anyone able to assist in providing paid support? Noobs need not apply as that role is already filled. Cheers STEVE H -- You received this message because you are subscribed to the Google Groups Mezzanine Users group. To unsubscribe from this group and stop receiving emails from it, send an email to mezzanine-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups Mezzanine Users group. To unsubscribe from this group and stop receiving emails from it, send an email to mezzanine-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: [mezzanine-users] Media Library - Filebrowser access restrictions
Thanks for the reply Josh. I'll open a pull request if I get it written. Cheers On Wed, Oct 15, 2014 at 6:45 AM, Josh Cartmell joshcar...@gmail.com wrote: Hey Ben, I don't think I did end up writing something. On Fri, Oct 10, 2014 at 7:27 PM, Ben Havilland b...@havilland.net wrote: I know this is crazy old but I am faced with the same question in the current version on Mezzanine. I am about to write the middleware Stephen suggested. Did you already write something Josh? Thanks On Monday, January 24, 2011 1:54:33 AM UTC-8, Stephen McDonald wrote: Hey Josh, You could implement the access control very easily with some middleware - just check the URL for the filebrowser prefix and you've access to the user via request in the middleware as well. That doesn't solve the issue though of controlling whether the link to filebrowser is shown in admin's navigation menu (the text appears as Media Library i the actual menu). You can easily remove it by defining your own menu structure with the setting ADMIN_MENU_ORDER but it's all or nothing at this stage without the ability to have it display based on the current user. The TinyMCE button that links to filebrowser is in the same boat - you can define your own TinyMCE settings with the HTML_WIDGET_CLASS and remove the filebrowser link but it's not going to be configurable per user. Hopefully the middleware approach will cover off what you need. Cheers, Steve On Sat, Jan 22, 2011 at 8:40 AM, Josh Cartmell gro...@j.oshua.net wrote: Hi I was wondering if there is a way to restrict access to filebrowser. I.e. I would like to create a user that is_staff so they can log into the admin site but they cannot access the filebrowser. In my brief testing any user that can log into the admin can access filebrowser. I don't see any assignable user permission for filebrowser. If anyone knows a work around or how to implement this functionality it would be great. Thanks, Josh -- Stephen McDonald http://jupo.org -- You received this message because you are subscribed to the Google Groups Mezzanine Users group. To unsubscribe from this group and stop receiving emails from it, send an email to mezzanine-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups Mezzanine Users group. To unsubscribe from this group and stop receiving emails from it, send an email to mezzanine-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups Mezzanine Users group. To unsubscribe from this group and stop receiving emails from it, send an email to mezzanine-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: [mezzanine-users] Static files on S3
Sorry but or configurations vary on the nginx part. I'm not using nginx, just gunicorn. Ben On Wed, Sep 3, 2014 at 11:26 AM, webpilgri...@gmail.com wrote: Hi Ben, Thanks for your reply. First a correction. When I said nginx.conf I should say: /etc/nginx/sites-enabled/consoc.conf, where consoc.conf is the name of my project. Could you please show how your /etc/nginx/sites-enabled/yourproject.conf file looks like? Best regards. Em quarta-feira, 3 de setembro de 2014 14h58min09s UTC-3, Ben Havilland escreveu: These settings work for me, hope it helps: ### # S3 STATIC FILES # ### AWS_QUERYSTRING_AUTH = False AWS_ACCESS_KEY_ID = os.environ.get('AWS_ACCESS_KEY_ID') AWS_SECRET_ACCESS_KEY = os.environ.get('AWS_SECRET_ACCESS_KEY') AWS_STORAGE_BUCKET_NAME = 'AWSBUCKETNAMEGOESHERE' AWS_PRELOAD_METADATA = True #helps collectstatic do updates STATICFILES_STORAGE = 'storages.backends.s3boto.S3BotoStorage' DEFAULT_FILE_STORAGE = 'storages.backends.s3boto.S3BotoStorage' STATIC_URL = 'https://' + AWS_STORAGE_BUCKET_NAME + '.s3.amazonaws.com/' ADMIN_MEDIA_PREFIX = STATIC_URL + 'grappelli/' MEDIA_URL = 'https://' + AWS_STORAGE_BUCKET_NAME + '.s3.amazonaws.com/' On Wed, Sep 3, 2014 at 10:52 AM, webpil...@gmail.com wrote: Hello everyone, I have read some threads about problems in storing Mezzanine statics files on S3, but I still didn't get it to work. Actually, my site is based on Drum. Static files are being collected to S3, but apparently the Webserver can not find them and the site is messed up. Exception is the media folder which is missing. I guess my nginx.conf need to be updated. My settings are: settings.py #STATIC_URL = /static/ AWS_STORAGE_BUCKET_NAME = consocstatic STATICFILES_STORAGE = 'storages.backends.s3boto.S3BotoStorage' S3_URL = 'http://%s.s3.amazonaws.com/' % AWS_STORAGE_BUCKET_NAME STATIC_URL = S3_URL nginx.conf location /static/ { root/home/ubuntu/consoc/project; access_log off; log_not_found off; } location /robots.txt { root/home/ubuntu/consoc/project/static; access_log off; log_not_found off; } location /favicon.ico { root/home/ubuntu/consoc/project/static/img; access_log off; log_not_found off; } } Any help is appreciated. -- You received this message because you are subscribed to the Google Groups Mezzanine Users group. To unsubscribe from this group and stop receiving emails from it, send an email to mezzanine-use...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups Mezzanine Users group. To unsubscribe from this group and stop receiving emails from it, send an email to mezzanine-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout. -- You received this message because you are subscribed to the Google Groups Mezzanine Users group. To unsubscribe from this group and stop receiving emails from it, send an email to mezzanine-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
[mezzanine-users] Re: Tried 3-4 heroku deployment tutorials but stuck on each one.
Hi all, I just joined the group. Kyle, it appears you have moved on but if anybody else is needs the current working Mezzanine/Heroku setup I've updated my tutorial and it addresses/fixes KeyError: u'ENGINE' the error you were getting. I just ran through it from scratch with the latest packages with success: http://www.benhavilland.com/blog/deploying-mezzanine-on-heroku/ There was a problem in the settings.py with the placement of the local settings and dynamic settings sections in the tutorial code. Ben On Tuesday, March 25, 2014 11:36:26 AM UTC-7, Kyle Pennell wrote: Hey all, Would love to get some help here if you could. Hit the wall on what I can do/try. I'm just trying to deploy a basic mezzanine setup on Heroku. I've triedJosh's tutorialhttps://gist.github.com/joshfinnie/4046138, Ben's Tutorialhttp://www.benhavilland.com/blog/deploying-mezzanine-on-heroku/, searched Stackoverflow, here, etc. Going on 10 hours trying. Hit unique and interesting bugs on each one. So I'm trying Steven Elliot's tutorial http://stevenelliottjr.github.io/. I reasoned that it was the newest (15 days ago) and might work better. He's been extremely helpful on Twitter. Hit this roadblock here: (mezzenv)kpennell@vm-0:~/mezz-site$ python manage.py collectstatic /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/mezzanine/utils/conf.py:51: UserWarning: You haven't defined the ALLOWED_HOSTS settings, which Django 1.5 requires . Will fall back to the domains configured as sites. warn(You haven't defined the ALLOWED_HOSTS settings, which /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/mezzanine/utils/conf.py:59: UserWarning: TIME_ZONE setting is not set, using closest match: Etc/UTC warn(TIME_ZONE setting is not set, using closest match: %s % tz) Traceback (most recent call last): File manage.py, line 29, in module execute_from_command_line(sys.argv) File /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/django/core/management/__init__.py, line 399, in execute_from_command_line utility.execute() File /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/django/core/management/__init__.py, line 392, in execute self.fetch_command(subcommand).run_from_argv(self.argv) File /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/django/core/management/__init__.py, line 261, in fetch_command commands = get_commands() File /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/django/core/management/__init__.py, line 107, in get_commands apps = settings.INSTALLED_APPS File /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/django/conf/__init__.py, line 54, in __getattr__ self._setup(name) File /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/django/conf/__init__.py, line 49, in _setup self._wrapped = Settings(settings_module) File /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/django/conf/__init__.py, line 128, in __init__ mod = importlib.import_module(self.SETTINGS_MODULE) File /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/django/utils/importlib.py, line 40, in import_module __import__(name) File /home/kpennell/mezz-site/settings.py, line 442, in module set_dynamic_settings(globals()) File /home/kpennell/mezz-site/mezzenv/local/lib/python2.7/site-packages/mezzanine/utils/conf.py, line 184, in set_dynamic_settings shortname = db[ENGINE].split(.)[-1] KeyError: u'ENGINE' So something with collect static doesn't work. Something to do with set_dynamic_settings. I copied his tut verbatim and cloned the project he gave me and both hit the snag there. I can post the code here if you want but thought pushing to github would be easier: https://github.com/kpennell/mezz-try Any ideas? -- You received this message because you are subscribed to the Google Groups Mezzanine Users group. To unsubscribe from this group and stop receiving emails from it, send an email to mezzanine-users+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.