Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass data of get-target-config to Conftest policies #1928

Open
suzuki-shunsuke opened this issue Oct 17, 2024 · 0 comments
Open

Pass data of get-target-config to Conftest policies #1928

suzuki-shunsuke opened this issue Oct 17, 2024 · 0 comments
Labels
enhancement New feature or request security

Comments

@suzuki-shunsuke
Copy link
Owner

suzuki-shunsuke commented Oct 17, 2024

Feature Overview

Pass data of get-target-config to Conftest policies.

Why is the feature needed?

To validate settings.

Example Code

No response

Note

// create a special data file
tmp.setGracefulCleanup();
const tmpobj = tmp.dirSync();
const data = {
tfaction: {
target: t.target,
working_directory: t.workingDir,
},
};
const tmpFile = path.join(tmpobj.name, "data.json");
fs.writeFileSync(tmpFile, JSON.stringify(data));
args.push("--data", tmpFile);

@suzuki-shunsuke suzuki-shunsuke added enhancement New feature or request security labels Oct 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request security
Projects
None yet
Development

No branches or pull requests

1 participant