Survey banner
Switching to Dataiku - a new area to help users who are transitioning from other tools and diving into Dataiku! CHECK IT OUT

Gitlab integration via https

Solved!
abdoulaye
Level 3
Gitlab integration via https

Hello, I've setup git https configuration (by login in ssh mode to my ec2 instance that run dataiku).

I've created a token then added it in gitconfig with the rightsthings. This setup work as I tested cloning a project.

In dataiku interface, I've issue when try to add remote repositoy. What the issue here?

โ€ƒ

de.png

 Not authorized

Remote Git usage is forbidden for auth=xxxx.xxx@xxxx.xxx, remoteURL=https://gitlab.xxxxx.com/xxx/xx/x/x-xx.git

Screenshot 2024-05-03 at 13.06.52.png

Screenshot 2024-05-03 at 13.06.23.png

0 Kudos
1 Solution
abdoulaye
Level 3
Author

I'was able to fix it. I just missed the right path in git config (third screnshot).

View solution in original post

0 Kudos
11 Replies
AlexT
Dataiker

Hi @abdoulaye ,

This would usually show because URL you are trying doesn't match the regex expression, can you try with .* as test and check on regex101 to make sure your regex is valid?

Thanks 


0 Kudos
abdoulaye
Level 3
Author

I've set .* for test.

 An error happened while adding a remote
An error happened while adding the following remote: origin (https://gitlab.xxx-xxx.xxx/xxx/xxx/xxx/xxx-xxx.git),
and then fetching it, caused by: IOException: Process failure, caused by: IOException:
Process execution failed (return code 1) (error=remote: HTTP Basic: Access denied.
The provided password or token is incorrect or your account has 2FA enabled and you must use a personal access token instead of a password. See https://gitlab.xxx-xxx.xxx/help/topics/git/troubleshooting_git#error-on-git-fetch-http-basic-access-denied fatal: Authentication failed for 'https://gitlab.xxx-xxx.xxx/xxx/xxx/xxx/xxx-xxx.git/' error: Could not fetch origin )
0 Kudos
Turribeach

Try with this expression:

.*/gitlab.xxxxx.com/xxx/.*
0 Kudos
abdoulaye
Level 3
Author

The .* should work but it throw error.

0 Kudos

What error do you get?

0 Kudos
abdoulaye
Level 3
Author

I got this error in screenshot. I use https url when I click add remote.

I'm my first message post why the window popup request Remote url as ssh url?

 

which user is used when doing this remote git (pull/fetch/push). Is it the one we use when login to instance via ssh?

Screenshot 2024-05-03 at 19.21.52.png

0 Kudos

This is a different error so it's an authentication issue now. Always post the errors you get, "throws an error" is not very useful to people trying to help you. SSH authentication is different than HTTPS authentication so you need to use the correct authentication tokens in each case. For HTTPS you need to generate your personal access token in Gitlab:

https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html

 

0 Kudos
abdoulaye
Level 3
Author

I'm not doing ssh connection. As said https token is correct and working correctly when test vhia login to host using ssh

Dataiku don't give clear doc about setting up https connection, seem here to none never set this. 

0 Kudos

@abdoulaye wrote:

I'm not doing ssh connection. As said https token is correct and working correctly when test vhia login to host using ssh


You say you are not doing SSH connection then you say you "tested via login to host using ssh" using an HTTP token. This is not possible. Either you use SSH keys via SSH or you use HTTPS with personal access tokens. I am not sure why you keep bringing SSH into this thread since you are trying to setup HTTPS. 

 

0 Kudos
abdoulaye
Level 3
Author

I restart

When you use dataikucloudstack(aws) the only way to interact with systems file is to log into the ec2 instance that run the DSS designer: this this done via ssh login (thi ssh is not for git it for login to host). Then to setup git there is two way to do that: 

- 1 https (I use this)

- 2 ssh (i do not use this)

I use 1 and ~/.gitconfig at I setup this file with the tokens from gitlab.

You got it why I say ssh?

0 Kudos
abdoulaye
Level 3
Author

I'was able to fix it. I just missed the right path in git config (third screnshot).

0 Kudos