In my chef recipe, I am basically decrypting a couple of data bags:
1. test.json
2. sample.json
The data obtained after decryption will next be used to create files on my kitchen node. Basically, test.json
and sample.json
are encrypted using a secret key I have (test.json
was obtained from test.txt
and sample.json
was obtained from sample.txt
which are both plaintext files), within a script called gendatabags.rb
that creates these files and puts them in their respective places. Note that the gendatabags.rb
takes the secret key path
and input file path
as input parameters. Now as I want to integration-test this flow, I am looking forward to using a test secret key that I've generated. I would like to provide test versions of both test.txt
and sample.txt
which contain some dummy strings. The catch is, now I'd like to run this script automatically during compile time
of my recipe. Can someone please provide some info on how to achieve this?
Thank you!