Skip to content
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

Prepackage hooks runs after building the docker image #53

Closed
john0isaac opened this issue Jun 28, 2024 · 3 comments · Fixed by #63
Closed

Prepackage hooks runs after building the docker image #53

john0isaac opened this issue Jun 28, 2024 · 3 comments · Fixed by #63
Assignees

Comments

@john0isaac
Copy link
Contributor

john0isaac commented Jun 28, 2024

Description

The first deployment fails (obviously as the static folder was not included in the docker image)

image

After deploying again the website works (as the static folder is already there from the first deployment)

Proposal

Is this an azd failure or do we understand the service lifecycle wrong?
The frontend build step is in the prepackage stage yet it happens after building the docker image.

  • Move this issue to azd? Done
  • Add instructions for manually building the frontend before running azd?
@john0isaac
Copy link
Contributor Author

john0isaac commented Jul 22, 2024

So Wallace Breza says that this should be a prebuild hook not prepackage but let's see what he will say on the issue.
Changing the step from prepackage to prebuild should resolve this issue.
Azure/azure-dev#3546 (comment)

I'm just wondering why is not consistent in the behavior he described only the first run follows the behavior he mentioned.

@pamelafox
Copy link
Contributor

pamelafox commented Jul 22, 2024

Huh, thanks for linking the issue. Let's change to prebuild then.

@john0isaac
Copy link
Contributor Author

FYI this needs to be done for all of the samples that has a "build" stage in their lifecycle where it builds a docker image.
Any sample with ACA that has prepackage command that runs frontend build needs to be changed to prebuild

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants