MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    Use enviromental variables in server only mode

    Scheduled Pinned Locked Moved General Discussion
    1 Posts 1 Posters 392 Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • idoodlerI Offline
      idoodler Module Developer
      last edited by idoodler

      Hey guys!

      I need to use enviromental variables process.env in the config.js. However I am unable to do so in the server only mode.

      The config.js is used in the “Webinterface”, this obviously don’t have access to the enviromental variables of Node.js.

      I am using balena-MagicMirror (made by me) to have multiple remotely managed MagicMirrors which all contain basically the same config, but differ in a few things that should be defined as enviromental variables.

      Anyone know how I can “inject” enviromental variables in the browser with some MagicMirror Module?

      Edit: I just created a module that will do this

      [card:idoodler/MMM-ENV-Provider]

      1 Reply Last reply Reply Quote 0
      • 1 / 1
      • First post
        Last post
      Enjoying MagicMirror? Please consider a donation!
      MagicMirror created by Michael Teeuw.
      Forum managed by Sam, technical setup by Karsten.
      This forum is using NodeBB as its core | Contributors
      Contact | Privacy Policy