Commit Graph

1845 Commits

Author SHA1 Message Date
Andrey Smirnov 61e00b5fbd Test updates for Travis CI
Travis is running Trusty with GPG 2.0.x, which is
much different from 2.1.x.

Add tests for default key signing.

Add test for gpg1/2 in functional.
2018-10-10 01:34:58 +03:00
Andrey Smirnov 1b2fccb615 Compatibility with GnuPG 1.x and 2.x, auto-detect GnuPG version
* aptly can sign and verify without issues with GnuPG 1.x and 2.x
* aptly auto-detects GnuPG version and adapts accordingly
* aptly automatically finds suitable GnuPG version

Majority of the work was to get unit-tests which can work with GnuPG 1.x & 2.x.
Locally I've verified that aptly supports GnuPG 1.4.x & 2.2.x. Travis CI
environment is based on trusty, so it runs gpg2 tests with GnuPG 2.0.x.

Configuration parameter gpgProvider now supports three values for GnuPG:

* gpg (same as before, default): use GnuPG 1.x if available (checks gpg, gpg1),
otherwise uses GnuPG 2.x; for aptly users who already have GnuPG 1.x
environment (as it was the only supported version) nothing should change; new
users might start with GnuPG 2.x if that's their installed version

* gpg1 looks for GnuPG 1.x only, fails otherwise

* gpg2 looks for GnuPG 2.x only, fails otherwise
2018-10-10 01:34:00 +03:00
Oliver Sauder 702c1ff217 Merge pull request #680 from sliverc/with_installer
Add support to mirror non package installer files
2018-09-27 09:50:37 +02:00
Oliver Sauder d1b2814ec6 Merge branch 'master' into with_installer 2018-09-27 09:35:09 +02:00
Andrey Smirnov ec57d1786c Merge pull request #780 from aptly-dev/773-non-armored-sig
Support for non-armored detached signatures
2018-09-26 16:37:42 +03:00
Andrey Smirnov 9f7c1f90ec Support for non-armored detached signatures 2018-09-26 01:36:52 +03:00
Oliver Sauder e23e30eb44 Merge branch 'master' into with_installer 2018-09-21 13:26:15 +02:00
Andrey Smirnov 2b4a61b84c Merge pull request #778 from aptly-dev/go-1-11
Bump Go versions with Go 1.11 release
2018-09-20 20:15:52 +03:00
Andrey Smirnov fbafde6e27 Bump Go versions with Go 1.11 release 2018-09-19 01:23:17 +03:00
Andrey Smirnov 14e5a75d35 Merge pull request #776 from urpylka/master
Replace Docker container w aptly & nginx in README
2018-09-14 23:49:58 +03:00
Artem Smirnov ea32d8627e Update AUTHORS 2018-09-14 01:29:11 +03:00
Artem Smirnov 814a0498df Little syntax fix 2018-09-14 01:24:21 +03:00
Artem Smirnov e45f85cc1e Replace to new docker container w aptly & nginx
Old project not supported long time
2018-09-14 01:22:32 +03:00
Oliver Sauder 1e9c032072 Merge pull request #774 from nuclearsandwich/update-contributing-docs
Use github.com/aptly-dev/aptly as the go package path.
2018-09-13 08:42:58 +02:00
Steven! Ragnarök c741cca5f2 Use github.com/aptly-dev/aptly as the go package path.
Without this change the first time setup instructions fail at the `make install` stage.
2018-09-13 00:21:14 -04:00
Andrey Smirnov 72ff71f59c Merge pull request #766 from aptly-dev/761-more-lazy
Reimplement DB collections for mirrors, repos and snapshots
2018-08-21 17:00:08 +03:00
Andrey Smirnov 699323e2e0 Reimplement DB collections for mirrors, repos and snapshots
See #765, #761

Collections were relying on keeping in-memory list of all the objects
for any kind of operation which doesn't scale well the number of
objects in the database.

With this rewrite, objects are loaded only on demand which might
be pessimization in some edge cases but should improve performance
and memory footprint signifcantly.
2018-08-21 01:08:14 +03:00
Andrey Smirnov fb5985bbbe Merge pull request #767 from aptly-dev/fix-sys-test-take-N
Fix system tests on `master` branch
2018-08-20 17:55:54 +03:00
Andrey Smirnov 5a9f4bee12 Fix system tests on master branch 2018-08-17 18:11:49 +03:00
Andrey Smirnov 4717793d8e Merge pull request #765 from aptly-dev/761-lazy-iteration
Implement lazy iteration (ForEach) over collections
2018-08-16 16:44:05 +03:00
Andrey Smirnov de38011dd2 Add simple benchmark for SnapshotCollection.ForEach() 2018-08-14 00:56:15 +03:00
Andrey Smirnov 0f4bbc4752 Implement lazy iteration (ForEach) over collections
See #761

aptly had a concept of loading small amount of info per each object
into memory once collection is accessed for the first time.

This might have simplified some operations, but it doesn't scale well
with huge aptly databases.

This is just intermediate step towards better memory management -
list of objects is not loaded unless some method is called.
`ForEach` method (mainly used in cleanup) is reimplemented to
iterate over database without ever loading all the objects into memory.

Memory was even worse with previous approach, as for each item usually
`LoadComplete()` is called, which pulls even more data into memory
and item stays in memory till the end of the iteration as it is referenced
from `collection.list`.

