-
Notifications
You must be signed in to change notification settings - Fork 73
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
DOP-4306: Remove legacy build code from autobuilder #985
Conversation
2e129a7
to
3aafad2
Compare
Your feature branch infrastructure has been deployed! Your webhook URL is: https://6g5m6zxu2l.execute-api.us-east-2.amazonaws.com/prod/webhook/githubEndpoint/trigger/build For more information on how to use this endpoint, follow these instructions. |
1 similar comment
Your feature branch infrastructure has been deployed! Your webhook URL is: https://6g5m6zxu2l.execute-api.us-east-2.amazonaws.com/prod/webhook/githubEndpoint/trigger/build For more information on how to use this endpoint, follow these instructions. |
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.
Hey Anabella! Looks good so far, we just need to make some more changes where we reference legacy build commands and whatnot.
src/job/stagingJobHandler.ts
Outdated
@@ -49,14 +49,12 @@ export class StagingJobHandler extends JobHandler { | |||
prepDeployCommands(): void { | |||
// TODO: Can we make this more readable? | |||
this.currJob.deployCommands = ['. /venv/bin/activate', `cd repos/${getDirectory(this.currJob)}`, 'make stage']; |
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.
We should remove '. /ven/bin/activate'
as that will cause errors when removing the legacy dependencies from the Dockerfile. We can also remove 'make stage'
as this now will never be used. In fact, this could be simplified even more by simply doing something like:
this.currJob.deployCommands = [`cd repos/${getDirectory(this.currJob)}`, `make next-gen-stage ${this.currJob.payload.pathPrefix ? `MUT_PREFIX=${this.currJob.payload.mutPrefix}` : '' }`];
} | ||
} else { | ||
this.currJob.payload.isNextGen = false; | ||
this.prepStageSpecificNextGenCommands(); |
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.
We should update the prepStageSpecificNextGenCommands();
. That method contains stuff that we can clean up/simplify. More specifically, that function depends on mutations made to the this.currJob.buildCommands
property in the this.prepBuildCommands
method.
Anywhere we see . /venv/bin/activate
or make (parse/html/stage/deploy)
we should remove that as those are meant for legacy builds.
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.
should make (parse/html/stage/deploy)
be replaced with something else?
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.
Also, should make publish
be removed as well?
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.
Good question. They should be replaced with the next-gen equivalent e.g. make parse should be replaced with next-gen-parse. make publish
should be removed as well, good catch!
Probably unrelated, but figure I would ask, for my own learning purposes. With these changes would |
We still use it to make sure that branches that have |
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.
Looks great!
Context
DOP-4306
Going forward, we will only support builds on Snooty so we can remove all of the not isNextGen code paths, and remove the checking logic
Using feature branch webhook, deployed README changes in
cloud-docs
. Built successfullyLink to build logs
Link to preprd site
Pushed branch to preprd, used standard webhook to deploy README changes in
cloud-docs
. Built successfully without errors.Link to build logs
Link to preprd site