envplate icon indicating copy to clipboard operation
envplate copied to clipboard

Add output file option?

Open simonvanderveldt opened this issue 10 years ago • 5 comments

Hello Kreuzwerker team,

First of all thanks for the nice and simple tool! :)

I want to ask you guys for your opinion on something: I'm using envplate for some of my personal projects and for one of them I use one Docker image which I volume mount a different config in depending on what I want to use the container for. This config contains a couple of variables that I want to template using envplate. Each of the configs gets used multiple times but with different values. Since I mount these into the container running envplate on them changes the actual file on the host :P

I'm wondering what you guys think about this and if it would a reasonable addition to envplate. Obvious workaround is to volume mount to a different filename and do a cp first (or to create multiple images with the config built into them)

simonvanderveldt avatar Sep 24 '15 19:09 simonvanderveldt

I think it's reasonable. Do you want to submit a PR?

yawn avatar Sep 28 '15 10:09 yawn

:+1:

It nice to have this. or make -d options output to stdout rather than output to stderr. Here is my PR

rustjson avatar Feb 01 '16 02:02 rustjson

I've released a RC for 1.0.0. Feel free to test and close if this fixes your issue. And thanks for contributing!

yawn avatar Feb 18 '16 22:02 yawn

Ping @RustJason

yawn avatar May 20 '16 14:05 yawn

it'd be also great if envplate would read from stdin:

cat templates/foo.conf | ep -d > /etc/foo.conf

however, -d seems redundant in this case.

funkyfuture avatar Oct 25 '16 17:10 funkyfuture