-
Notifications
You must be signed in to change notification settings - Fork 16
Design doc for spk service create
#480
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 - my questions were answered in the design review
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.
So the new flags --build-vg
and --build-variables
should be used in conjunction, and we won't be piggy-backing off another vg elsewhere.
Would we add these VG to the azdo project through spk project create-variable-group
or spk variable-group create
?
Additionally, I think we may need to expand the section about implementation:
we can add logic to iterate through the a
linked variable group and inject variables as arguments to be part of the
az acr build
command
We will also need to expose each variable group variable as an environment variable in that pipeline step.
Is there a preference as to which spk |
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.
As part of the build-update-hld.yaml, where there is the "ACR Build and Publish" task (L208-L217) generated by spk service create, we can add logic to iterate through the a linked variable group and inject variables as arguments to be part of the az acr build command (i.e.az acr build -r
$(ACR_NAME) -f $ (DOCKER_BUILD_FILE) --build-arg$key=$ {value}).
@yradsmikham When exactly do we look at the variables in the variable group? Seems like this would have to happen "client side" before we git commit + push
the build-update-hld.yaml
file?
If a users adds additional args to their variable group do they have to call spk service create
again locally, the commit and push?
@andrebriggs , we access the variables in the variable group when the services build pipeline (i.e. fabrikam.acme.frontend-pipeline) runs, or when the If users make updates to their Dockerfile and require to add additional args to their variable group, they should (for now) just update their |
Sure, I can be a little more specific about this. |
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 good. Thanks @yradsmikham
Though according to docs here, once we have a reference to the variables, we could use a script to iterate through them, making secret substitutions and passing them all into the build args. So as long as the variable group variable is updated somehow (either though a future spk command or the azdo UI) then the build script should have the latest arguments. |
Related to microsoft/bedrock#1006.