title: Set Docker volumes size quota within docker-compose driver opts?
body: <p>I am testing with docker-compose and volumes storage quotas.</p>
  
  <p>This is the <code>docker-compose.yml</code> I have <strong>working</strong> for now:
  <a href="https://i.stack.imgur.com/SqDY4.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/SqDY4.png" alt="docker-compose.yml"></a>
  Which is pretty much a simple Apache, with PHP and an upload php file.</p>
  
  <p>What I am unable to find is to make the volume be "like the others", I just want to add the quota line, something like this:</p>
  
  <pre><code>volumes:
      storage1:
          driver_opts:
              o: 'size=100000,uid=1000'
  
      storage2:
          driver_opts:
              o: 'size=1g'
  
      storage3:
          driver_opts:
              o: 'size=100m'
      ...
  </code></pre>
  
  <p>...but of course this does not work, I <code>need to specify the device</code>, which I do not know what the default is, and if I need anything else.</p>
  
  <p>Like I said, I just want "default" behaviour with the size quota working, and I though I could achieve this by re-setting the default values in the mandatory <code>driver_opts</code> parameters. So, how could I achieve that?
  (If there is a better way, please tell me.)</p>
  
  <p><em>System: Ubuntu 18.04 LTS x86_64 / Docker 18.09</em></p>
  
  <p>Thanks in advance.</p>