dockerfile/examples/omnivore/official-src/omnivore-main/pkg/extension/replace-with-process-env.js

7 lines
179 B
JavaScript
Raw Permalink Normal View History

2024-03-15 14:52:38 +08:00
module.exports = (content, vars) => {
for (const key in vars) {
content = content.replace(new RegExp('process.env.' + key, 'g'), process.env[key]);
}
return content;
};