Skip to content
This repository has been archived by the owner on Sep 28, 2024. It is now read-only.

Hocus fails to resolve DNS records hosted locally #5

Open
szymex73 opened this issue Apr 1, 2023 · 1 comment
Open

Hocus fails to resolve DNS records hosted locally #5

szymex73 opened this issue Apr 1, 2023 · 1 comment

Comments

@szymex73
Copy link

szymex73 commented Apr 1, 2023

🐛 Bug description

When using a self-hosted git and DNS, hocus fails on the prebuild stage for such a repo since it cannot resolve the local name with the hardcoded 8.8.8.8 DNS server.

In my setup, I host a DNS server locally in the network and provide local domain names that get resolved through it. The DNS server IP is given along with the DHCP lease so the host system knows which resolver to use, but Hocus does not inherit this and fails to resolve the name of the local git server.

Steps to reproduce

  1. Install Hocus
  2. Set up a git server in a local network as well as a DNS server with records pointing to that git server
  3. Add a repository to Hocus

Result

The prebuild status for branches stays pending perpetually as it fails to fetch the project since it cannot resolve the local git server with 8.8.8.8.

What should happen

Hocus should be able to resolve local DNS names and pull the repo.

Possible fixes

This issue could be fixed by providing the ability to configure DNS servers used internally instead of hardcoding 8.8.8.8, or by setting up a DNS forwarder that the VMs could use internally that would then forward the requests to the DNS used by the host system.

Environment

  • Hocus version (commit hash): a998d71
  • OS and its version: Ubuntu Server 22.04.2
@gorbak25
Copy link
Member

gorbak25 commented Apr 1, 2023

Hi @szymex73!
Thank you for reporting this bug :) We will add a DNS proxy to the Hocus Agent so the VM's will be able to use the DNS resolver inside the agent container.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants