Commit Graph

758 Commits

Author SHA1 Message Date
Zhang Xiao
e2ebcbb02a Release file: support Version field
https://wiki.debian.org/DebianRepository/Format#Version

The Version field, if specified, shall be the version of the release.
On the other hand, if not set or set to an empty value, the Version
field will not be included in the Release file.

Signed-off-by: Zhang Xiao <xiao.zhang@windriver.com>
2026-03-03 07:38:44 +00:00
André Roth
9defe70190 Merge pull request #1537 from tonobo/reproducible-publish
Add SOURCE_DATE_EPOCH support for reproducible builds
2026-02-28 12:46:57 +01:00
Tim Foerster
49f342878a Add SOURCE_DATE_EPOCH support for reproducible builds
Implement support for the SOURCE_DATE_EPOCH environment variable as
specified by reproducible-builds.org. When set, this variable overrides
the current timestamp in the Release file's Date and Valid-Until fields,
enabling reproducible filesystem publishes.

- Read SOURCE_DATE_EPOCH environment variable in Publish()
- Use the epoch timestamp for both Date and Valid-Until fields
- Gracefully fallback to current time if unset or invalid
- Add comprehensive tests for valid and invalid SOURCE_DATE_EPOCH values
2026-02-20 07:24:52 +01:00
Zhang Xiao
1f29c65a95 fix t06_publish/PublishSnapshot43Test_gold gold error
Signed-off-by: Zhang Xiao <xiao.zhang@windriver.com>
2026-02-03 07:12:04 +00:00
André Roth
c6a9f82358 multi sign: add test 2026-01-26 11:26:40 +01:00
Ales Bregar
4ba4c0cba6 system test configuration fix 2026-01-24 10:55:15 +01:00
André Roth
0db9797c4e add test 2026-01-16 14:50:09 +01:00
Zhang Xiao
a2ffffedc1 Support updating label and origin domain of publish
Signed-off-by: Zhang Xiao <xiao.zhang@windriver.com>
2026-01-16 14:50:09 +01:00
Roman Lebedev
a4cc9211d6 InRelease file: support Signed-By field
https://wiki.debian.org/DebianRepository/Format#Signed-By says:
> **Signed-By**
> An optional field containing a comma separated list of
> OpenPGP key fingerprints to be used for validating
> the next Release file. The fingerprints must consist
> only of hex digits and may not contain spaces.
> The fingerprint specifies either the key the Release file
> must be signed with or the key the signature key must be
> a subkey of. The later match can be disabled by appending
> an exclamation mark to the fingerprint.
>
> If the field is present, a client should only accept future updates
> to the repository that are signed with keys listed in the field.
> The field should be ignored if the Valid-Until field is not present
> or if it is expired.

For both the CLI tools and JSON, the field is taken as a string verbatim.

When specified, we must also provide `Valid-Until` field,
and i'm not sure there is an 'infinity' value for it,
so 100 years will have to do?

