aws-quickstart/quickstart-git2s3

GitError: failed to resolve address for git.xxxxxx.com: No address associated with hostname

sudusan opened this issue · 1 comments

I have generated the SSH key and registered it in the enterprise GitHub. I have added the web hook api. When I make a commit to my git repo, the lambda function is triggered. I get the following error (partial stack from cloud watch logs below):

failed to resolve address for git.autodesk.com: No address associated with hostname: GitError
Traceback (most recent call last):
File "/var/task/lambda_function.py", line 226, in lambda_handler
repo = create_repo(repo_path, remote_url, creds)
File "/var/task/lambda_function.py", line 70, in create_repo
repo = clone_repository(remote_url, repo_path, callbacks=creds)
File "/var/task/pygit2/init.py", line 263, in clone_repository
check_error(err)
File "/var/task/pygit2/errors.py", line 64, in check_error
raise GitError(message)
GitError: failed to resolve address for git.autodesk.com: No address associated with hostname

Any help in resolving this is appreciated

This is regarding the network issue. Just add your lambda in the VPC instead of "NoVPC" configuration and test with one test server to ping your github enterprise. If you are able to telnet git then lambda with also connect to git once in VPC.