-
Notifications
You must be signed in to change notification settings - Fork 1
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
feat: display the auth secret when creating an environment #219
Conversation
@@ -71,6 +71,7 @@ const preparePlan = ({ | |||
env, | |||
prompts, | |||
tokenBehavior, | |||
additionnalStep, |
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.
the diff in this file is to support the additionnalStep
keyword, which adds a step at the end of the plan.
@@ -59,7 +59,9 @@ function errorIfStdRest(stds) { | |||
} | |||
} | |||
|
|||
function errorIfBadCommand({ commandClass, commandArgs, commandPlan }) { | |||
function errorIfBadCommand({ |
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.
the diff in this file is to support the 'additionnalStep' keyword, which adds a step at the end of the plan.
@@ -66,6 +66,7 @@ async function testCli({ | |||
commandClass, | |||
commandArgs, | |||
commandPlan: testCommandPlan, | |||
additionnalStep, |
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.
the diff in this file is to support the additionnalStep keyword, which adds a step at the end of the plan.
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.
src/services/environment-manager.js
Outdated
@@ -36,7 +38,7 @@ function EnvironmentManager(config) { | |||
this.createEnvironment = async () => { | |||
const authToken = authenticator.getAuthToken(); | |||
|
|||
return agent | |||
const environment = await agent |
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.
Shouldn't we totally migrate this one to async/await ?
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.
why not!
@@ -7,10 +7,11 @@ class KeyGenerator { | |||
crypto, | |||
}); | |||
this.crypto = crypto; | |||
this.length = 24; |
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.
Maybe a small comment on the fact that randomBytes(24).toString('hex')
generate a 48 characters string might be useful here ...
Or maybe that's just me that is not super familiar with the crypto
package 😅.
Node 15 introduce crypto.getRandomValues()
, via the web crypto api that would have been better here :)
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.
Look good, works as expected.
Feel free to ignore my comment if you don't find it useful, maybe that's just me :D
# [2.3.0](v2.2.8...v2.3.0) (2021-09-02) ### Features * display the auth secret when creating an environment ([#219](#219)) ([6320f5d](6320f5d))
🎉 This PR is included in version 2.3.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Definition of Done
General
Security