Commit Graph

16 Commits (master)

Author SHA1 Message Date
CrazyMax 5fcc94454f
Generate and embed build sources
Signed-off-by: CrazyMax <crazy-max@users.noreply.github.com>
2021-09-18 01:39:35 +02:00
Tonis Tiigi fb32dad95b git: fix default branch detection
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2021-07-06 16:34:43 -07:00
Levi Harrison ccc9f20895 Moved getDefaultBranch function to gitsource
It is my suspecion that the tests were failing on previous commits because of the lack of authentication and other stuff like that available in gitidentifier as compared to gitsource

Signed-off-by: Levi Harrison <levisamuelharrison@gmail.com>
2021-07-06 15:38:00 -07:00
Levi Harrison 8604d7cef2 Automatically detect default git branch
Instead of just assuming that the default branch is master, use ls-remote to find out. Also removed tests that didn't specifiy a branch but required authentication, because those will fail now that the repo is actually checked.

Signed-off-by: Levi Harrison <levisamuelharrison@gmail.com>
2021-07-06 15:37:31 -07:00
Tonis Tiigi 3bdb6b5159 git: support subdir component
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2021-05-19 22:13:04 -07:00
Alex Couture-Beil 3a5bdf0710 Move prefix check to isGitTransport
- rename IsSSHTransport to IsImplicitSSHTransport
- add testing for NewGitIdentifier

Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2021-01-04 11:09:56 -08:00
Alex Couture-Beil 3fa063dcf3 move ssh regexp test to common location
- include testing
- improve hostname checking

Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-12-10 17:10:38 -08:00
Alex Couture-Beil 23af9dcb86 require a username for git over ssh
Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-12-10 17:10:38 -08:00
Alex Couture-Beil b64f992917 Allow any ssh-user while cloning from git
- this allows one to use a non-standard ssh username like repo@host
rather than assuming it must be git@host

Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-12-10 17:10:38 -08:00
Alex Couture-Beil 92e89a3374 Fixes related to the PR
- back out changes to changing the git url
 - fix gid
 - ignore global ssh config option when specifying known hosts

Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-11-12 17:32:29 -08:00
Alex Couture-Beil f2c8eb177c Support cloning from non-standard git repos
- fixes assumption that ssh git clones must be via the `git` user.
- allows passing the SSH_AUTH_SOCK from the client to GitSource
- allows passing a known_host entry for ssh

Signed-off-by: Alex Couture-Beil <alex@earthly.dev>
2020-11-10 15:55:17 -08:00
Tonis Tiigi 49de675234 git: support for token authentication
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2020-06-16 17:00:06 -07:00
Vincent Demeester 08373f2381
Clean some small dependencies on docker/docker package
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
2018-02-01 16:05:24 -08:00
Tonis Tiigi 367752bf1c dockerfile: add test for building from git repo
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-12-17 21:09:20 -08:00
Tonis Tiigi fa7ee2e2a8 source: add keepgitdir option for git source
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-07-10 22:19:05 -07:00
Tonis Tiigi b65989a5e4 source: add git source
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-07-10 22:19:05 -07:00