Gets actual path for owner

Signed-off-by: Somtochi Onyekwere <somtochionyekwere@gmail.com>
pull/681/head
Somtochi Onyekwere 4 years ago
parent 96d8ec2016
commit 4fcf93306a

@ -129,18 +129,22 @@ func bootstrapGitLabCmdRun(cmd *cobra.Command, args []string) error {
return fmt.Errorf("cluster already bootstrapped to %v path", usedPath)
}
repository, err := git.NewRepository(glRepository, glOwner, glHostname, glToken, "flux", glOwner+"@users.noreply.gitlab.com")
provider := &git.GitLabProvider{
IsPrivate: glPrivate,
IsPersonal: glPersonal,
}
owner, err := provider.GetRepositoryOwner(ctx, glToken, glOwner)
if err != nil {
return err
}
if glSSHHostname != "" {
repository.SSHHost = glSSHHostname
repository, err := git.NewRepository(glRepository, owner, glHostname, glToken, "flux", glOwner+"@users.noreply.gitlab.com")
if err != nil {
return err
}
provider := &git.GitLabProvider{
IsPrivate: glPrivate,
IsPersonal: glPersonal,
if glSSHHostname != "" {
repository.SSHHost = glSSHHostname
}
tmpDir, err := ioutil.TempDir("", namespace)

Loading…
Cancel
Save