]> git.ipfire.org Git - pakfire.git/log
pakfire.git
4 months agojobs: Drop the control connect and explicitely launch them
Michael Tremer [Tue, 4 Feb 2025 11:20:33 +0000 (11:20 +0000)] 
jobs: Drop the control connect and explicitely launch them

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agocompress: Enable long mode (if available)
Michael Tremer [Tue, 4 Feb 2025 10:57:10 +0000 (10:57 +0000)] 
compress: Enable long mode (if available)

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agohashes: Replace the old digest mechanism
Michael Tremer [Tue, 4 Feb 2025 10:37:50 +0000 (10:37 +0000)] 
hashes: Replace the old digest mechanism

This is splitting the hasher into a separate object so that we have more
flexibility here. It also renames the digests struct into "hashes" which
is a little bit shorter and I thought that it makes more sense.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agodigests: Constify source when importing digests
Michael Tremer [Mon, 3 Feb 2025 15:06:55 +0000 (15:06 +0000)] 
digests: Constify source when importing digests

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Remove debugging line
Michael Tremer [Mon, 3 Feb 2025 14:58:33 +0000 (14:58 +0000)] 
repo: Remove debugging line

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Fix composing import paths
Michael Tremer [Mon, 3 Feb 2025 14:53:44 +0000 (14:53 +0000)] 
repo: Fix composing import paths

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Move sync decision
Michael Tremer [Mon, 3 Feb 2025 14:28:16 +0000 (14:28 +0000)] 
repo: Move sync decision

There are actually not a lot of changes, I just needed to move a lot of
static functions.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agoxfer: Refactor code to retry
Michael Tremer [Mon, 3 Feb 2025 14:21:36 +0000 (14:21 +0000)] 
xfer: Refactor code to retry

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Perform a full scan for local repositories without metadata
Michael Tremer [Mon, 3 Feb 2025 14:19:05 +0000 (14:19 +0000)] 
repo: Perform a full scan for local repositories without metadata

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Download the package database
Michael Tremer [Mon, 3 Feb 2025 14:16:53 +0000 (14:16 +0000)] 
repo: Download the package database

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Store the downloaded metadata if it is more recent
Michael Tremer [Mon, 3 Feb 2025 14:00:59 +0000 (14:00 +0000)] 
repo: Store the downloaded metadata if it is more recent

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Parse the entire repository metadata
Michael Tremer [Mon, 3 Feb 2025 11:35:14 +0000 (11:35 +0000)] 
repo: Parse the entire repository metadata

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agojson: Add more helper functions to read JSON objects
Michael Tremer [Mon, 3 Feb 2025 11:34:38 +0000 (11:34 +0000)] 
json: Add more helper functions to read JSON objects

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Read any existing repository metadata before download
Michael Tremer [Mon, 3 Feb 2025 10:39:28 +0000 (10:39 +0000)] 
repo: Read any existing repository metadata before download

