Hi,
I am having an issue configuring BB pipelines to manually trigger certain steps.
For example pipeline
deploy-to-integration:
- step:
caches:
- node
script:
- make install_yarn
- make install_awscli
- make lint-test
- make deploy-integration
works with no problem , but
master:
- step:
name: Install Lint Test
caches:
- node
script:
- make install_yarn
- make install_awscli
- make lint-test
- step:
name: Deploy to Int
deployment: test
trigger: manual
script:
- make deploy-integration
gives an error that one of the dependancies is not found
sh: 1: webpack: not found
The make commands are the same
Is there anything obviously wrong with this setup ?
Do I need to install dependencies on each step ?
Thanks
Hi Marta,
Each step runs in a separate docker container on a separate machine, so none of the files that are created in the first step will be automatically available in the second step. That includes any software that is installed in the first step.
Generally you will want to install any required software again in the second step and transfer any other files generated in your first step using artifacts: https://confluence.atlassian.com/bitbucket/using-artifacts-in-steps-935389074.html
Note that artifacts can only be used to transfer files within your build directory, so generally can't be used to copy installed software.
If installing software takes a significant amount of time and you want to avoid doing that in every step then you should consider building a custom docker image and using that image for your build. https://confluence.atlassian.com/bitbucket/use-docker-images-as-build-environments-792298897.html
Cheers,
Steven
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.