jigit plug-in error when adding gitlab
I follow the official screenshots to fill in the corresponding information, there is an error: Error in the URL more than "/ api / v3 / projects /" These. Please see the
Comments (15)
-
-
reporter the problem still exists
-
repo owner Hi!
You are right, repository is the full project name and it shouldn't contain .git suffix.
Could you take a look at JIRA log file? It should contain information and stacktrace related to this error.
-
reporter This is jigit-plugen's log, I do not get it
16-Nov-2017 18:07:58.878 WARNING [http-nio-8080-exec-13] com.sun.jersey.spi.container.servlet.WebComponent.filterFormParameters A servlet request, to the URI http://192.168.220.202:8080/rest/jigit/1.0/repo/test, contains form parameters in the request body but the request body has been consumed by the servlet or a servlet filter accessing the request parameters. Only resource methods using @FormParam will work as expected. Resource methods consuming the request body by other means will not work as expected.
-
repo owner Let's try to call GitLab API with curl (https://curl.haxx.se/). You have to run two commands.
The first:
curl -i --header "PRIVATE-TOKEN: {YOUR_TOKEN_HERE}" "http://{YOUR_GITLAB_SITE_NAME_HERE}/api/v3/projects"
And the second:
curl -i --header "PRIVATE-TOKEN: {YOUR_TOKEN_HERE}" "http://{YOUR_GITLAB_SITE_NAME_HERE}/api/v3/projects/{YOUR_GROUP_NAME_HERE}%2Ffisheyetest/repository/branches/master"
I bet that group name is minglongzhang ). So, your command will be something like this:
curl -i --header "PRIVATE-TOKEN: it_is_a_secret" "http://gitlab****.com/api/v3/projects/minglongzhang%2Ffisheyetest/repository/branches/master"
It's better to run commands from JIRA server if it is possible.
What are the output of commands?
-
reporter Thank you for always looking for a solution for me. These are logs:
[root@localhost ~]# curl -i --header "PRIVATE-TOKEN:N2iPfkvu611bnXnDMygY" "http://gitlab.*.com/api/v3/projects" HTTP/1.1 200 OK Link: http://gitlab.****.com/api/v3/projects?archived=&order_by=created_at&page=1&per_page=20&simple=false&sort=desc; rel="first", http://gitlab.****.com/api/v3/projects?archived=&order_by=created_at&page=1&per_page=20&simple=false&sort=desc; rel="last" [{"id":267,"description":"","default_branch":"master","tag_list":[],"public":true,"archived":false,"visibility_level":20,"ssh_url_to_repo":"git@gitlab..com:minglong.zhang/fisheyepublic.git","http_url_to_repo":"http://gitlab..com/minglong.zhang/fisheyepublic.git","web_url":"http://gitlab..com/minglong.zhang/fisheyepublic","owner":{"name":"张明龙","username":"minglong.zhang","id":151,"state":"active","avatar_url":"http://cn.gravatar.com/avatar/af3adcce988072515cf190df801a3a78?s=80\u0026d=identicon","web_url":"http://gitlab..com/minglong.zhang"},"name":"fisheyepublic","name_with_namespace":"张明龙 / fisheyepublic","path":"fisheyepublic","path_with_namespace":"minglong.zhang/fisheyepublic","container_registry_enabled":true,"issues_enabled":true,"merge_requests_enabled":true,"wiki_enabled":true,"builds_enabled":true,"snippets_enabled":true,"created_at":"2017-11-14T06:52:57.231Z","last_activity_at":"2017-11-14T06:52:57.231Z","shared_runners_enabled":true,"lfs_enabled":true,"creator_id":151,"namespace":{"id":178,"name":"minglong.zhang","path":"minglong.zhang","kind":"user","full_path":"minglong.zhang","parent_id":null},"avatar_url":null,"star_count":0,"forks_count":0,"open_issues_count":0,"public_builds":true,"shared_with_groups":[],"only_allow_merge_if_build_succeeds":false,"request_access_enabled":false,"only_allow_merge_if_all_discussions_are_resolved":false,"permissions":{"project_access":{"access_level":40,"notification_level":3},"group_access":null}},{"id":266,"description":"fisheyetest","default_branch":"master","tag_list":[],"public":false,"archived":false,"visibility_level":0,"ssh_url_to_repo":"git@gitlab..com:minglong.zhang/fisheyetest.git","http_url_to_repo":"http://gitlab..com/minglong.zhang/fisheyetest.git","web_url":"http://gitlab..com/minglong.zhang/fisheyetest","owner":{"name":"张明龙","username":"minglong.zhang","id":151,"state":"active","avatar_url":"http://cn.gravatar.com/avatar/af3adcce988072515cf190df801a3a78?s=80\u0026d=identicon","web_url":"http://gitlab.***.com/minglong.zhang"},"name":"fisheyetest","name_with_namespace":"张明龙 / fisheyetest","path":"fisheyetest","path_with_namespace":"minglong.zhang/fisheyetest","container_registry_enabled":true,"issues_enabled":true,"merge_requests_enabled":true,"wiki_enabled":true,"builds_enabled":true,"snippets_enabled":true,"created_at":"2017-11-14T06:07:17.481Z","last_activity_at":"2017-11-17T01:08:34.780Z","shared_runners_enabled":true,"lfs_enabled":true,"creator_id":151,"namespace":{"id":178,"name":"minglong.zhang","path":"minglong.zhang","kind":"user","full_path":"minglong.zhang","parent_id":null},"avatar_url":null,"star_count":0,"forks_count":0,"open_issues_count":0,"public_builds":true,"shared_with_groups":[],"only_allow_merge_if_build_succeeds":false,"request_access_enabled":false,"only_allow_merge_if_all_discussions_are_resolved":false,"permissions":{"project_access":{"access_level":40,"notification_level":3},"group_access":null}}]
[root@localhost ~]# curl -i --header "PRIVATE-TOKEN:N2iPfkvu611bnXnDMygY" "http://gitlab.****.com/api/v3/projects/minglong.zhang%2Ffisheyetest/repository/branches/master" HTTP/1.1 404 Not Found Server: nginx
-
repo owner Ok.
It looks like it's a problem in nginx settings. One of Russian users faced it recently. Unfortunatelly, I don't know all the specialities, but I'll ask him to help.
The problem was related to encoding %2F of symbol /. He solved it via configuring nginx reverse proxy https://www.nginx.com/resources/admin-guide/reverse-proxy/
-
repo owner -
reporter Thank you for helping me. Let me try
-
reporter I found a problem that an error will occur when the repository name contains ".". I did the test,Created two warehouses zml.easy and zmleasy 1) contain".": http://192.168.220.194/zmltest/zml.easy.git Wrong:http://45.78.30.202/20171120173413.png 2) Does not contain ".":http://192.168.220.194/zmltest/zmleasy.git success:http://45.78.30.202/20171120173436.png
-
repo owner Ok. I've found an issue related to GitLab https://gitlab.com/gitlab-org/gitlab-ce/issues/22718. Consequently, it's not a Jigit issue.
It looks like this bug can be closed. Do you have some extra questions?
-
repo owner Hi.
Have you solved problems with GitLab? Do you use Jigit?
-
reporter I renamed the gitlab repository name. solved. thanks.
-
repo owner - changed status to resolved
-
repo owner - changed status to wontfix
- Log in to comment
i just know this problem. the Repository should be project name