aplsms
(Andrii Petrenko)
April 2, 2018, 10:36pm
1
hi all,
I have a problem running drone+gogs in my local environment,
Error message:
Initialized empty Git repository in /drone/src/git.local/apl/test/.git/
+ git remote add origin https://git.local/apl/test.git
+ git fetch --no-tags origin +refs/heads/master:
fatal: unable to access 'https://git.local/apl/test.git/': Could not resolve host: git.local
exit status 128
I can ping gogs server and clone this repository on server and worker.
i’m using latest version of drone running on alpine.
drone/agent 0.8-alpine a59d0ad4d071 3 days ago 18.8MB
drone/drone 0.8-alpine 751a9128c47c 3 days ago 35.9MB
Thank you in advance.
I think there are existing threads that discuss this error and how to resolve http://discuss.harness.io/search?q=Could%20not%20resolve%20host
aplsms
(Andrii Petrenko)
April 3, 2018, 3:19pm
4
Hello Brad,
i’ve added env DRONE_NETWORK=br-pub
, but nothing changed. Is it possible to set more option for build container like --dns
and --extra-hosts
and have more detailed debug?
If you need to add a custom DNS server you can configure it with you Docker daemon. On linux you can create or edit the /etc/docker/daemon.json
file. More details here: https://docs.docker.com/engine/reference/commandline/dockerd/#on-linux
aplsms
(Andrii Petrenko)
April 3, 2018, 3:50pm
6
yes, all of them already there.
$ sudo cat /etc/docker/daemon.json
{
"ipv6": false,
"dns": ["192.168.1.2", "192.168.1.4"],
"host":[
"tcp://192.168.1.2:2375",
"unix:///var/run/docker.sock"
]
}
This thread describes how others have solved this problem:
Hello,
Trying to set up a local configuration of Gogs and Drone, I am finding it difficult to make Drone fetch and clone Gogs repos during the default build procedure. I’d like to underline that all local means that the host is expected to be running without any external net connection; it will be an ‘isolated’ box with all the required docker images downloaded already. However, at now, it is connected, so that I can try different approaches.
I believe that this use case is slightly different …
Unfortunately I’m not sure there is much more I can do to assist, but hopefully the above link helps you to resolve the problem. Good luck!
aplsms
(Andrii Petrenko)
April 3, 2018, 4:15pm
8
is it possible to set debug to maximum level to see what and how drone doing?
aplsms
(Andrii Petrenko)
April 4, 2018, 1:12am
9
Please close this thread. Issue resolved by reimagine host from scratch.
hi Did you solved it ?
I am meetting this question now ,
so could you share how to finish it ,
thank you