# Gitlab Integration

**URL:** <https://forum.ansible.com/t/gitlab-integration/29277>\
**Category:** AWX Project\
**Tags:** awx\
**Created:** [December 17, 2018, 7:11pm UTC](https://forum.ansible.com/t/gitlab-integration/29277 "2018-12-17T19:11:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ricardo\_Augusto\_Sant](https://avatars.discourse-cdn.com/v4/letter/r/58956e/32.png) [@Ricardo\_Augusto\_Sant](https://forum.ansible.com/u/Ricardo_Augusto_Sant)\
**Post date:** [December 17, 2018, 7:11pm UTC](https://forum.ansible.com/t/gitlab-integration/29277/1 "2018-12-17T19:11:08Z")

</div>

Hello everyone!  
I’m trying to integrate AWX x GITLAB and I receiving below issue:

“msg”: “ssh: Could not resolve hostname gitlabserver.local: Name or service not known\r\nfatal: Could not read from remote repository.\n\nPlease make sure you have the correct access rights\nand the repository exists.”

This is my repo: ssh://git@gitlabserver.local:2222/ansible/Ansible.git

My GITLAB is working on Docker Container and your SSH PORT is 2222. AWX is trying connect in port 22 (local server).

Can I change this on AWX?

Note: I have most repos working fine with Jenkins in same GITLAB.

Tks

Att,  
Ricardo Santos

---

<div class="post-metadata">

**Author:** ![matburt](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/matburt/32/3612_2.png) [@matburt](https://forum.ansible.com/u/matburt)\
**Post date:** [December 17, 2018, 8:26pm UTC](https://forum.ansible.com/t/gitlab-integration/29277/2 "2018-12-17T20:26:50Z")

</div>

> Could not resolve hostname gitlabserver.local: Name or service not known

This suggests that the problem is actually a DNS resolution issue.

---

<div class="post-metadata">

**Author:** ![Ricardo\_Augusto\_Sant](https://avatars.discourse-cdn.com/v4/letter/r/58956e/32.png) [@Ricardo\_Augusto\_Sant](https://forum.ansible.com/u/Ricardo_Augusto_Sant)\
**Post date:** [December 17, 2018, 9:48pm UTC](https://forum.ansible.com/t/gitlab-integration/29277/3 "2018-12-17T21:48:49Z")

</div>

The problem was that awxtask did not resolve the DNS nor did it have the credentials needed to connect to the Repository in Gitlab.

Solution:  
Add HOSTNAME IP entries to / etc / hosts on awxtask  
Creating ssh key in awxtask  
Copy id\_rsa to git user

Please close topic