Fixes https://github.com/aptly-dev/aptly/issues/1497
2025-12-30 06:06:48 +03:00
Ryan Gonzalez
33a2f70d07 system-test: Allow skipping coverage
Enabling coverage near-doubles the incremental build time and adds
overhead to individual tests on the order of **5-10x** or more. It's not
essential to have this for quick local system-test runs, so add an option
to disable it.
2025-09-23 16:25:46 -05:00
Ryan Gonzalez
568a9ce4d5 docker: Preserve the go build cache
Otherwise, every `make docker-...` invocation will need to rebuild
everything from scratch.
2025-09-23 16:25:46 -05:00
Ryan Gonzalez
29ac9c1919 system-test: Fix crash when a comparison with a non-string value fails
`orig` isn't necessarily a string, so the string concatenation here can
raise a TypeError.
2025-09-23 16:25:46 -05:00
Itay Porezky
dc884e6052 Removing non related actions from mirror update 2025-06-29 21:55:27 +03:00
dependabot[bot]
32f03bfd62 build(deps): bump requests from 2.28.2 to 2.32.4 in /system
Bumps [requests](https://github.com/psf/requests) from 2.28.2 to 2.32.4.
- [Release notes](https://github.com/psf/requests/releases)
- [Changelog](https://github.com/psf/requests/blob/main/HISTORY.md)
- [Commits](https://github.com/psf/requests/compare/v2.28.2...v2.32.4)

---
updated-dependencies:
- dependency-name: requests
  dependency-version: 2.32.4
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-10 03:23:26 +00:00
André Roth
5b04d4fbe1 system-tests: abort on failure 2025-06-09 13:17:54 +02:00
André Roth
1566e193f6 system-test: enable faketime optionally per test 2025-06-09 13:17:54 +02:00
André Roth
601c8e9d52 tests: use faketime to prevent expired signing keys 2025-06-08 20:05:49 +02:00
André Roth
27c15680e8 Merge pull request #1445 from silkeh/fix-db-references
Remove corrupt package references in `db recover`
2025-05-01 10:27:42 +02:00
Silke Hofstra
d8a4a28259 Remove corrupt package references in db recover
When aptly crashes it is possible to get a corrupt database with a dangling key reference.
This results in an error with 'key not found', eg:

    ERROR: unable to load package Pall example-package 1.2.3 778cf6f877bf6e2d: key not found

This change makes `db recover` fix this situation by removing the dangling references.
2025-04-30 12:21:34 +02:00
André Roth
f7057a9517 go1.24: fix lint, unit and system tests
- development env: base on debian trixie with go1.24
- lint: run with default config
- fix lint errors
- fix unit tests
- fix system test
2025-04-26 13:29:50 +02:00
André Roth
22bc2f9d0f system-tests: improve sorted compare
sort both aptly output and gold file. output original output for
debugging on failure.

* Makefile: enable CAPTURE=1 env variable for capturing gold files
* docker-system-test: use AWS env vars for S3 tests
* fix system tests timing issue with order of gpg logs in publish tests
2025-04-25 00:51:59 +02:00
André Roth
c07bf2b108 s3: add debug logs for commands
* initialize zerolog for commands
* Change default log format: remote colors and timestamp
2025-04-24 12:13:38 +02:00
André Roth
664a5cd675 go1.23: fix system test 2025-04-20 11:57:42 +02:00
André Roth
8546cf31ce add test: snapshot empty mirror 2025-01-11 20:00:42 +01:00
André Roth
5a18428666 aptly.conf: fix s3 example 2025-01-11 15:25:53 +01:00
Gordian Schoenherr
8830354027 Extend system tests for @file filter syntax 2024-12-20 10:59:29 +09:00
Gordian Schoenherr
2467674fca Update system tests 2024-12-19 16:05:21 +09:00
André Roth
93650efddb Merge pull request #1404 from schoenherrg/fix/with-sources-ignored
Fix `-with-sources` not fetching differently named source packages
2024-12-11 13:01:30 +01:00
André Roth
e50a5e175f update documentation and man page 2024-12-11 12:02:52 +01:00
André Roth
a7d6782176 add test and improve config error messages 2024-12-11 12:02:52 +01:00
André Roth
a15d8a3f7b add test 2024-12-11 12:02:52 +01:00
André Roth
4e566b4692 fix tests and lint 2024-12-11 12:02:52 +01:00
André Roth
e92afd8f78 fix unit tests on arm
and fix etcd data dir
2024-12-11 10:40:44 +01:00
André Roth
280563caa8 unit-tests: allow running as user 2024-12-11 10:40:44 +01:00
André Roth
09c56342d2 fix json 2024-12-11 10:40:44 +01:00
André Roth
ea80f6d49c write commented json default config 2024-12-11 10:40:44 +01:00
André Roth
1f469e23b5 fix optional params 2024-12-11 10:40:44 +01:00
André Roth
5e91b10c8c improve test to check for source pkgs with different name 2024-12-11 05:33:38 +01:00
Gordian Schoenherr
8c3fe8dabb Fix failing system test
The fix of the -with-filter flag causes the following previously
missing source files to be downloaded, so I updated the test file.

```
rkward_0.7.5-1~bullseyecran.0.debian.tar.xz
rkward_0.7.5-1~bullseyecran.0.dsc
rkward_0.7.5.orig.tar.gz
rpy2_3.5.12-1~bullseyecran.0.debian.tar.xz
rpy2_3.5.12-1~bullseyecran.0.dsc
rpy2_3.5.12.orig.tar.gz
```
2024-12-10 11:52:55 +09:00
André Roth
320307f504 graph: do not remove tempfile when opening in viewer 2024-12-04 17:30:27 +01:00
André Roth
d80b905945 run azure tests in docker 2024-11-17 17:44:31 +01:00
André Roth
d96ef0f178 Merge pull request #1393 from aptly-dev/improve/debianization
Improve/debianization
2024-11-17 17:38:47 +01:00
André Roth
d2b9adf6f2 Add a test to confirm that skel files added with the same path as a repository file do not override the repository file.
Co-authored-by: iofq <cjriddz@protonmail.com>
2024-11-17 14:17:14 +01:00
André Roth
53c2f8b778 debian: add lintian
and fix/improve cross building. build now with PIE and RELRO
2024-11-17 14:10:30 +01:00
Mauro Regli
1357d246d8 rename addon files to skel files 2024-11-17 14:09:37 +01:00
Mauro Regli
03f189b62c add first test of addon files 2024-11-17 14:09:37 +01:00
André Roth
c86b888b0a add tests 2024-11-08 19:00:18 +01:00
André Roth
596f59d3c4 fix tests 2024-11-08 17:07:37 +01:00
André Roth
19d213d748 fix tests 2024-11-08 15:55:01 +01:00
André Roth
dd4f90e4c2 Revert "use git-lfs for test files"
This reverts commit bf4b660568.
2024-11-08 15:23:31 +01:00