This way we can verify that the downloaded version is more recent.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepos: Add a new object to parse the metadata into
Michael Tremer [Mon, 3 Feb 2025 10:28:32 +0000 (10:28 +0000)] 
repos: Add a new object to parse the metadata into

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agojson: Add helper function to read integers
Michael Tremer [Mon, 3 Feb 2025 10:26:00 +0000 (10:26 +0000)] 
json: Add helper function to read integers

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Load metadata into memory and verify it
Michael Tremer [Sun, 2 Feb 2025 16:36:50 +0000 (16:36 +0000)] 
repo: Load metadata into memory and verify it

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agokey: Parse signatures that don't have a comment
Michael Tremer [Sun, 2 Feb 2025 16:32:02 +0000 (16:32 +0000)] 
key: Parse signatures that don't have a comment

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agoutil: Add a simple buffer structure
Michael Tremer [Sun, 2 Feb 2025 16:24:47 +0000 (16:24 +0000)] 
util: Add a simple buffer structure

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agokey: Print correct error code when verification fails
Michael Tremer [Sun, 2 Feb 2025 16:24:21 +0000 (16:24 +0000)] 
key: Print correct error code when verification fails

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agojson: Oops, forgot to add the files
Michael Tremer [Sun, 2 Feb 2025 15:39:20 +0000 (15:39 +0000)] 
json: Oops, forgot to add the files

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Move repomd.json into the root
Michael Tremer [Sun, 2 Feb 2025 15:17:28 +0000 (15:17 +0000)] 
repo: Move repomd.json into the root

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Don't make the JSON pretty
Michael Tremer [Sun, 2 Feb 2025 15:09:48 +0000 (15:09 +0000)] 
repo: Don't make the JSON pretty

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Cleanup old metadata before writing new stuff
Michael Tremer [Sun, 2 Feb 2025 15:06:56 +0000 (15:06 +0000)] 
repo: Cleanup old metadata before writing new stuff

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepos: Add file type to metadata
Michael Tremer [Sun, 2 Feb 2025 15:01:41 +0000 (15:01 +0000)] 
repos: Add file type to metadata

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepos: Add filesize to metadata
Michael Tremer [Sun, 2 Feb 2025 15:00:12 +0000 (15:00 +0000)] 
repos: Add filesize to metadata

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepos: Some minor code cleanup when writing metadata
Michael Tremer [Sun, 2 Feb 2025 14:57:00 +0000 (14:57 +0000)] 
repos: Some minor code cleanup when writing metadata

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Only use a few stronger digests for metadata
Michael Tremer [Sun, 2 Feb 2025 14:53:47 +0000 (14:53 +0000)] 
repo: Only use a few stronger digests for metadata

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Add checksums for files
Michael Tremer [Sun, 2 Feb 2025 14:46:52 +0000 (14:46 +0000)] 
repo: Add checksums for files

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Add an array for files
Michael Tremer [Sun, 2 Feb 2025 14:10:30 +0000 (14:10 +0000)] 
repo: Add an array for files

This should allow us to add more items whenever we would need to.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Add the database path to the repository metadata
Michael Tremer [Sun, 2 Feb 2025 13:48:58 +0000 (13:48 +0000)] 
repo: Add the database path to the repository metadata

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agojson: Move functions into a separate file
Michael Tremer [Sun, 2 Feb 2025 13:42:15 +0000 (13:42 +0000)] 
json: Move functions into a separate file

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Use our own JSON functions to build repository metadata
Michael Tremer [Sun, 2 Feb 2025 13:29:54 +0000 (13:29 +0000)] 
repo: Use our own JSON functions to build repository metadata

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Sign the repository metadata instead of the database
Michael Tremer [Sat, 1 Feb 2025 16:18:24 +0000 (16:18 +0000)] 
repo: Sign the repository metadata instead of the database

I don't think that there is any chance that we will be able to get rid
of the JSON object.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agokeys: Give signing functions better names
Michael Tremer [Sat, 1 Feb 2025 15:53:56 +0000 (15:53 +0000)] 
keys: Give signing functions better names

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agotests: key: Remove unused variables
Michael Tremer [Sat, 1 Feb 2025 15:53:39 +0000 (15:53 +0000)] 
tests: key: Remove unused variables

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Refactor importing repositories
Michael Tremer [Sat, 1 Feb 2025 14:50:18 +0000 (14:50 +0000)] 
repo: Refactor importing repositories

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Make the static analyzer happy when importing repositories
Michael Tremer [Sat, 1 Feb 2025 14:43:02 +0000 (14:43 +0000)] 
repo: Make the static analyzer happy when importing repositories

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agomirrors: Import the correct headers
Michael Tremer [Sat, 1 Feb 2025 14:36:30 +0000 (14:36 +0000)] 
mirrors: Import the correct headers

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agoxfers: Use correct error code when a transfer fails
Michael Tremer [Sat, 1 Feb 2025 14:36:16 +0000 (14:36 +0000)] 
xfers: Use correct error code when a transfer fails

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agoxfer: Return positive error codes on verify
Michael Tremer [Sat, 1 Feb 2025 14:35:52 +0000 (14:35 +0000)] 
xfer: Return positive error codes on verify

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agohttpclient: Prevent that the event loop terminates too early
Michael Tremer [Sat, 1 Feb 2025 14:25:43 +0000 (14:25 +0000)] 
httpclient: Prevent that the event loop terminates too early

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agohttpclient: Keep WebSocket connections open
Michael Tremer [Sat, 1 Feb 2025 14:12:35 +0000 (14:12 +0000)] 
httpclient: Keep WebSocket connections open

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agohttpclient: Implicitly handle relaunch
Michael Tremer [Sat, 1 Feb 2025 14:10:03 +0000 (14:10 +0000)] 
httpclient: Implicitly handle relaunch

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agohttpclient: Launch transfers as soon as they are enqueued when not in standalone...
Michael Tremer [Sat, 1 Feb 2025 14:00:54 +0000 (14:00 +0000)] 
httpclient: Launch transfers as soon as they are enqueued when not in standalone mode

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agohttpclient: Shorten some function names
Michael Tremer [Sat, 1 Feb 2025 13:56:07 +0000 (13:56 +0000)] 
httpclient: Shorten some function names

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agoxfer: Remove circular dependency to HTTP client
Michael Tremer [Sat, 1 Feb 2025 13:49:10 +0000 (13:49 +0000)] 
xfer: Remove circular dependency to HTTP client

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agohttpclient: Refactor the queue management
Michael Tremer [Sat, 1 Feb 2025 13:40:03 +0000 (13:40 +0000)] 
httpclient: Refactor the queue management

