title: How to set heap memory in cassandra on docker
body: <p>I am using a Cassandra docker (official Cassandra docker) to setup my local env.
  As part of this I want to limit the amount of memory the Cassandra is using in my local deployment.<br>
  By default Cassandra has a pre defined way to set its memory.<br>
  I found references to some info saying that i can use JVM_OPTS to set this values but it does not seem to take hold.<br>
  I am looking for a way to set up this values without creating my own Cassandra docker.</p>
  
  <p>Docker command that is used to run container:</p>
  
  <pre><code>docker run -dit --name sdc-cs --env RELEASE="${RELEASE}" \
     --env CS_PASSWORD="${CS_PASSWORD}" --env ENVNAME="${DEP_ENV}" \
     --env HOST_IP=${IP} --env JVM_OPTS="-Xms1024m -Xmx1024m" \
     --log-driver=json-file --log-opt max-size=100m \
     --log-opt max-file=10 --ulimit memlock=-1:-1 --ulimit nofile=4096:100000 \
     --volume /etc/localtime:/etc/localtime:ro \
     --volume ${WORKSPACE}/data/CS:/var/lib/cassandra \
     --volume ${WORKSPACE}/data/environments:/root/chef-solo/environments \
     --publish 9042:9042 --publish 9160:9160 \
     ${PREFIX}/sdc-cassandra:${RELEASE} /bin/s
  </code></pre>
  
  <p>Any advice will be appreciated!</p>