-
Notifications
You must be signed in to change notification settings - Fork 586
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
Updated baas-test-server to use the arm64 docker image #6304
Conversation
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.
LGTM
const dylibFilename = "libstitch_support.dylib"; | ||
const dylibUsrLocalLibPath = "/usr/local/lib/" + dylibFilename; | ||
const assistedAggPath = path.resolve(baasPath, "assisted_agg"); | ||
const { AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY } = process.env; |
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.
Does it mean that you don't need to store them in .env
?
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.
Yep - or provide them to the process on the command-line, but the dotenv.config()
above helps load them from a file.
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.
-100 lines 🎉 Nice!
}; | ||
|
||
function assertImage(value: unknown): asserts value is Image { | ||
assert(typeof value === "object" && value !== null); |
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.
assert(typeof value === "object" && value !== null); | |
assert(typeof value === "object" && value !== null && !Array.isArray(value)); |
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.
I think it's fine. Without the explicit check for array, the property checks below will return undefined and fail their assertions.
}; | ||
|
||
function assertImagesResponse(value: unknown): asserts value is ImagesResponse { | ||
assert(typeof value === "object" && value !== null); |
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.
assert(typeof value === "object" && value !== null); | |
assert(typeof value === "object" && value !== null && !Array.isArray(value)); |
const object = value as Record<string, unknown>; | ||
assert(Array.isArray(object.allBranches)); | ||
const { images } = object; | ||
assert(typeof images === "object" && images !== null); |
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.
assert(typeof images === "object" && images !== null); | |
assert(typeof images === "object" && images !== null && !Array.isArray(images)); |
What, How & Why?
We still need to update the instructions for how to get the AWS credentials, but with this PR the BaaS test server will be pulled from AWS ECR and will run in an Arm64 compatible docker container 🎉