Git Product home page Git Product logo

Comments (3)

indykoning avatar indykoning commented on September 24, 2024

Hi!

This is related to #80 and this will be able to be set by en environment variable like that by the time it is closed

Sadly the Magento Deployment Configuration we use cannot be set using variables by normal means.
We have been able to do that by using means such as https://github.com/justbetter/magento2-dotenv (To prevent magento from regenerating and overwriting the env.php) and loading env variables in the config https://github.com/justbetter/magento2-dotenv/blob/master/Example/env.php

However the proper solution will be to add the module configuration to the "core config" part of Magento so it can be set in the same way you describe

from magento2-sentry.

rit001 avatar rit001 commented on September 24, 2024

In fact, it is already doable as it is a feature of the Magento config system for I guess non cloud configurations. My question was about what env names to use - while I'm still working on my final configuration I can say that the required env names are

  CONFIG__DEFAULT__SENTRY_DSN
  CONFIG__DEFAULT__SENTRY__ENVIRONMENT
  CONFIG__DEFAULT__SENTRY__LOG_LEVEL
  CONFIG__DEFAULT__SENTRY__MAGE_MODE_DEVELOPMENT
  CONFIG__DEFAULT__SENTRY__ERROREXCEPTION_REPORTING

You still need the section in the env.php file as Magento needs to know that it has to define the placeholders, but any env defined with the above names will overwrite the corresponding value read from the env.php.

As I noted the Magento docs are not that clear - so the section you link to is correct that only env.php and config.php are merged at start-up and no other config file can be added. The use of env variables to override the values read in gets covered (poorly) within the Pipeline Deployment docs

      https://devdocs.magento.com/guides/v2.4/config-guide/deployment/pipeline/example/environment-variables.html

The magic of the config system starts to make sense once you find the following command that dumps all the values you can override/set

     bin/magento config:show

and
bin/magento config:show --scope="default"

from magento2-sentry.

indykoning avatar indykoning commented on September 24, 2024

See #80 and https://github.com/justbetter/magento2-sentry#configuration-for-adobe-cloud it can now be set with system config 🚀

from magento2-sentry.

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.