Code Monkey home page Code Monkey logo

Comments (4)

mschae avatar mschae commented on July 20, 2024 1

I just published 1.5.0 with you changes (and some cleanup). Thanks!

https://hex.pm/packages/cors_plug/1.5.0

from cors_plug.

mschae avatar mschae commented on July 20, 2024

Hey,

Thanks for your issue description, it’s very thorough and it all makes sense to me.

I’m ok allowing a function for origin that is called on every request. May I ask how you configure the app? If it is through environment variables we could discuss passing a {:system, “VAR_NAME”} tuple or something of the like. That’s how I’ve seen other libraries handle this issue.

Either way I can give you a branch to test in the next few days unless you want to submit a PR.

Thanks,
Michael

from cors_plug.

mauricioszabo avatar mauricioszabo commented on July 20, 2024

I'm using docker secrets, so the config is inside a specific file in my filesystem (something like /run/secrts/origin. I'm also using memoize (https://github.com/melpon/memoize) to avoid reading the same file over and over again after every request.

from cors_plug.

mauricioszabo avatar mauricioszabo commented on July 20, 2024

When you publish a new version, can you let me know? Thanks!

from cors_plug.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.