For the subsequent PR: reimplement `ByUUID()` and probably other methods
to avoid loading all the items into memory, at least for all the collecitons
except for published repos. When published repository is being loaded, it
might pull source local repo which in turn would trigger loading for all the
local repos which is not acceptable.
2018-08-04 00:26:02 +03:00
Andrey Smirnov 86a1c41e5d Merge pull request #762 from aptly-dev/761-flush-collections
Lower memory usage for `aptly db cleanup`
2018-08-01 00:29:18 +03:00
Andrey Smirnov 021b8c4cff Lower memory usage for aptly db cleanup
This is not a complete fix, but the easiest first step.

During `db cleanup`, aptly is loading every repo/mirror/... into memory,
and even though each object is processed only once, collection holds
a reference to all the loaded objects, so they won't be GC'd until
process exits.

CollectionFactory.Flush() releases pointers to collection objects,
making objects egligble for GC.

This is not a complete fix, as during iteration we could have tried
to release a link to every object being GCed and that would have
helped much more.
2018-07-20 01:04:51 +03:00
Andrey Smirnov bcacb7b7f0 Merge pull request #760 from aptly-dev/756-fix
Keep checksum of not compressed index file even if it's not uploaded
2018-07-16 23:50:48 +03:00
Andrey Smirnov 747b9752ce Keep checksum of not compressed index file even if it's not uploaded
Fixes: #756
2018-07-14 00:17:36 +03:00
Andrey Smirnov b0be6c8a7a Merge pull request #755 from aptly-dev/gpg2-gpg1
Unit tests for PGP signing/verification
2018-07-11 19:19:37 +03:00
Andrey Smirnov 58c7358113 Unit tests for PGP signing/verification
These unit-tests cover operations via both PGP providers:
built-in `openpgp` and external `gpg`.

Next step is to run these tests for gpg1 & gpg2
as separate entities.
2018-07-11 01:07:13 +03:00
Oliver Sauder b1a2523ef0 Add unit test for remote and http 2018-07-06 15:02:37 +02:00
Oliver Sauder b7323db31b Add detached signature to installer hashsum file 2018-07-06 15:02:37 +02:00
Oliver Sauder 2e52692ba6 Test LinkFromPool with nested filenames 2018-07-06 15:02:37 +02:00
Oliver Sauder 0075ead526 Simplify package function signature LinkFromPool 2018-07-06 15:02:37 +02:00
Oliver Sauder 6df4a746f1 Clarify doc strings 2018-07-06 15:02:37 +02:00
Oliver Sauder 074904ee92 Allow editing of with-installer mirror flag 2018-07-06 15:02:37 +02:00
Oliver Sauder 108b0ea226 Add support to mirror non package installer files 2018-07-06 15:02:37 +02:00
Andrey Smirnov 9a704de43b Merge pull request #754 from aviau/lzma
switch to packaged lzma package
2018-06-23 00:58:50 +03:00
aviau 7dfc12d138 switch to packaged lzma package 2018-06-22 12:44:23 -04:00
Harald Sitter 9000446663 Merge pull request #753 from aviau/official-uuid
dep: use official uuid package
2018-06-22 11:14:35 +02:00
aviau 814ac6c28c dep: use official uuid package 2018-06-21 16:12:45 -04:00
Oliver Sauder d1a284298f Merge pull request #751 from sliverc/repo_include_api
Expose repo include through API
2018-06-19 16:02:22 +02:00
Oliver Sauder 9509629bcf Add changes test to increase coverage 2018-06-19 15:40:38 +02:00
Oliver Sauder f1882cfe2c Expose repo include through API 2018-06-19 15:39:09 +02:00
Andrey Smirnov 90e446ec16 Merge pull request #743 from aptly-dev/gpg2-skip
Skip GPG version check `APTLY_SKIP_GPG_VERSION_CHECK=1` is set in the env
2018-06-19 00:42:04 +03:00
Oliver Sauder 464ed8269b Merge pull request #750 from sliverc/fix_nvidia_test
Fix failing SHA512 checksums only test
2018-06-18 08:59:52 +02:00
Oliver Sauder 57a51d94ed Fix failing SHA512 checksums only test
This test has been failing very often because of changes in nvidia
repository. As this test is not related to filtering
remove number of filtered packages from output for a more robust test.
2018-06-15 15:43:37 +02:00
Andrey Smirnov 53c557271d Merge pull request #744 from aptly-dev/nightly-builds
Move release build to Travis CI
2018-06-12 00:48:00 +03:00
Andrey Smirnov b6fe16095b Move nightly builds to Travis CI
This updates previous work in #739 to build
Debian packages and zip files for other OS.

All the build artifacts are uploaded to S3
public bucket `aptly-nightly` so that there's
archive for all the builds.

All `.deb` packages are automatically uploaded
to repo.aptly.info/nightly on build.
2018-06-12 00:26:44 +03:00
Oliver Sauder 6a1c439325 Merge pull request #747 from tomascassidy/patch-1
Fix typo
2018-06-05 21:54:34 +02:00
tomascassidy 06b0be7bad Fix typo 2018-06-05 16:23:06 +10:00
Andrey Smirnov e5acf22285 Skip GPG version check APTLY_SKIP_GPG_VERSION_CHECK=1 is set in the environment
This allows to force using GnuPG 2.x even if aptly is not 100% ready
to use it.
2018-05-25 00:23:50 +03:00