I got following settings:
STATIC_URL = '/static/'
STATIC_ROOT = os.path.join(BASE_DIR, 'static')
STATICFILES_DIRS = (
os.path.join(BASE_DIR, 'static', 'appname'), )
In my templates I got
<link rel="stylesheet" href"{% static 'appname/css/main.css' %}" />
My static folder includes default Django admin css and js like /static/css and its working fine.
My same static folder includes /static/appname/css/main.css
Still my css is not coming up. My templates are showing up but without css/js. I got all my folders such as 'templates', static', 'static-files' under my project folder.
My default Django static files are showing after "coollectstatic" under static/admin. But I have no idea how to use "STATICFILES_DIRS" in production to show my project template related static files. I am deploying for production. Please advise.
I figured it out that it needed settings in gunicorn from What is the most common way to configure static files in debug and production for Django . The tutorial is not based on gunicorn but the link attached regarding gunicorn worked fine for me. I am thankful as you guys tried to help and stackoverflow just rocks.