Skip to content

git_resource extension makes bad assumptions about repo url #618

@CafeLungo

Description

@CafeLungo

The git_resource plugin assumes the protocol is ssh, and it also assumes the ssh port is 22. This does not work if your git server is using a different port. It is also incompatible with the protocol portion of the URL. For example git+ssh://myurl.com:2222/my_repo.git is not identified as a URL, but instead as a directory:

Use case: git+ssh://myurl.com:2222/my_repo.git:
Actual result:
It assumes this is a directory:

Error in docker_build: error reading dockerfile: open /Users/user/Documents/workspace/my_project/git+ssh:/git@myurl.com:2222/my_repo.git/Dockerfile:

Expected result:
Cloning into /Users/user/Library/Application Support/tilt-dev/.git-sources/my_repo from git+ssh://myurl.com:2222

Use case: myurl.com:2222/my_repo.git:
Actual result:
It makes assumptions about the ssh server:

cloning into '/Users/user/Library/Application Support/tilt-dev/.git-sources/my_repo'...
ssh: connect to host myurl.com port 22: Operation timed out

Expected result:
Cloning into /Users/user/Library/Application Support/tilt-dev/.git-sources/my_repo from git+ssh://myurl.com:2222/my_repo

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions