An Interest In:
Web News this Week
- April 2, 2024
- April 1, 2024
- March 31, 2024
- March 30, 2024
- March 29, 2024
- March 28, 2024
- March 27, 2024
May 26, 2022 01:26 am GMT
Original Link: https://dev.to/zodman/backup-the-env-files-to-gitgistdropbox-36j4
backup the .env files to git/gist/dropbox in school way!
Hi guys...
Here is a little tip that I like.
Sometimes we need to save the local.env, prod.env file or the stg.env file ... But you don't look where is the best place to backup it .. adding to git it's not a good idea because you are storing secrets is very dangerous...
exists projects like git-secrets1, but in my opinion, it's another layer of knowledge you need to dominate.
let's keep it simple:
cp .env local.envgpg --armor -c local.env # enter a passwordls local.env.asc # file encrypted created
with that you have a file encrypted symmetrical and it can be stored on your:
$ git add *.asc # your git$ cp *.asc ~/Dropbox # your dropbox$ gh gist create local.env.asc # to gist
For decrypt:
gpg -d local.env.asc # entering the password
When your coworkers saw that they will say:
what are you doing? soo old school!!
Original Link: https://dev.to/zodman/backup-the-env-files-to-gitgistdropbox-36j4
Share this article:
Tweet
View Full Article
Dev To
An online community for sharing and discovering great ideas, having debates, and making friendsMore About this Source Visit Dev To