Add deprecation notice to $data

This commit is contained in:
Johan Haals
2021-01-04 15:31:30 +01:00
parent 4c33dc48e9
commit 36268a966c
@@ -107,6 +107,9 @@ export async function readSecret(
return ctx.env[secret.env];
}
if ('data' in secret) {
console.warn(
`Configuration uses deprecated $data key, use $include instead.`,
);
const url =
'path' in secret ? `${secret.data}#${secret.path}` : secret.data;
const [filePath, dataPath] = url.split(/#(.*)/);