SamDrucker icon indicating copy to clipboard operation
SamDrucker copied to clipboard

Create a host_repo table

Open dlangille opened this issue 2 weeks ago • 4 comments

@Freaky have you seen this fixed in your install?

I came back to this because of kmod

I'm seeing these values in the repo field:

pkg+https://pkg.FreeBSD.org/FreeBSD:14:amd64/kmods_quarterly_3

Which makes sense, given we have this output:

$ /usr/sbin/pkg -vv | grep ' url' | cut -f2 -d \"
pkg+https://pkg.FreeBSD.org/FreeBSD:14:amd64/kmods_quarterly_3
http://bsdpackages.talos.cisco.com/packages/FreeBSD:14:amd64-2025Q4

I'll create a new issue.

Originally posted by @dlangille in #1

We now have multiple repos. I propose splitting the existing host table and creating two new tables:

  • repo (id, name)
  • host_repo (host_id, repo_id)

An update script will be required:

  • create the two new tables

  • take existing values from the host.repo column and populate the new repo table

  • combine the values from host.repo and repo to populate the new host_repo table

  • a clean up script will drop the host.repo column - it will be run manually once you are happy with the update script results

The functions will need updating. The server side script will need an update. Perhaps we can handle that entirely within functions.

dlangille avatar Nov 14 '25 14:11 dlangille