overhangio / tutor-ecommerce

Ecommerce plugin for Tutor
GNU Affero General Public License v3.0
17 stars 50 forks source link

refactor: use import proxy instead of reverse_proxy directive #20

Closed cmltaWt0 closed 2 years ago

cmltaWt0 commented 2 years ago

Switch to import proxy to unify the configuration approach for Caddyfile between plugins.

# E-commerce
{{ ECOMMERCE_HOST }}{$default_site_port} {
    request_body {
        max_size 10MB
    }
    import proxy "ecommerce:8000"
}

Reference to discovery patching approach: https://github.com/overhangio/tutor-discovery/pull/22/commits/1793baf930744b3a44059a9df2cffba452ab5a82#diff-007a5a30db1b49ebd828fa0d85c73a71290b76f8d6954c792c2b407bbaf4d881

regisb commented 2 years ago

Good catch! You had many conflicts so I stole your change and added it manually to the "maple" branch :stuck_out_tongue: I hope you don't mind... Thanks!