bloglike:2022-01
This is an old revision of the document!
Issue 2022 - January
AWS CodePipeline + GitHub + git submodule
There are couple of how tos AWS CodePipeline + GitHub and git submodule around - one, two(which discusses handful of solutions), three, four. And here is the one which works for me in given setup:
- private repositories hosted at GitHub
- AWS CodeStar connection to GitHub
- AWS CodePipeline with “full clone”
- AWS CodeBuild with the following buildspec
- buildspec.yml
version: 0.2 env: git-credential-helper: yes phases: build: commands: - git submodule update --init --recursive - ls -laR .
NOTES:
- URL in
.gitmodules
must behttps://github.com/user-org/repo
. Relative path and git+SSH didn't work for me. Actually, this was rather important finding for me and it looks like it's not mentioned anywhere. It looks like I will have to apply yet another hack since GitHub Actions require hack-around as well. - Don't forget to allow AWS CodeBuild service role to use of AWS CodeStar connection, namely
codestar-connections:UseConnection
. Usually forgotten. - What about SSH? What about it? Sadly, that's one way to deal with git submodules in GitHub Actions.
bloglike/2022-01.1642791665.txt.gz · Last modified: 2022/01/21 13:01 by stybla