1
0
mirror of https://github.com/regclient/regclient.git synced 2025-04-18 22:44:00 +03:00

23 Commits

Author SHA1 Message Date
Brandon Mitchell
1eb1ea4b34
Feat: Refactor logging to use log/slog
This updates the regclient Go library.
Existing users of logrus will continue to work using a logrus handler to slog.
Updates to the various commands will be made in a future commit.

Signed-off-by: Brandon Mitchell <git@bmitch.net>
2024-11-10 17:14:57 -05:00
Brandon Mitchell
d6b815f3e0
Fix: Prevent data race when reading blob and seeking
A seek to the current location is used to monitor the progress, making it possible for the callback to panic from a data race.

Signed-off-by: Brandon Mitchell <git@bmitch.net>
2024-08-28 16:52:53 -04:00
Brandon Mitchell
4bd605f9ef
Chore: Remove ReqPerSec in tests
This is no longer needed to speed up tests since request per second does not have a default setting.

Signed-off-by: Brandon Mitchell <git@bmitch.net>
2024-08-20 16:08:19 -04:00
Brandon Mitchell
eea06e2a5c
Refactoring the type package
I feel like I need to explain, this is all to move the descriptor package.
The platform package could not use the predefined errors in types because of a circular dependency from descriptor.
The most appropriate way to reorg this is to move descriptor out of the type package since it was more complex than a self contained type.
When doing that, type aliases were needed to avoid breaking changes to existing users.
Those aliases themselves caused circular dependency loops because of the media types and errors, so those were also pulled out to separate packages.
All of the old values were aliased and deprecated, and to fix the linter, those deprecations were fixed by updating the imports... everywhere.

Signed-off-by: Brandon Mitchell <git@bmitch.net>
2024-03-04 15:43:18 -05:00
Brandon Mitchell
cc0ae63f8f
Replace t.Error and return with t.Fatal
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2024-02-27 15:33:52 -05:00
Brandon Mitchell
caa949c329
Replace uuid with random id generator
This removes an unneeded dependency.

Signed-off-by: Brandon Mitchell <git@bmitch.net>
2024-02-26 09:12:15 -05:00
Brandon Mitchell
3a101001a9
Cancel failed blob uploads to a registry
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2024-02-21 14:52:31 -05:00
Brandon Mitchell
0ad815ee02
Update tests to use t.Parallel where possible
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2023-10-02 20:09:11 -04:00
Brandon Mitchell
b2a7336453
Reorder Go imports to move local packages last
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2023-09-30 22:21:10 -04:00
Brandon Mitchell
d2ca5fa5eb
Add concurrency to image copy
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2023-05-06 09:01:35 -04:00
Brandon Mitchell
1963eacd3e
Deprecate redundant regclient options
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2023-04-12 19:56:54 -04:00
Brandon Mitchell
d996200617
Fix handling of data field
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2023-02-25 10:05:47 -05:00
Brandon Mitchell
0117209286
Adding Seek to reghttp to enable retries
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2022-10-31 21:29:04 -04:00
Brandon Mitchell
585e17b190
Recover a failed chunk with a status request
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2022-10-10 21:09:04 -04:00
Brandon Mitchell
e90d7fcbde Bumping to Go 1.19 and GHA versions
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2022-08-27 10:19:19 -04:00
Brandon Mitchell
0a50b7b9ee Fix Content-Range header
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2022-05-17 20:00:39 -04:00
Brandon Mitchell
c800decc9f Improve handling of external URLs
- Attempt to pull external blob from registry
- Handle blob pull to external URL
- Copy option to copy external blobs
- Mod option to remove external URLs from descriptors

Signed-off-by: Brandon Mitchell <git@bmitch.net>
2022-05-07 20:24:06 -04:00
Brandon Mitchell
29a0d79421 Parse the descriptor data field when available
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2022-03-07 08:51:54 -05:00
Brandon Mitchell
99ee6bdc35 Updating blob methods to use descriptors
Descriptors will be useful when Data field is added.

Signed-off-by: Brandon Mitchell <git@bmitch.net>
2022-03-06 14:48:07 -05:00
Brandon Mitchell
5c3f85f253 Refactor blob like manifests, add SetConfig
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2022-02-22 21:15:03 -05:00
Brandon Mitchell
5fa181ff08 regclient linting, scheme API rename
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2022-02-04 15:25:14 -05:00
Brandon Mitchell
4b796535cb Adjusting types to use New/Opts initializers
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2022-01-02 21:05:09 -05:00
Brandon Mitchell
1d93bf7bb6 Moving regclient package to top level
Signed-off-by: Brandon Mitchell <git@bmitch.net>
2021-12-29 14:51:11 -05:00