From: Chuck Lever III <chuck.lever@oracle.com>
To: Luis Chamberlain <mcgrof@kernel.org>, Scott Mayhew <smayhew@redhat.com>
Cc: "kdevops@lists.linux.dev" <kdevops@lists.linux.dev>
Subject: Re: scripts/get-distro-default-bridge.sh
Date: Wed, 1 May 2024 01:13:12 +0000 [thread overview]
Message-ID: <0D7E1DC2-8816-4DC9-87AA-E006E054FBF9@oracle.com> (raw)
In-Reply-To: <ZjFgOCoEOwDj0OSn@bombadil.infradead.org>
> On Apr 30, 2024, at 5:18 PM, Luis Chamberlain <mcgrof@kernel.org> wrote:
>
> On Tue, Apr 30, 2024 at 09:12:42PM +0000, Chuck Lever III wrote:
>>
>>
>>> On Apr 30, 2024, at 3:52 PM, Luis Chamberlain <mcgrof@kernel.org> wrote:
>>>
>>> On Tue, Apr 30, 2024 at 07:15:21PM +0000, Chuck Lever III wrote:
>>>> Hi Luis-
>>>>
>>>> My mirroring set-up broke somehow on my Vagrant system.
>>>> I thought I had tested the gitr workflow mirroring
>>>> changes before I pushed them -- maybe I tested it on
>>>> one of my guestfs systems.
>>>>
>>>> I copied this change from the many similar changes you did
>>>> to the other mirrored git repos:
>>>>
>>>> +config HAVE_MIRROR_GIT
>>>> + bool
>>>> + depends on USE_LIBVIRT_MIRROR
>>>> + default $(shell, scripts/check_mirror_present.sh /mirror/git.git)
>>>> +
>>>> config GITR_REPO
>>>> string "The git tool repository to clone"
>>>> - default "https://git.kernel.org/pub/scm/git/git.git"
>>>> - help
>>>> + default DEFAULT_GIT_URL if !HAVE_MIRROR_GIT
>>>> + default $(shell, scripts/append-makefile-vars.sh git:// $(KDEVOPS_DEFAULT_BRIDGE_IP_VAGRANT) /mirror/git.git) if HAVE_MIRROR_GIT && VAGRANT
>>>> + default $(shell, scripts/append-makefile-vars.sh git:// $(KDEVOPS_DEFAULT_BRIDGE_IP_GUESTFS) /mirror/git.git) if HAVE_MIRROR_GIT && GUESTFS
>>>> + help
>>>>
>>>> So KDEVOPS_DEFAULT_BRIDGE_IP_VAGRANT contains
>>>>
>>>> http://192.168.124.1
>>>>
>>>> which means the GITR_REPO URL looks like this:
>>>>
>>>> git://http://192.168.124.1/mirror/git.git
>>>>
>>>> Needless to say, ansible.builtin.git does not know what
>>>> to do with that URL ;-)
>>>>
>>>> So I'm not quite sure what you intended with commit
>>>> a2579089dc70 ("provision: generalize bridge-ip further"),
>>>> otherwise I'd just post a fix.
>>>
>>> The mirror uses git by default as we should not have a local mirror
>>> blocked by stupid firewalls, so the fix here I think is:
>>>
>>> diff --git a/scripts/get-distro-default-bridge.sh b/scripts/get-distro-default-bridge.sh
>>> index 09d09ff04ee1..d85625c4ebd8 100755
>>> --- a/scripts/get-distro-default-bridge.sh
>>> +++ b/scripts/get-distro-default-bridge.sh
>>> @@ -9,7 +9,7 @@ VIRT_TYPE=$2
>>> # a different deafult it should be easy for you to extend it here.
>>>
>>> if [[ "$VIRT_TYPE" == "vagrant" ]]; then
>>> - echo "http://192.168.124.1"
>>> + echo "192.168.124.1"
>>> else
>>> echo "192.168.122.1"
>>> fi
>>
>> Thanks!
>>
>> I've run into a couple of problems while testing this change.
>>
>> First, it appears that Fedora 39 packages git-daemon separately,
>> so mirroing wasn't fully set up on this system. I installed it
>> by hand (sudo dnf install git-daemon) but that needs to be
>> addressed in kdevops at some point.
>>
>> "git clone git://192.168.124.1/mirror/git.git" just hangs no
>> matter where I run it.
>>
>> "git clone git://192.168.122.1/mirror/git.git" works on the
>> control node, but on the target nodes it gets ECONNREFUSED.
>> Stopping firewalld on the control node seems to fix that.
>
> So for fedora we can disable mirroring until this is fixed.
I think I have it nailed, though I wonder if it will be an
issue for RHEL/CentOS as well. Scott, do you know off-hand
if either the packaging issue or the firewall issue will
be at play for RHEL/CentOS?
>> Fwiw, "ip a" on my control node reports:
>>
>> 6: virbr0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
>> link/ether 52:54:00:1d:6e:76 brd ff:ff:ff:ff:ff:ff
>> inet 192.168.122.1/24 brd 192.168.122.255 scope global virbr0
>> valid_lft forever preferred_lft forever
>
> Sounds like the script needs to check for that then for vagrant. You can
> also just use a fedora check for it to hard code it to the same IP as
> with guestfs. Up to you. There is a DISTRO_FEDORA already you could rely
> on.
The output of get-distro-prefix is passed to the get-distro-
default-bridge.sh script, but I'm not sure this is working:
cel@renoir:~/src/kdevops/cel$ scripts/get-distro-prefix.sh
debian
cel@renoir:~/src/kdevops/cel$ cat /etc/redhat-release
Fedora release 39 (Thirty Nine)
cel@renoir:~/src/kdevops/cel$
--
Chuck Lever
prev parent reply other threads:[~2024-05-01 1:13 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-04-30 19:15 scripts/get-distro-default-bridge.sh Chuck Lever III
2024-04-30 19:52 ` scripts/get-distro-default-bridge.sh Luis Chamberlain
2024-04-30 21:12 ` scripts/get-distro-default-bridge.sh Chuck Lever III
2024-04-30 21:18 ` scripts/get-distro-default-bridge.sh Luis Chamberlain
2024-05-01 1:13 ` Chuck Lever III [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=0D7E1DC2-8816-4DC9-87AA-E006E054FBF9@oracle.com \
--to=chuck.lever@oracle.com \
--cc=kdevops@lists.linux.dev \
--cc=mcgrof@kernel.org \
--cc=smayhew@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).