-
Notifications
You must be signed in to change notification settings - Fork 31
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
Secrets cli #657
Secrets cli #657
Conversation
packages/dbos-cloud/cli.ts
Outdated
.option("-s, --secretname <string>", "Specify the name of the secret to create") | ||
.option("-v, --value <string>", "Specify the value of the secret to store with the name.") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we make these mandatory?
I think we can use this method
} | ||
logger.info(` ... app name is ${appName}.`); | ||
|
||
logger.info(bearerToken); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this
|
||
const body = {'ApplicationName': appName , 'SecretName':secretName, 'ClearSecretValue': secretValue}; | ||
|
||
console.log(body); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this log
return 1; | ||
} | ||
|
||
logger.info(`Secret successfully created!`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logger.info(`Secret successfully created!`); | |
logger.info(`Secret ${secretName} successfully created!`); |
logger.error("Failed to get app name."); | ||
return 1; | ||
} | ||
logger.info(` ... app name is ${appName}.`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
logger.info(` ... app name is ${appName}.`); | |
logger.debug(` ... app name is ${appName}.`); |
} else { | ||
const secrets = res.data as string[]; | ||
secrets.forEach((secret) => { | ||
logger.info(secret); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably also use console.log
here as it's multiple lines.
(1) npx dbos-cloud app secrets create
(2) npx dbos-cloud app secrets list