Difference between revisions of "Docker-compose: volumes:"

From wikieduonline
Jump to navigation Jump to search
Tags: Mobile web edit, Mobile edit
Tags: Mobile web edit, Mobile edit
Line 1: Line 1:
[[Docker compose file: docker-compose.yml]]
+
[[Docker compose file: docker-compose.yml]] ([[Docker-compose.yml examples|examples)
 
  [[docker-compose: volumes|volumes]]: <ref>https://docs.docker.com/compose/compose-file/#volumes</ref>
 
  [[docker-compose: volumes|volumes]]: <ref>https://docs.docker.com/compose/compose-file/#volumes</ref>
  

Revision as of 07:30, 4 March 2020

Docker compose file: docker-compose.yml ([[Docker-compose.yml examples|examples)

volumes: [1]

Examples

https://docs.docker.com/compose/compose-file/#volumes#driver_opts

volumes:
 example:
   driver_opts:
     type: "nfs"
     o: "addr=10.40.0.199,nolock,soft,rw"
     device: ":/docker/example"

https://docs.docker.com/compose/compose-file/#volumes#external
If set to true, specifies that this volume has been created outside of Compose.

volumes:
 data:
   external: true

See also

  • https://docs.docker.com/compose/compose-file/#volumes
  • Advertising: