title: How to run _update elasticsearch with external script
body: <p>I want to run example update </p>
  
  <pre><code>curl -XPOST 'localhost:9200/test/type1/1/_update' -d '{
      "script" : "ctx._source.text = \"some text\""
  }'
  </code></pre>
  
  <p>(<a href="http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/docs-update.html">http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/docs-update.html</a>), but got error <code>{"error":"ElasticsearchIllegalArgumentException[failed to execute script]; nested: ScriptException[dynamic scripting for [mvel] disabled]; ","status":400}</code>.</p>
  
  <p>From this page <a href="http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/modules-scripting.html">http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/modules-scripting.html</a>, I found out that I need to place my script (I called it <code>demorun.groovy</code>) and run it by name.
  I did that, and now try to reference as </p>
  
  <pre><code>curl -XPOST 'localhost:9200/test/type1/1/_update' -d '{
      "script" : "demorun.groovy"
  }'
  </code></pre>
  
  <p>But still get same error. 
  I suppose that reference it wrong. How to pass _update with external script?</p>
  
  <p>My demorun.groovy:</p>
  
  <pre><code>ctx._source.text = \"some text\"
  </code></pre>