title: Bulk index django model to elastic search
body: <p>I am trying to bulk index my django model to elastic search 6, my plan is to run this as a cron once a day to update the index.
  import requests</p>
  
  <pre><code>data = serialize('json', CapitalSheet.objects.all())
  
  data += "\n"
  
  r = requests.post("http://127.0.0.1:9200/capitalsheet/_bulk", json = data)
  
  print(r.content)
  </code></pre>
  
  <p>I am getting this error:
  <code>b'{"error":{"root_cause":[{"type":"illegal_argument_exception","reason":"The bulk request must be terminated by a newline [\\n]"}],"type":"illegal_argument_exception","reason":"The bulk request must be terminated by a newline [\\n]"},"status":400}'</code></p>
  
  <p>If you can suggest something better, I would be glad.</p>