Support AWS CodeBuild projects
See original GitHub issueHello, thanks for the great work at CodeCov. We use it in several projects, and have recently ported from CircleCI to AWS CodeBuild (for price and AWS CodePipeline integration).
We are currently using the codecov shell script and doing some shell magic to make it all work. It would be wonderful if CodeBuild was supported “automagically” like the other CI providers.
If it helps, here is what we’ve done so far, and it seems to mostly be working. Once we pull the plug on Circle completely, we’ll know if the uploads to master are working correctly.
VCS_PULL_REQUEST=$(echo $CODEBUILD_SOURCE_VERSION | grep pr | sed 's/pr\///g')
With that set, the git fallback seems to be handling the rest.
Here are the CodeBuild environment variables: https://docs.aws.amazon.com/codebuild/latest/userguide/build-env-ref-env-vars.html
Thanks!
Issue Analytics
- State:
- Created 6 years ago
- Reactions:3
- Comments:6
Top GitHub Comments
I believe we now have several projects using this tool with no additional magic required.
Here is a simplified buildspec that is working for us.
where we have
codecov==2.0.15
pinned in the requirements/test.txt file.@gitblit Yes, we ran into the issue of non-pr’s causing an issue. That’s why we just threw the
|| true
bit on the end of that last command, to keep those builds from failing.There have also been some improvements to this package since our initial trial, so we are able to use it instead of the codecov.sh script, still with similar env variables and parameters.