-
Notifications
You must be signed in to change notification settings - Fork 0
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: replace set-env-vars
task with prepare-buildpack-build
one
#49
Conversation
86a6447
to
db47c63
Compare
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 project.toml file can specify the location of files that you need to build
[io.buildpacks]
include = [
"cmd/",
"go.mod",
"go.sum",
"*.go"
]
you can have different project.toml files in the repository and pass the descriptor as the argument
# build the app
pack build sample-app \
--builder cnbs/sample-builder:bionic \
--path samples/apps/bash-script/ \
--descriptor samples/apps/bash-script/new-project.toml
buildpack.yml is deprecated
https://paketo.io/docs/howto/dotnet-core/
so use project-COMPONENTNAME.toml to define the behavior. Also
[[build.env]]
name = "BPE_OVERRIDE_SERVER_PORT"
value = "8000"
[[build.buildpacks]]
uri = "java-maven"
[[build.buildpacks]]
uri = "paketo-buildpacks/environment-variables"
we can try using this buildpack
https://github.com/paketo-buildpacks/environment-variables in order to setup env vars
let's see if
/cnb/lifecycle/creator has argument to pass a custom named project.toml file.
that way you don't need to pre-rename the files into project.toml or buildpack.yml files.
@dmitry-mightydevops no, it doesn't support
|
Yes, it works in this way only when we build project locally with But it is not the way, how Tekton build works. We have there below command:
So it has no |
It is not deprecated until v1.0.0 version (https://github.com/paketo-buildpacks/dotnet-core-runtime#configuration), latest version is v0.10.8. So we still can use it, anyway we set only
|
I already checked that and no, we can't, Tekton not provides possibility to read build related configuration If smth is not clear, let's discuss it in a call |
If you want to try to use it instead of our current
But anyway, it looks like we can't avoid |
Team, what do you think about switching tekton from |
@DanilaKazakevich discussed with @dmitry-mightydevops in Slack and decided to leave current solution for now with TODO mark to investigate this issue again, when Dmitry will upgrade Tekton engine and probably we will go in suggested by you way |
45594ff
45594ff
to
a5d0624
Compare
This change is needed in cases, when we have few different app stacks, which may be built with
buildpacks
(I need this change for https://saritasa.atlassian.net/browse/OVIO-66 to be able to build 2 separate .NET components -api
andvideo processor
from the same repo, both of them can be built with buildpacks).Added new TriggerBinding params, which may be customized during build process
buildpack_config_filename
andproject_config_filename
(they allow to define custom names forbuildpack.yml
andproject.toml
files) + reorganizedset-env-vars
buildpack task to add one moreprepare
step, which changes correspondingproject_config_filename
andbuildpack_config_filename
files tobuildpack.yml
andproject.toml
files.So the flow is following:
buildpack.yml
andproject.toml
files for each component, i.e.ovio-api-project.toml
,ovio-video-processor-project.toml
,ovio-api-buildpack.yml
,ovio-video-processor-buildpack.yml
instead of originalbuildpack.yml
andproject.toml
ones.tekton
section in EKS, we need to define correctbuildpack_config_filename
andproject_config_filename
filenames and during build correct files would be taken and renamed to ordinarybuildpack.yml
andproject.toml
files.That's how these changes are added to
rocks
EKS: https://github.com/saritasa-nest/saritasa-rocks-kubernetes-aws/pull/93