fork 0k-charms
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

88 lines
2.5 KiB

  1. docker-image: docker.0k.io/mirror/odoo:rc_12.0-MYC-INIT-3.7
  2. data-resources:
  3. - /var/lib/odoo
  4. # config-resources:
  5. # ## XXXvlab: should this be there or declared dynamically in the relation that
  6. # ## create/update this file ?
  7. # # - /etc/odoo-server.conf
  8. docker-compose:
  9. command:
  10. - odoo
  11. - --config=/opt/odoo/auto/odoo.conf
  12. ## YYYvlab: useful ?
  13. tty: true
  14. environment:
  15. INITIAL_LANG: fr_FR
  16. LIST_DB: 'true'
  17. default-options:
  18. workers: 1
  19. # modules:
  20. # - l10n_fr
  21. #database: MYDATABASE ## will be the one connected to postgres
  22. ## Adds custom values in options
  23. # conf:
  24. # options:
  25. # email_from: xxxx
  26. # othersection:
  27. # myvalue: yyy
  28. uses:
  29. postgres-database:
  30. #constraint: required | recommended | optional
  31. #auto: pair | summon | none ## default: pair
  32. constraint: required
  33. auto: summon
  34. solves:
  35. database: "main storage"
  36. default-options:
  37. extensions:
  38. - unaccent
  39. log-rotate:
  40. #constraint: required | recommended | optional
  41. #auto: pair | summon | none ## default: pair
  42. constraint: recommended
  43. auto: pair
  44. solves:
  45. unmanaged-logs: "in docker logs"
  46. #default-options:
  47. web-proxy:
  48. #constraint: required | recommended | optional
  49. #auto: pair | summon | none ## default: pair
  50. constraint: recommended
  51. auto: pair
  52. solves:
  53. proxy: "Public access"
  54. default-options:
  55. target: !var-expand ${MASTER_BASE_SERVICE_NAME}:8069
  56. apache-custom-rules:
  57. - !bash-stdout |
  58. workers=$(relation-base-compose-get workers 2>/dev/null)
  59. workers=${workers:-1}
  60. if [ "$workers" -gt 1 ]; then
  61. echo "ProxyPass /longpolling/ http://${MASTER_BASE_SERVICE_NAME}:8072/longpolling/"
  62. echo "ProxyPassReverse /longpolling/ http://${MASTER_BASE_SERVICE_NAME}:8072/longpolling/"
  63. fi
  64. backup:
  65. constraint: recommended
  66. auto: pair
  67. solves:
  68. backup: "Automatic regular backup"
  69. default-options:
  70. ## First pattern matching wins, no pattern matching includes.
  71. ## include-patterns are checked first, then exclude-patterns
  72. ## Patterns rules:
  73. ## - ending / for directory
  74. ## - '*' authorized
  75. ## - must start with a '/', will start from $SERVICE_DATASTORE
  76. exclude-patterns:
  77. - "/var/lib/odoo/sessions/"
  78. # network-isolation:
  79. # whitelist: ## required external services used by this service
  80. # - www.google.com
  81. # - www.gravatar.com
  82. # - fonts.gstatic.com
  83. # - fonts.googleapis.com
  84. # - cdnjs.cloudflare.com