Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re^2: .env loading the dot env file?

by perlfan (Vicar)
on Mar 28, 2021 at 20:01 UTC ( [id://11130525]=note: print w/replies, xml ) Need Help??


in reply to Re: .env loading the dot env file?
in thread .env loading the dot env file?

Very nice. The benefit here is that you don't have to do anything externally when invoking your script. Thank you and bookmarked :)

Replies are listed 'Best First'.
Re^3: .env loading the dot env file?
by LanX (Saint) on Mar 28, 2021 at 21:10 UTC
    Yes I like this inside-out approach too, since it's trivial to share data between different languages. :)

    BUT I should add that source has the same limitation like a do config.pl ... it's evaling code which might pose a bigger security problem than only "parsing" the file.

    OTOH that's also the case if the shell does it, before executing Perl.

    It wasn't clear to me what kind of .env the OP wants. And %ENV is always security relevant.

    Cheers Rolf
    (addicted to the Perl Programming Language :)
    Wikisyntax for the Monastery

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11130525]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (1)
As of 2024-04-24 15:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found