It does not seem like a very good idea to give cURL all the handles at
the same time and let it sort it all out. Therefore, this is yet another
attempt to implement some half-decent queueing to implement parallel
downloads.

Fixes: #13812 - httpclient: Bring back a queue for transfers
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agoxfer: Don't verify digest when we did not get a positive response
Michael Tremer [Fri, 31 Jan 2025 16:20:03 +0000 (16:20 +0000)] 
xfer: Don't verify digest when we did not get a positive response

When servers were sending a 404 error page, the transfer failed because
of a digest mismatch which is not what we want.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agoxfer: Ensure we always cleanup on failure
Michael Tremer [Fri, 31 Jan 2025 14:41:46 +0000 (14:41 +0000)] 
xfer: Ensure we always cleanup on failure

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopakfire: Remove unused clone function
Michael Tremer [Fri, 31 Jan 2025 14:41:18 +0000 (14:41 +0000)] 
pakfire: Remove unused clone function

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agosnapshot: Clone pakfire with custom flags
Michael Tremer [Fri, 31 Jan 2025 14:40:18 +0000 (14:40 +0000)] 
snapshot: Clone pakfire with custom flags

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agosnapshot: Create a new snapshot if the cache dir does not exist
Michael Tremer [Fri, 31 Jan 2025 14:39:43 +0000 (14:39 +0000)] 
snapshot: Create a new snapshot if the cache dir does not exist

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agohttpclient: Configure some more sensible defaults
Michael Tremer [Fri, 31 Jan 2025 14:38:24 +0000 (14:38 +0000)] 
httpclient: Configure some more sensible defaults

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Anchor the key to the appdata
Michael Tremer [Fri, 31 Jan 2025 13:05:47 +0000 (13:05 +0000)] 
repo: Anchor the key to the appdata

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agoxfer: Tidy up mirror handling
Michael Tremer [Fri, 31 Jan 2025 12:46:42 +0000 (12:46 +0000)] 
xfer: Tidy up mirror handling

No functional changes

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agoxfer: For queued xfers, make sure we don't use an older mirror
Michael Tremer [Fri, 31 Jan 2025 12:34:49 +0000 (12:34 +0000)] 
xfer: For queued xfers, make sure we don't use an older mirror

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agomirrorlist: Don't free the JSON object when checking it's type
Michael Tremer [Fri, 31 Jan 2025 12:32:30 +0000 (12:32 +0000)] 
mirrorlist: Don't free the JSON object when checking it's type

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agomirrors: Disable instead of "broken"
Michael Tremer [Fri, 31 Jan 2025 12:19:08 +0000 (12:19 +0000)] 
mirrors: Disable instead of "broken"

This patch also implements this all with flags.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agomirrors: Evaluate the status code
Michael Tremer [Fri, 31 Jan 2025 12:12:24 +0000 (12:12 +0000)] 
mirrors: Evaluate the status code

