title: Static files configuration in AWS not working
body: <p>I currently have an multi-docker container application (nginx, postgres RDS, Django) running on Elastic BeanStalk and I am able to use it but the static files (CSS files and JS scripts) are not loaded. This is my current configuration: </p>
  
  <p><b>nginx setup file</b></p>
  
  <pre><code> user nginx;
   worker_processes 1;
  
   events {
     worker_connections 1024;
   }
  
  http {
  include /etc/nginx/mime.types;
  client_max_body_size 100M;
  
  server {
      listen 80;
      charset utf-8;
      server_name mydashboard.com;
  
      access_log /dev/stdout;
      error_log /dev/stdout info;
  
      location /media/ {
          alias /var/www/media/;
      }
  
      location /static/ {
          alias /var/www/static/;
      }
  
      location / {
          proxy_pass http://web:8888; 
          proxy_set_header host $host;
          proxy_set_header X-Real-IP $remote_addr;
          proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
          proxy_set_header X-Forwarded-Host $server_name;
      }
    }
  }
  </code></pre>
  
  <p><b>.ebextensions (folder)</b></p>
  
  <p><b>django.config (file)</b></p>
  
  <pre><code> option_settings:
       "aws:elasticbeanstalk:application:environment":
   DJANGO_SETTINGS_MODULE: "mydashboard.settings"
      "ALLOWED_HOSTS": ".elasticbeanstalk.com"
   "aws:elasticbeanstalk:container:python":
       WSGIPath: mydashboard/mydashboard/wsgi.py
   "aws:elasticbeanstalk:container:python:staticfiles":
      "/static/": "www/static/"
  </code></pre>
  
  <p><b>settings.py</b></p>
  
  <pre><code>  STATIC_URL = '/static/'
    STATICFILES_DIRS = (os.path.join(BASE_DIR,'static'),)
    STATIC_ROOT = os.path.join(BASE_DIR, "..", "www", "static")
    STATICFILES_STORAGE = 'whitenoise.storage.CompressedManifestStaticFilesStorage'
    MEDIA_URL = '/media/'
  </code></pre>
  
  <p>If I remove the folder <code>.ebextensions</code> folder and load the app, it will work without displaying the static files but if I add the folder with the <code>django.conf</code> file the app won't deploy and I will encounter the error: <code>Invalid option specification (Namespace: 'aws:elasticbeanstalk:container:python:staticfiles', OptionName: '/static/'): Unknown configuration setting.</code> </p>
  
  <p>In one post I found (<a href="https://stackoverflow.com/questions/42462880/how-to-serve-static-files-to-aws-when-deploying-django-app-python-manage-py-co/42501995">Serving static files in Django</a>) it is mentioned that all staticfiles directives from .config files should be removed and under the Software Configuration I should configure the static files under the Static File section, however, this Static File section is not even displayed. What code am I missing for displaying the static files? Thanks in advance for your suggestions and answers. </p>