Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mattrobenolt/envdir-plusplus
kinda like envdir, kinda like dotenv, kinda like docker env-file
https://github.com/mattrobenolt/envdir-plusplus
Last synced: 2 months ago
JSON representation
kinda like envdir, kinda like dotenv, kinda like docker env-file
- Host: GitHub
- URL: https://github.com/mattrobenolt/envdir-plusplus
- Owner: mattrobenolt
- License: mit
- Created: 2020-02-20T22:39:55.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2020-02-25T21:45:48.000Z (almost 5 years ago)
- Last Synced: 2024-08-04T01:19:37.599Z (4 months ago)
- Language: Go
- Homepage:
- Size: 12.7 KB
- Stars: 9
- Watchers: 3
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ENVDIR++(1)
a good mashup of envdir + docker's env-file. Intended to be used as a docker entrypoint script like:
```
#!/usr/bin/envdir++ /bin/sh
```This allows pointing `envdir++` to a directory if docker compatible env-file's. See the example `.env/` folder in this repository and `test.sh` scripts for examples of how this works.
Intended use case is pairing Vault Agent with Kubernetes, were Vault Agent runs as an initContainer, spits out secrets as files into `/vault/secrets/*`. This then reads those files and elevates them into environment variables so your application can access them.
Add to your `Dockerfile`:
```Dockerfile
FROM alpineENV ENVDIR_VERSION v0.4.0
RUN set -eux; \
\
apk add --no-cache --virtual .build-deps \
gnupg \
wget \
; \
wget -O /usr/bin/envdir++ "https://github.com/mattrobenolt/envdir-plusplus/releases/download/$ENVDIR_VERSION/envdir++-linux-amd64"; \
wget -O /usr/bin/envdir++.asc "https://github.com/mattrobenolt/envdir-plusplus/releases/download/$ENVDIR_VERSION/envdir++-linux-amd64.asc"; \
export GNUPGHOME="$(mktemp -d)"; \
gpg --keyserver ha.pool.sks-keyservers.net --recv-keys D8749766A66DD714236A932C3B2D400CE5BBCA60; \
gpg --batch --verify /usr/bin/envdir++.asc /usr/bin/envdir++; \
rm -rf "$GNUPGHOME" /usr/bin/envdir++.asc; \
chmod +x /usr/bin/envdir++; \
envdir++ /bin/sh -c 'echo ok'; \
apk del --no-network .build-deps
```