With some errors, there is no point at all to keep trying.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agomirrors: Refactor mirror handling
Michael Tremer [Fri, 31 Jan 2025 12:00:34 +0000 (12:00 +0000)] 
mirrors: Refactor mirror handling

xfers will now immediately get a mirror assigned when they have a
mirrorlist set so that we don't have to play any games later.

When an xfer has failed, we will ask for another mirror and run again.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agomirror: Ensure paths always have a trailing slash
Michael Tremer [Fri, 31 Jan 2025 11:57:12 +0000 (11:57 +0000)] 
mirror: Ensure paths always have a trailing slash

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agocontrib: Enable mirror list for stable
Michael Tremer [Fri, 31 Jan 2025 10:46:17 +0000 (10:46 +0000)] 
contrib: Enable mirror list for stable

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Achor the mirrorlist to the appdata
Michael Tremer [Fri, 31 Jan 2025 10:45:45 +0000 (10:45 +0000)] 
repo: Achor the mirrorlist to the appdata

This is now possible because we won't circle-reference Pakfire any more
since we have the ctx object.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Instead of passing around flags, automatically free the repo
Michael Tremer [Fri, 31 Jan 2025 10:09:52 +0000 (10:09 +0000)] 
repo: Instead of passing around flags, automatically free the repo

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Add reference counting to appdata
Michael Tremer [Fri, 31 Jan 2025 10:03:34 +0000 (10:03 +0000)] 
repo: Add reference counting to appdata

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopakfire: Include flags when cloning an instance
Michael Tremer [Fri, 31 Jan 2025 09:56:58 +0000 (09:56 +0000)] 
pakfire: Include flags when cloning an instance

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopakfire: Clean up after failing to create a temporary directory
Michael Tremer [Fri, 31 Jan 2025 09:50:52 +0000 (09:50 +0000)] 
pakfire: Clean up after failing to create a temporary directory

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agocompress: Free the cookie if level parsing fails
Michael Tremer [Fri, 31 Jan 2025 09:44:15 +0000 (09:44 +0000)] 
compress: Free the cookie if level parsing fails

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopakfire: Include local repo name in path
Michael Tremer [Thu, 30 Jan 2025 22:54:47 +0000 (22:54 +0000)] 
pakfire: Include local repo name in path

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Use function to check repo name
Michael Tremer [Thu, 30 Jan 2025 22:53:49 +0000 (22:53 +0000)] 
repo: Use function to check repo name

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agolog buffer: Removed unused r
Michael Tremer [Thu, 30 Jan 2025 22:50:23 +0000 (22:50 +0000)] 
log buffer: Removed unused r

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agoarchive: Compose path after all other metadata has been set
Michael Tremer [Thu, 30 Jan 2025 22:47:51 +0000 (22:47 +0000)] 
archive: Compose path after all other metadata has been set

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Check pointers before trying to free them
Michael Tremer [Thu, 30 Jan 2025 22:47:25 +0000 (22:47 +0000)] 
repo: Check pointers before trying to free them

This is again for the static analyzer

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Make the static analyzer happy again
Michael Tremer [Thu, 30 Jan 2025 22:39:03 +0000 (22:39 +0000)] 
repo: Make the static analyzer happy again

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Actually copy files to the right place
Michael Tremer [Thu, 30 Jan 2025 22:20:37 +0000 (22:20 +0000)] 
repo: Actually copy files to the right place

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Implement the reverse of pakfire_package_get_path()
Michael Tremer [Thu, 30 Jan 2025 22:07:21 +0000 (22:07 +0000)] 
repo: Implement the reverse of pakfire_package_get_path()

