added support for username:password

Signed-off-by: Richard Jones <richard@dagger.io>
This commit is contained in:
Richard Jones
2021-12-22 11:02:52 -07:00
parent a49d794409
commit 0295dc6340
3 changed files with 62 additions and 37 deletions

View File

@@ -11,12 +11,21 @@ package engine
}
// Pull a directory from a git remote
// Note: do not add credentials to the remote url: e.g: https://username:password@github.com
// as this will expose those in logs. By using username and password (as #Secret) Dagger will
// url encode them for you
#GitPull: {
$dagger: task: _name: "GitPull"
remote: string
ref: string
authToken?: #Secret
authHeader?: #Secret
keepGitDir: true | *false
output: #FS
remote: string
ref: string
keepGitDir: true | *false
{
username: string
password: #Secret // can be password or personal access token
} | {
authToken: #Secret
} | {
authHeader: #Secret
}
output: #FS
}