[BUG] git repo link not working in path attribute
varma-amit opened this issue · 3 comments
Bug Description
I am trying to source terraform module stored in github repo, but when I pass the git link of repo in the "path" attribute of modules section in runway.yml and execute runway plan, it returns error as follows:
$runway plan
return self.__git_ls_remote(self.__determine_git_ls_remote_ref())
File "/usr/lib/python3.9/site-packages/runway/sources/git.py", line 77, in __git_ls_remote
ls_remote_output = subprocess.check_output(cmd)
File "/usr/lib/python3.9/subprocess.py", line 424, in check_output
return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
File "/usr/lib/python3.9/subprocess.py", line 528, in run
raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['git', 'ls-remote', '', 'HEAD']' returned non-zero exit status 128.
I am able to clone the repo manually with git clone command on the host machine where runway is installed, and ssh key is also added to github repo.
git ls-remote <repo_url> HEAD is also returning output without any error on manual execution on the terminal
I am assuming it has to do something with ssh authentication.
Can someone please address this asap as it is blocking critical operations in our project.
runway.yml:
deployments:
- name: test-deployment
modules:- path: git::git:///terraform-google-bigquery.git
parameters:
dataset_id: "Testing-runway"
regions:
europe-west2
- path: git::git:///terraform-google-bigquery.git
Expected Behavior
runway plan should not return error
Steps To Reproduce
Example project: ...
- add git repo url to path attribute in runway.yml:
deployments:
- name: test-deployment
modules:- path: git::git:///terraform-google-bigquery.git
parameters:
dataset_id: "Testing-runway"
regions:
europe-west2
- path: git::git:///terraform-google-bigquery.git
- $runway plan
...
Runway version
2.6.8
Installation Type
pypi (pip, pipenv, poetry, etc)
OS / Environment
- OS: Red hat Linux
- terraform version: 1.5.2
Anything else?
No response
Update:
Seems like authentication or git protocol is not the problem but the URL format is.
My repo url contains multiple hyphens("-") and after removing all of them, runway plan was able to detect the url as valid.
Not sure why runway is not able to parse git url with hyphens.
Is anyone going to address this please, awaiting response since last week and need to get this going as it is blocking critical operations in our project. Any help is much appreciated!!
Hi @varma-amit , thank you for filing this issue. I believe we have identified the fix for this. If you are able to test the branch bugfix/remote-uri-path-hyphen-support
and confirm that would be very helpful. We'll get this merged into the next release once approved.