This hopefully fixes that we will copy/link packages to themselves.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Don't try to copy the package into the same repository
Michael Tremer [Thu, 30 Jan 2025 21:39:19 +0000 (21:39 +0000)] 
repo: Don't try to copy the package into the same repository

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepos: Ensure the repo is always internalized
Michael Tremer [Thu, 30 Jan 2025 21:39:02 +0000 (21:39 +0000)] 
repos: Ensure the repo is always internalized

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agotests: repo: Usual EQUALS macro to show the true figures
Michael Tremer [Thu, 30 Jan 2025 21:33:34 +0000 (21:33 +0000)] 
tests: repo: Usual EQUALS macro to show the true figures

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopackages: Allow passing a repository for faster caching
Michael Tremer [Thu, 30 Jan 2025 21:00:50 +0000 (21:00 +0000)] 
packages: Allow passing a repository for faster caching

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Automatically sync local repositories with their index
Michael Tremer [Thu, 30 Jan 2025 20:51:06 +0000 (20:51 +0000)] 
repo: Automatically sync local repositories with their index

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopackagelist: Add helper function to check if a certain path is on the list
Michael Tremer [Thu, 30 Jan 2025 20:50:05 +0000 (20:50 +0000)] 
packagelist: Add helper function to check if a certain path is on the list

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopackages: Fix destroying a package
Michael Tremer [Thu, 30 Jan 2025 20:43:16 +0000 (20:43 +0000)] 
packages: Fix destroying a package

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Have the function to return all packages as list create the list
Michael Tremer [Thu, 30 Jan 2025 20:06:06 +0000 (20:06 +0000)] 
repo: Have the function to return all packages as list create the list

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopackages: Introduce a function to return the expected path
Michael Tremer [Thu, 30 Jan 2025 20:05:07 +0000 (20:05 +0000)] 
packages: Introduce a function to return the expected path

Since we need the paths in other places, this is the best way.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Don't do any path voodoo for internal repositories
Michael Tremer [Thu, 30 Jan 2025 19:31:36 +0000 (19:31 +0000)] 
repo: Don't do any path voodoo for internal repositories

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agotransaction: Use the new check to find available packages
Michael Tremer [Thu, 30 Jan 2025 17:07:23 +0000 (17:07 +0000)] 
transaction: Use the new check to find available packages

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Pass on the correct error code if we could not open the database
Michael Tremer [Thu, 30 Jan 2025 17:06:23 +0000 (17:06 +0000)] 
repo: Pass on the correct error code if we could not open the database

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopackage: Build a unified way to check if a package exists
Michael Tremer [Thu, 30 Jan 2025 17:00:04 +0000 (17:00 +0000)] 
package: Build a unified way to check if a package exists

This performs a quick stat() as well.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Make path composition public
Michael Tremer [Thu, 30 Jan 2025 16:59:44 +0000 (16:59 +0000)] 
repo: Make path composition public

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Simply scan again on forced refresh of local repos
Michael Tremer [Thu, 30 Jan 2025 16:14:05 +0000 (16:14 +0000)] 
repo: Simply scan again on forced refresh of local repos

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agorepo: Make the write metadata function public
Michael Tremer [Thu, 30 Jan 2025 16:10:36 +0000 (16:10 +0000)] 
repo: Make the write metadata function public

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopakfire: Remove the refresh function
Michael Tremer [Thu, 30 Jan 2025 16:02:43 +0000 (16:02 +0000)] 
pakfire: Remove the refresh function

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopakfire: Don't refresh the local repository sooner than the others
Michael Tremer [Thu, 30 Jan 2025 16:02:13 +0000 (16:02 +0000)] 
pakfire: Don't refresh the local repository sooner than the others

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopython: Drop Pakfire.refresh()
Michael Tremer [Thu, 30 Jan 2025 15:57:41 +0000 (15:57 +0000)] 
python: Drop Pakfire.refresh()

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agopakfire: Refresh repos once all have been created
Michael Tremer [Thu, 30 Jan 2025 15:56:37 +0000 (15:56 +0000)] 
pakfire: Refresh repos once all have been created

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agobuild: Move creating the local repository into Pakfire
Michael Tremer [Thu, 30 Jan 2025 15:54:04 +0000 (15:54 +0000)] 
build: Move creating the local repository into Pakfire

Pakfire is kind of the thing that should do the setup. That way, we have
it all in one place instead of two places of setup.

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agocli: The shell environment is obviously local, too
Michael Tremer [Thu, 30 Jan 2025 15:25:04 +0000 (15:25 +0000)] 
cli: The shell environment is obviously local, too

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
4 months agocontrib: Remove the local repo from the configuration
Michael Tremer [Thu, 30 Jan 2025 15:21:36 +0000 (15:21 +0000)] 
contrib: Remove the local repo from the configuration

Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>