mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-06-16 07:10:54 +00:00
Compare commits
295 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| d90825f4f0 | |||
| 5be757e35e | |||
| e51c1894bf | |||
| 24fcde56b6 | |||
| 7390e19e03 | |||
| 0aa0c0a995 | |||
| 1d10dd6ce7 | |||
| e28fa416ab | |||
| d6c7b1d770 | |||
| 92ea4a2505 | |||
| 3e5e0fc119 | |||
| 9fa4248e3b | |||
| d958a146f7 | |||
| 125a7c2c07 | |||
| d403150d77 | |||
| 4e6c52ec2a | |||
| 90ffa6883a | |||
| 4a85be68a0 | |||
| 19e4040b17 | |||
| 767323fde9 | |||
| 5be8231598 | |||
| e9f1947156 | |||
| 3d8c906c7f | |||
| f1c0205e21 | |||
| 7d124ac5c0 | |||
| abebdb94a5 | |||
| 7b45c4d380 | |||
| 6cbd80566f | |||
| 274bb2732a | |||
| 5935c7d5a0 | |||
| 4ab07fef23 | |||
| e7abc4d39a | |||
| 71b045366d | |||
| 7abac9537f | |||
| 9d64dc2fd9 | |||
| 6e1b49daa8 | |||
| 7bbfe88008 | |||
| 4c5db7d98c | |||
| cab280ebc0 | |||
| 2f78cf5129 | |||
| bc3755dcf7 | |||
| a5730feb9d | |||
| b8f084b1dc | |||
| 9fc50e347b | |||
| 034ab23ff1 | |||
| 865a0c92eb | |||
| b3a4eb8897 | |||
| 33536bd69f | |||
| 10bed44763 | |||
| 0111596d50 | |||
| 1df6ce531c | |||
| 1ad63d1786 | |||
| 895cf5e5c6 | |||
| 9b53deb97f | |||
| 6e9e9a6e31 | |||
| 90343b21d3 | |||
| 2369a2dadf | |||
| 237f43f8ba | |||
| 7fcac4ed49 | |||
| d52f325d99 | |||
| 921dfaddb9 | |||
| f642f3fde4 | |||
| f401cea76a | |||
| 76d3b27842 | |||
| 35ad56ff7f | |||
| 3bfc305df8 | |||
| 5ab866f0db | |||
| 12855db1a0 | |||
| e094d79b85 | |||
| 96394ecf38 | |||
| e9600f9d66 | |||
| 94ec8c4548 | |||
| bde3dcc5f5 | |||
| df10066c16 | |||
| 6b52a72359 | |||
| 608e0d8610 | |||
| 94c1b2b755 | |||
| c31ab7b43f | |||
| 0bbf61df95 | |||
| 1b58b88b02 | |||
| 61ef1fe798 | |||
| 863ec4dae9 | |||
| 5aa5b8d9cb | |||
| 37750cefda | |||
| 7be60cd8be | |||
| 606b701b00 | |||
| fe2f17d38a | |||
| 4aeba31a6a | |||
| 2086d424bd | |||
| 520eeea355 | |||
| dad2527182 | |||
| 9a3922fe17 | |||
| 9c2e95d614 | |||
| baba1165ff | |||
| a0610292a7 | |||
| de7f169043 | |||
| 97b7143f6d | |||
| 520b50e49b | |||
| 70cbc12ac7 | |||
| 9a01c64f68 | |||
| 673da76e55 | |||
| 146daa22a7 | |||
| 9150a75886 | |||
| 92bff40eb4 | |||
| 3fd90c74de | |||
| 5039f76fe8 | |||
| 15e14b2a93 | |||
| d41157bd54 | |||
| cfe853e791 | |||
| 4fa420699b | |||
| 2b9a7914fd | |||
| 3bf957c313 | |||
| 25dfd98672 | |||
| a1fd350573 | |||
| bbf5db745f | |||
| 884d695273 | |||
| 65a984ec2b | |||
| e06ecf5092 | |||
| 3bbd61d75b | |||
| 69f851124c | |||
| 5fef06100c | |||
| 40ba4ce958 | |||
| a8aeaff2a3 | |||
| d8fea9f142 | |||
| f33a9dccf8 | |||
| 5c4f97f88e | |||
| 4c7796ca56 | |||
| e6e102a95c | |||
| fee581c722 | |||
| f398ffb183 | |||
| 60e578bad9 | |||
| 55fc2f4d0c | |||
| dc74239275 | |||
| 75ad96e9ca | |||
| 265d1373a1 | |||
| 814ee037d3 | |||
| 4ab22a5fc5 | |||
| 6222250104 | |||
| f2b328395d | |||
| f3732b1683 | |||
| 82ddc7f9ce | |||
| 5031adcb7f | |||
| c5322ff2f6 | |||
| a1f1cf307b | |||
| 1b0cad0f1b | |||
| 29c2603d61 | |||
| ea9657dae0 | |||
| b61875fa9c | |||
| 1308c2f774 | |||
| 63bc8282a0 | |||
| cd0626e825 | |||
| dc4b4a86a4 | |||
| bb6df8ee63 | |||
| 199b5ab9b8 | |||
| 5719d6fcdd | |||
| 29e4ea6ec0 | |||
| 491c8ebdd1 | |||
| 3afb6e47bf | |||
| f767136371 | |||
| 86162f0ef5 | |||
| f03f8378b9 | |||
| 074b35755d | |||
| a92de0d9bd | |||
| f966258772 | |||
| 7938eebdcd | |||
| dccf1acb78 | |||
| 20278a7b5d | |||
| d4268fd4c6 | |||
| e7af54999f | |||
| 916d5a22c2 | |||
| abdd341369 | |||
| a802160318 | |||
| a5c7bde1a3 | |||
| 217a8a8e92 | |||
| e85459c529 | |||
| 2edaf38386 | |||
| cc7f75370f | |||
| 829d9924c3 | |||
| 164cefe2a2 | |||
| 9ac2e25739 | |||
| 1de4d69922 | |||
| dbc5ba9458 | |||
| 1459919984 | |||
| 11b9382e56 | |||
| c49c3cac30 | |||
| 165c79394b | |||
| 8fa7bc9206 | |||
| 842cbc0e44 | |||
| 014f4c49d1 | |||
| c9f52ab9f4 | |||
| c44eb676b0 | |||
| d29fbb8acf | |||
| 1566f9a229 | |||
| b65434650c | |||
| 4ba3e0b941 | |||
| 535d7149bd | |||
| e8df80555c | |||
| d978ae5a15 | |||
| 8de7940335 | |||
| b6a1adf90e | |||
| 910b969894 | |||
| 476f17b84c | |||
| 1fe6cbdb4c | |||
| fb9f92e99e | |||
| 056182923a | |||
| be0e5f1dad | |||
| 5add1af33b | |||
| bda3b8dad2 | |||
| 5679b4b1db | |||
| 7730890e7c | |||
| 7d2ddd44c0 | |||
| ba8c42d70b | |||
| 09ad0121c6 | |||
| 23e839c80b | |||
| bed9fffa94 | |||
| 4c3e0f8b3c | |||
| c3bd6a3eea | |||
| 93294dcb18 | |||
| 9492994b8c | |||
| 0394a30dd7 | |||
| 83c0c03257 | |||
| 4c5aa19a8f | |||
| 8adb6e37eb | |||
| 12211e127c | |||
| 4345e93446 | |||
| 29bdd9ff26 | |||
| f6225c4983 | |||
| b49bcafd67 | |||
| 3cbca50cad | |||
| 018a6bd2c7 | |||
| 8c2cd7117c | |||
| 13e67ee7ca | |||
| a40e6dd5d8 | |||
| 89fd04febb | |||
| ee9fb8dfec | |||
| 1949e77df8 | |||
| 44079e1ce2 | |||
| 76a9eeda7c | |||
| 2dd9a49f05 | |||
| aa7a862631 | |||
| 66d1f3878b | |||
| 4f12259bc0 | |||
| c926f2bf05 | |||
| 1ee35b841d | |||
| 1a802d7428 | |||
| 056c3d6dad | |||
| 64760ea779 | |||
| d1027dd016 | |||
| 37862fdb5c | |||
| bbc8eae484 | |||
| 8fd4a508f8 | |||
| 26ac72d142 | |||
| bbebb43808 | |||
| 35deb90803 | |||
| 9fdc90cf13 | |||
| 6fe53d9508 | |||
| 9141f1b343 | |||
| 80804b9b49 | |||
| 034a67ff7e | |||
| 8d6cc854aa | |||
| 0ed02327b0 | |||
| fac32a6def | |||
| 1d0a51886f | |||
| e65a50161d | |||
| 950bfadaba | |||
| fbac926044 | |||
| 7efd573010 | |||
| 2b589d1ded | |||
| 63762ba279 | |||
| fa01fd6ed5 | |||
| 57598ec9de | |||
| 5ccd8663f6 | |||
| d663c8e3cc | |||
| 22a9d9a369 | |||
| b6ebdd9c7b | |||
| 94ac71d4ce | |||
| 9666e1cf41 | |||
| 35bd883d40 | |||
| 8faca75d06 | |||
| b1deaba0bd | |||
| 32417bbb7e | |||
| b3596e7471 | |||
| 9bbd6b21b9 | |||
| 7d35c5c5bb | |||
| 7d1f66e537 | |||
| 2e9f8b8064 | |||
| 5703f81bac | |||
| 7f8edee078 | |||
| 991aa67efb | |||
| f6e8e05dad | |||
| 09c07b24dc | |||
| 3699db53b5 | |||
| 0b2469eef2 | |||
| 1d892e6b99 | |||
| f4e87ed80b |
Vendored
+33
@@ -0,0 +1,33 @@
|
||||
aptly (1.6.0+ds1-1) unstable; urgency=medium
|
||||
|
||||
- aptly-api: configuration file is now /etc/aptly.conf, and `rootDir`
|
||||
defaults to `~/.aptly`
|
||||
|
||||
- aptly-api: default port is 8080, as declared in
|
||||
`/etc/default/aptly-api`
|
||||
|
||||
- aptly: swagger support is disabled, but will be re-enabled after the
|
||||
corresponding golang packages make it to unstable
|
||||
|
||||
- aptly: default format is yaml, but the old format is still supported
|
||||
for now
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sun, 29 Dec 2024 08:46:07 +0100
|
||||
|
||||
aptly (1.3.0+ds1-2.2) unstable; urgency=medium
|
||||
|
||||
This version tries to fix the database backwards compatibility,
|
||||
so you don't need to rebuild the database if you upgrade from
|
||||
aptly <= 1.3.0-6.
|
||||
|
||||
However some fields are missing, like created time of a snapshot.
|
||||
|
||||
-- Shengjing Zhu <zhsj@debian.org> Sat, 13 Apr 2019 23:26:39 +0800
|
||||
|
||||
aptly (1.3.0+ds1-2) unstable; urgency=medium
|
||||
|
||||
* The database created by aptly <= 1.3.0-6 is not compatible
|
||||
with greater versions. Users must create a new database.
|
||||
The `aptly db recover` will not fix the issue.
|
||||
|
||||
-- Alexandre Viau <aviau@debian.org> Fri, 26 Oct 2018 13:20:53 -0400
|
||||
Vendored
+2
-1
@@ -80,8 +80,9 @@ serve_in_api_mode: false
|
||||
# Enable metrics for Prometheus client
|
||||
enable_metrics_endpoint: false
|
||||
|
||||
# Not implemented in this version.
|
||||
# Enable API documentation on /docs
|
||||
enable_swagger_endpoint: false
|
||||
#enable_swagger_endpoint: false
|
||||
|
||||
# OBSOLETE: use via url param ?_async=true
|
||||
async_api: false
|
||||
|
||||
Vendored
+514
-43
@@ -1,51 +1,522 @@
|
||||
aptly (1.6.2) stable; urgency=medium
|
||||
aptly (1.6.2-3) unstable; urgency=medium
|
||||
|
||||
* doc: add swagger doc for /api/gpg/key (https://github.com/aptly-dev/aptly/pull/1456)
|
||||
* bash-completion: include global options in aptly command completions (https://github.com/aptly-dev/aptly/pull/1452)
|
||||
* Bump golang.org/x/net from 0.33.0 to 0.38.0 (https://github.com/aptly-dev/aptly/pull/1443)
|
||||
* Bump golang.org/x/crypto from 0.31.0 to 0.35.0 (https://github.com/aptly-dev/aptly/pull/1441)
|
||||
* Remove corrupt package references in `db recover` (https://github.com/aptly-dev/aptly/pull/1445)
|
||||
* Fix upload of unchanged packages in S3 (https://github.com/aptly-dev/aptly/pull/1440)
|
||||
* use go 1.24 (https://github.com/aptly-dev/aptly/pull/1439)
|
||||
[ Sébastien Delafond ]
|
||||
* tests: disable t04_mirror/create/CreateMirror18Test (Closes: #1135740)
|
||||
* tests: disable t12_api/gpg/GPGAPITestAddKey (Closes: #1135672)
|
||||
* d/control: bump-up Standards-Version
|
||||
|
||||
-- André Roth <neolynx@gmail.com> Mon, 09 Jun 2025 13:45:15 +0200
|
||||
-- Sebastien Delafond <seb@debian.org> Tue, 05 May 2026 18:14:44 +0200
|
||||
|
||||
aptly (1.6.1) stable; urgency=medium
|
||||
aptly (1.6.2-2) unstable; urgency=medium
|
||||
|
||||
* update golang-github-syndtr-goleveldb-dev dependency (v1.0.1-0.20220721030215-126854af5e6d) to fix segfault on arm64
|
||||
(bug in golang-github-golang-snappy-dev)
|
||||
* allow snapshotting empty mirrors again (regression)
|
||||
* debian compliance: add postrm (note: `apt purge aptly-api` will remove all data in ~aptly-api/)
|
||||
* update other dependencies (x/net 0.33.0, gin-gonic/gin 1.9.1)
|
||||
[ Sébastien Delafond ]
|
||||
* Remove Built-Using
|
||||
* Mark patches as "Forwarded: not-needed"
|
||||
|
||||
-- André Roth <neolynx@gmail.com> Sat, 15 Feb 2025 13:03:16 +0100
|
||||
-- Sebastien Delafond <seb@debian.org> Fri, 21 Nov 2025 15:46:51 +0100
|
||||
|
||||
aptly (1.6.0) stable; urgency=medium
|
||||
aptly (1.6.2-1) unstable; urgency=medium
|
||||
|
||||
* support reading filters from file or stdin
|
||||
* fix mirroring source packages
|
||||
* support yaml config per default
|
||||
* provide swagger API documentation
|
||||
* provide API for querying aptly storage usage
|
||||
* provide snapshot pull via API
|
||||
* support creating repos from snapshots
|
||||
* fix mirroring flat remote repos
|
||||
* support skeleton files for publishing
|
||||
* use new azure sdk
|
||||
* support updating the components of a published repo
|
||||
* support publishing multiple distributions (-multi-dist)
|
||||
* support etcd database
|
||||
* allow slash (/) in distribution names
|
||||
* support for storing the "local" pool on Azure
|
||||
* provide copy package API
|
||||
* fix publish concurrency and improve performance
|
||||
* improved mirroring
|
||||
* fix download throttling
|
||||
* fix resuming package downloads
|
||||
* fix ignoring signatures
|
||||
* fix packages dependency resolution (Virtual Packages, version numbers in Provides)
|
||||
* improved S3 support and performance
|
||||
* fix race condition with goleveldb
|
||||
* use go 1.22
|
||||
[ Sébastien Delafond ]
|
||||
* d/watch: v5
|
||||
* Bump up Standards-Version
|
||||
* Remove +ds suffix
|
||||
* Add Static-Built-Using
|
||||
* New upstream version 1.6.2
|
||||
|
||||
-- André Roth <neolynx@gmail.com> Tue, 24 Dec 2024 17:44:35 +0100
|
||||
-- Sebastien Delafond <seb@debian.org> Wed, 24 Sep 2025 06:19:54 +0200
|
||||
|
||||
aptly (1.6.1+ds1-3) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* tests: declare needs-internet for system-test
|
||||
* tests: disable unit test TestVerifyClearsigned & system test
|
||||
CreateMirror31Test (Closes: #1108828)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Tue, 08 Jul 2025 14:12:52 +0200
|
||||
|
||||
aptly (1.6.1+ds1-2) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Do not re-publish unchanged files to S3 every single time (Closes: #1104299)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Mon, 28 Apr 2025 15:38:43 +0200
|
||||
|
||||
aptly (1.6.1+ds1-1) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* New upstream version 1.6.1
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Mon, 24 Feb 2025 09:04:35 +0100
|
||||
|
||||
aptly (1.6.0+ds1-8) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* tests: disable riscv64-flaky EditRepo4Test
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Fri, 21 Feb 2025 06:54:18 +0100
|
||||
|
||||
aptly (1.6.0+ds1-7) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* tests: clean way to disable single tests, disable s390-flaky CreateMirror35Test
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 20 Feb 2025 07:26:41 +0100
|
||||
|
||||
aptly (1.6.0+ds1-6) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* tests: disable system-test's etcd tests as the corresponding fixture is also arch-specific
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Wed, 19 Feb 2025 14:02:19 +0100
|
||||
|
||||
aptly (1.6.0+ds1-5) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* tests: do not use upstream's etcd installer
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Wed, 19 Feb 2025 07:20:44 +0100
|
||||
|
||||
aptly (1.6.0+ds1-4) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* postrm: remove aptly-api user and home directory on purge
|
||||
* tests: use extensive coverage from make's test and system-test
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Tue, 18 Feb 2025 10:36:13 +0100
|
||||
|
||||
aptly (1.6.0+ds1-3) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* aptly.conf: fix s3 example
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Mon, 13 Jan 2025 14:51:29 +0100
|
||||
|
||||
aptly (1.6.0+ds1-2) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Document disabled swagger in default config file
|
||||
* Rediff patches: swagger references in man page
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Mon, 30 Dec 2024 11:11:07 +0100
|
||||
|
||||
aptly (1.6.0+ds1-1) unstable; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Official 1.6 release
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Fri, 27 Dec 2024 14:23:29 +0100
|
||||
|
||||
aptly (1.6.0+ds1~beta3-1) experimental; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Latest upstream version
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Wed, 11 Dec 2024 18:16:19 +0100
|
||||
|
||||
aptly (1.6.0+ds1~beta2-1) experimental; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Latest upstream version
|
||||
|
||||
[ André Roth ]
|
||||
* set systemd service file limit to 32768
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 21 Nov 2024 16:08:05 +0100
|
||||
|
||||
aptly (1.6.0+ds1~beta1-1) experimental; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Latest upstream version
|
||||
* Disable "use new azure-sdk"
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sun, 17 Nov 2024 18:52:06 +0100
|
||||
|
||||
aptly (1.6.0+ds1~alpha5-1) experimental; urgency=medium
|
||||
|
||||
* Sort out dependencies on gpg*
|
||||
* Reduce diff with upstream some more
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sun, 17 Nov 2024 15:59:23 +0100
|
||||
|
||||
aptly (1.6.0+ds1~alpha4-1) experimental; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Remove build-dep on git
|
||||
* Adjust systemd unit for aptly-api
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sun, 17 Nov 2024 14:51:49 +0100
|
||||
|
||||
aptly (1.6.0+ds1~alpha3-1) experimental; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Latest upstream version
|
||||
* Remove useless maintainer scripts
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sun, 17 Nov 2024 07:50:06 +0100
|
||||
|
||||
aptly (1.6.0+ds1~alpha2-1) experimental; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Latest upstream version
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sat, 16 Nov 2024 14:42:10 +0100
|
||||
|
||||
aptly (1.6.0+ds1~alpha1-2) experimental; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Add zsh completion
|
||||
* aptly-api: revert arch:all, so mv_conffile does the right thing
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Wed, 16 Oct 2024 09:10:05 +0200
|
||||
|
||||
aptly (1.6.0+ds1~alpha1-1) experimental; urgency=medium
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* d/patches: remove old patch, and disable swagger support
|
||||
* d/control: bump up Standards-Version
|
||||
* Adjust packaging for 1.6.0~alpha1
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Tue, 15 Oct 2024 14:40:57 +0200
|
||||
|
||||
aptly (1.5.0+ds1-2) unstable; urgency=medium
|
||||
|
||||
[ Shengjing Zhu ]
|
||||
* Replace golang-gopkg-cheggaaa-pb.v1-dev with
|
||||
golang-github-cheggaaa-pb-dev (Closes: #1050900)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Mon, 04 Sep 2023 08:49:36 +0200
|
||||
|
||||
aptly (1.5.0+ds1-1) unstable; urgency=medium
|
||||
|
||||
* Team upload.
|
||||
* New upstream release (Closes: #1022721), including fix for "Order of
|
||||
fields in Packages/Sources is unpredictable" (Closes: #907121).
|
||||
|
||||
-- Roland Mas <lolando@debian.org> Tue, 31 Jan 2023 14:47:04 +0100
|
||||
|
||||
aptly (1.4.0+ds1-7) unstable; urgency=medium
|
||||
|
||||
* Team upload.
|
||||
* Add support for zstd compression (Closes: #1010465)
|
||||
|
||||
-- Anton Gladky <gladk@debian.org> Tue, 17 May 2022 22:42:29 +0200
|
||||
|
||||
aptly (1.4.0+ds1-6) unstable; urgency=medium
|
||||
|
||||
* Conflict on gpgv1 (Closes: #990821)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 04 Nov 2021 10:24:53 +0100
|
||||
|
||||
aptly (1.4.0+ds1-5) unstable; urgency=medium
|
||||
|
||||
* Conflict on gnupg1 (Closes: #990821)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 14 Oct 2021 18:43:04 +0200
|
||||
|
||||
aptly (1.4.0+ds1-4) unstable; urgency=medium
|
||||
|
||||
* Install correct bash completion snippet (Closes: #984979)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 11 Mar 2021 15:20:57 +0100
|
||||
|
||||
aptly (1.4.0+ds1-3) unstable; urgency=medium
|
||||
|
||||
* Fix s3 etag issue (Closes: #983877)
|
||||
* Bump-up d/watch version
|
||||
* Bump-up Standards-Version
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Wed, 03 Mar 2021 10:50:51 +0100
|
||||
|
||||
aptly (1.4.0+ds1-2) unstable; urgency=medium
|
||||
|
||||
* Use pipeline from salsa-ci-team
|
||||
* Allow reprotest failure
|
||||
* Pass version from d/rules (Closes: #968585)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Fri, 21 Aug 2020 10:13:44 +0200
|
||||
|
||||
aptly (1.4.0+ds1-1) unstable; urgency=medium
|
||||
|
||||
* New upstream version 1.4.0+ds1
|
||||
* Rediff patches
|
||||
* Depend on gnupg 2
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sun, 22 Dec 2019 15:16:25 +0100
|
||||
|
||||
aptly (1.3.0+ds1-4) unstable; urgency=medium
|
||||
|
||||
[ Debian Janitor ]
|
||||
* Rename obsolete path debian/tests/control.autodep8 to debian/tests/control.
|
||||
* Use secure URI in Homepage field.
|
||||
* Bump debhelper from old 11 to 12.
|
||||
* Set debhelper-compat version in Build-Depends.
|
||||
|
||||
[ Sébastien Delafond ]
|
||||
* Bump up Standards-Version
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sun, 22 Dec 2019 14:10:19 +0100
|
||||
|
||||
aptly (1.3.0+ds1-3) unstable; urgency=medium
|
||||
|
||||
* Build-Depend on golang-golang-x-tools-dev instead of golang-go.tools (Closes: #945884)
|
||||
* Lintian fix
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sat, 21 Dec 2019 10:29:09 +0100
|
||||
|
||||
aptly (1.3.0+ds1-2.3) unstable; urgency=medium
|
||||
|
||||
* Non-maintainer upload.
|
||||
* Remove myself from uploaders.
|
||||
|
||||
-- Alexandre Viau <aviau@debian.org> Sun, 15 Sep 2019 19:27:47 -0400
|
||||
|
||||
aptly (1.3.0+ds1-2.2) unstable; urgency=medium
|
||||
|
||||
* Non-maintainer upload.
|
||||
* Add patch to fix DB backwards compatibility (Closes: #911924)
|
||||
* Fix struct field tag typo
|
||||
* Update debian/NEWS about DB compatibility
|
||||
|
||||
-- Shengjing Zhu <zhsj@debian.org> Tue, 16 Apr 2019 00:18:23 +0800
|
||||
|
||||
aptly (1.3.0+ds1-2.1) unstable; urgency=medium
|
||||
|
||||
[ Shengjing Zhu ]
|
||||
* Non-maintainer upload.
|
||||
* Add patch to fix UUID struct field not encoded in msgpack (Closes: #923866)
|
||||
|
||||
[ Tobias Frost ]
|
||||
* Prepare upload.
|
||||
|
||||
-- Tobias Frost <tobi@debian.org> Fri, 05 Apr 2019 17:19:14 +0200
|
||||
|
||||
aptly (1.3.0+ds1-2) unstable; urgency=medium
|
||||
|
||||
* Add NEWS to warn about database compatibility.
|
||||
|
||||
-- Alexandre Viau <aviau@debian.org> Fri, 26 Oct 2018 13:22:38 -0400
|
||||
|
||||
aptly (1.3.0+ds1-1) unstable; urgency=medium
|
||||
|
||||
[ Ondřej Nový ]
|
||||
* d/changelog: Remove trailing whitespaces
|
||||
|
||||
[ Alexandre Viau ]
|
||||
* d/watch: Append +ds suffix.
|
||||
* d/copyright: ignore vendor/*. (Closes: #902128)
|
||||
* d/copyright: remove vendor/* sections.
|
||||
* d/copyright: MIT -> Expat.
|
||||
* d/control: add vendor/* build dependencies.
|
||||
* Patch: Use Debian's uuid package.
|
||||
* Patch: Use Debian's lzma package.
|
||||
* d/rules: remove trailing whitespace.
|
||||
|
||||
-- Alexandre Viau <aviau@debian.org> Mon, 15 Oct 2018 11:54:03 -0400
|
||||
|
||||
aptly (1.3.0-6) unstable; urgency=medium
|
||||
|
||||
* Combine autodep8 and autopkgtest.
|
||||
|
||||
-- Alexandre Viau <aviau@debian.org> Fri, 29 Jun 2018 18:11:41 -0400
|
||||
|
||||
aptly (1.3.0-5) unstable; urgency=medium
|
||||
|
||||
* Fix syntax-error-in-dep5-copyright.
|
||||
* Fix unnecessary-testsuite-autopkgtest-field.
|
||||
* Fix broken autopkgtest.
|
||||
* Depend on gpgv1.
|
||||
|
||||
-- Alexandre Viau <aviau@debian.org> Tue, 26 Jun 2018 23:01:36 -0400
|
||||
|
||||
aptly (1.3.0-4) unstable; urgency=medium
|
||||
|
||||
* Document #902128 in debian/copyright
|
||||
* Point debian/watch to new git repo on GitHub
|
||||
* Add simple autopkgtest
|
||||
* Add debian/.gitlab-ci.yml
|
||||
* Depend on gnupg1 (Closes: #902419)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Tue, 26 Jun 2018 14:24:34 +0200
|
||||
|
||||
aptly (1.3.0-3) unstable; urgency=medium
|
||||
|
||||
* Create aptly-api package. (Closes: #902032)
|
||||
|
||||
-- Alexandre Viau <aviau@debian.org> Fri, 22 Jun 2018 13:51:50 -0400
|
||||
|
||||
aptly (1.3.0-2) unstable; urgency=medium
|
||||
|
||||
* Team upload, many thanks to Alexandre Viau for this work
|
||||
* Switch to dh-golang. (Closes: #902038)
|
||||
* Fix vcs-field-not-canonical.
|
||||
* Fix insecure-copyright-format-uri.
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Fri, 22 Jun 2018 13:53:11 +0200
|
||||
|
||||
aptly (1.3.0-1) unstable; urgency=medium
|
||||
|
||||
* Fix copyright
|
||||
* New upstream version 1.3.0
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 21 Jun 2018 15:14:57 +0200
|
||||
|
||||
aptly (1.2.0-4) unstable; urgency=medium
|
||||
|
||||
* Enable Built-Using in debian/control (thanks M. Staperberg)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Tue, 06 Mar 2018 10:10:42 +0100
|
||||
|
||||
aptly (1.2.0-3) unstable; urgency=medium
|
||||
|
||||
* Switch to DEP 14
|
||||
* Update Vcs-* to point to salsa.d.o
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Fri, 16 Feb 2018 17:02:25 +0100
|
||||
|
||||
aptly (1.2.0-2) unstable; urgency=medium
|
||||
|
||||
* Team upload.
|
||||
* Build-Depend on golang-any, not golang
|
||||
* Set XS-Go-Import-Path
|
||||
|
||||
-- Michael Stapelberg <stapelberg@debian.org> Sat, 10 Feb 2018 18:41:37 +0100
|
||||
|
||||
aptly (1.2.0-1) unstable; urgency=medium
|
||||
|
||||
* New upstream version 1.2.0
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Wed, 03 Jan 2018 13:43:30 +0100
|
||||
|
||||
aptly (1.1.1-2) unstable; urgency=medium
|
||||
|
||||
* Support both uncompressed control.tar, and xz-compressed
|
||||
control.tar.xz. Thanks to Boyuan Yang for the patch (Closes: 879718)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 02 Nov 2017 13:23:29 +0100
|
||||
|
||||
aptly (1.1.1-1) unstable; urgency=medium
|
||||
|
||||
* New upstream version 1.1.1
|
||||
* Use bash-completion snippet from upstream
|
||||
* Bump up Standards-Version
|
||||
* Update debian/copyright
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 02 Nov 2017 09:03:23 +0100
|
||||
|
||||
aptly (1.0.1-1) unstable; urgency=medium
|
||||
|
||||
* Imported Upstream version 1.0.1
|
||||
* Update debian/copyright
|
||||
* Adapt debian/rules
|
||||
* Update Vcs-Git
|
||||
* Bump-up Standards-Version
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Tue, 18 Jul 2017 11:53:29 +0200
|
||||
|
||||
aptly (0.9.7-1) unstable; urgency=medium
|
||||
|
||||
* Imported new upstream version 0.9.7
|
||||
* Add new licenses and copyrights info
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Tue, 24 May 2016 09:17:08 +0200
|
||||
|
||||
aptly (0.9.6-1) unstable; urgency=medium
|
||||
|
||||
* Import new upstream version 0.9.6
|
||||
* Add dependency on xz-utils
|
||||
* Licenses and copyrights
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Wed, 10 Feb 2016 18:28:51 +0100
|
||||
|
||||
aptly (0.9.5-2) unstable; urgency=medium
|
||||
|
||||
* Remove empty component in GOPATH (Closes: #793838)
|
||||
|
||||
[ Sebastien Delafond ]
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sun, 16 Aug 2015 18:42:22 +0200
|
||||
|
||||
aptly (0.9.5-1) unstable; urgency=medium
|
||||
|
||||
* Imported Upstream version 0.9.5
|
||||
* Up-to-date bash completion
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Fri, 15 May 2015 10:46:51 +0200
|
||||
|
||||
aptly (0.9.1-1) unstable; urgency=medium
|
||||
|
||||
* Imported Upstream version 0.9.1
|
||||
* Document licenses and copyrights for new dependencies
|
||||
* Suggest graphviz
|
||||
* Proper name for bash-completion file
|
||||
* Bump-up Standards-Version
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sat, 02 May 2015 12:57:16 +0200
|
||||
|
||||
aptly (0.8-3) unstable; urgency=medium
|
||||
|
||||
* Correct Vcs-Browser entry (Closes: #764622)
|
||||
* Correct dependency from "gpg" to "gnupg" (Closes: #764619)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 09 Oct 2014 18:41:38 +0200
|
||||
|
||||
aptly (0.8-2) unstable; urgency=medium
|
||||
|
||||
* Add missing dependencies on bzip2, gpg and gpgv
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 09 Oct 2014 11:15:21 +0200
|
||||
|
||||
aptly (0.8-1) unstable; urgency=medium
|
||||
|
||||
* Imported Upstream version 0.8
|
||||
* Document new copyrights and licenses
|
||||
* Add bash completion snippet
|
||||
* Reference full paths in debian/copyright, and remove unused
|
||||
references, so lintian does not complain
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Sat, 04 Oct 2014 17:46:24 +0200
|
||||
|
||||
aptly (0.7.1-1) unstable; urgency=medium
|
||||
|
||||
* Imported Upstream version 0.7.1
|
||||
* Add copyright information for new libraries
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Wed, 10 Sep 2014 10:03:27 +0200
|
||||
|
||||
aptly (0.5-5) unstable; urgency=medium
|
||||
|
||||
* Turn off verbose mode
|
||||
* Correct Vcs-* information
|
||||
* gocov is licensed MIT, not BSD-3
|
||||
* Add missing MIT license text
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Tue, 09 Sep 2014 09:20:40 +0200
|
||||
|
||||
aptly (0.5-4) unstable; urgency=medium
|
||||
|
||||
* Collect licenses by going over files one by one
|
||||
* Use packaged golang-go.tools
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Thu, 10 Jul 2014 00:49:09 +0200
|
||||
|
||||
aptly (0.5-3) unstable; urgency=low
|
||||
|
||||
* Licensing:
|
||||
- goleveldb is BSD-2, not BSD-3
|
||||
- _vendor/src/code.google.com/p/gographviz/scanner/scanner is BSD-3,
|
||||
copyright 2009 The Go Authors
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Wed, 28 May 2014 10:04:01 +0200
|
||||
|
||||
aptly (0.5-2) unstable; urgency=low
|
||||
|
||||
* Go interpreter not needed at runtime
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Fri, 02 May 2014 12:04:02 +0200
|
||||
|
||||
aptly (0.5-1) unstable; urgency=low
|
||||
|
||||
* Initial release (Closes: #746343)
|
||||
|
||||
-- Sebastien Delafond <seb@debian.org> Tue, 29 Apr 2014 15:47:31 +0200
|
||||
|
||||
Vendored
+7
-16
@@ -1,7 +1,7 @@
|
||||
Source: aptly
|
||||
Section: utils
|
||||
Priority: optional
|
||||
Maintainer: André Roth <neolynx@gmail.com>
|
||||
Maintainer: Sebastien Delafond <seb@debian.org>
|
||||
Build-Depends: bash-completion,
|
||||
debhelper-compat (= 13),
|
||||
dh-golang,
|
||||
@@ -77,20 +77,18 @@ Build-Depends: bash-completion,
|
||||
golang-go.uber-zap-dev,
|
||||
golang-etcd-server-dev (>= 3.5.15-7),
|
||||
golang-gopkg-yaml.v3-dev,
|
||||
git
|
||||
Standards-Version: 4.7.0
|
||||
Standards-Version: 4.7.4
|
||||
Homepage: https://www.aptly.info
|
||||
Vcs-Git: https://github.com/aptly-dev/aptly.git
|
||||
Vcs-Browser: https://github.com/aptly-dev/aptly
|
||||
Vcs-Git: https://salsa.debian.org/debian/aptly.git
|
||||
Vcs-Browser: https://salsa.debian.org/debian/aptly
|
||||
XS-Go-Import-Path: github.com/aptly-dev/aptly
|
||||
Testsuite: autopkgtest-pkg-go
|
||||
|
||||
Package: aptly
|
||||
Architecture: any
|
||||
Depends: ${misc:Depends}, ${shlibs:Depends}, bzip2, xz-utils, gpgv, gpg
|
||||
Suggests: graphviz
|
||||
Static-Built-Using: ${misc:Static-Built-Using}
|
||||
Conflicts: gnupg1, gpgv1
|
||||
Built-Using: ${misc:Static-Built-Using}, ${misc:Built-Using}
|
||||
Suggests: graphviz
|
||||
Description: Swiss army knife for Debian repository management - main package
|
||||
It offers several features making it easy to manage Debian package
|
||||
repositories:
|
||||
@@ -107,7 +105,7 @@ Description: Swiss army knife for Debian repository management - main package
|
||||
This is the main package, it contains the aptly command-line utility.
|
||||
|
||||
Package: aptly-api
|
||||
Architecture: any
|
||||
Architecture: all
|
||||
Depends: ${misc:Depends}, aptly
|
||||
Description: Swiss army knife for Debian repository management - API
|
||||
It offers several features making it easy to manage Debian package
|
||||
@@ -123,10 +121,3 @@ Description: Swiss army knife for Debian repository management - API
|
||||
- merge two or more snapshots into one
|
||||
.
|
||||
This package contains the aptly-api service.
|
||||
|
||||
Package: aptly-dbg
|
||||
Architecture: any
|
||||
Depends: ${misc:Depends}
|
||||
Built-Using: ${misc:Static-Built-Using}, ${misc:Built-Using}
|
||||
Description: Debian repository management tool (debug files)
|
||||
Debug symbols for aptly
|
||||
|
||||
Vendored
+3
@@ -0,0 +1,3 @@
|
||||
[DEFAULT]
|
||||
debian-branch = debian/master
|
||||
upstream-branch = upstream/latest
|
||||
Vendored
+1
@@ -0,0 +1 @@
|
||||
usr/bin/files
|
||||
+123
@@ -0,0 +1,123 @@
|
||||
From: =?utf-8?q?Andr=C3=A9_Roth?= <neolynx@gmail.com>
|
||||
Date: Tue, 15 Oct 2024 12:09:33 +0200
|
||||
Subject: Disable swagger
|
||||
|
||||
This can be enabled once the following modules make it into Debian:
|
||||
|
||||
- github.com/swaggo/files v1.0.1
|
||||
- github.com/swaggo/gin-swagger v1.6.0
|
||||
- github.com/swaggo/swag v1.16.3
|
||||
|
||||
Forwarded: not-needed
|
||||
---
|
||||
api/router.go | 22 +++++++++++-----------
|
||||
docs/index.go | 10 ----------
|
||||
docs/index.go.disabled | 10 ++++++++++
|
||||
man/aptly.1 | 3 ++-
|
||||
man/aptly.1.ronn.tmpl | 3 ++-
|
||||
5 files changed, 25 insertions(+), 23 deletions(-)
|
||||
delete mode 100644 docs/index.go
|
||||
create mode 100644 docs/index.go.disabled
|
||||
|
||||
diff --git a/api/router.go b/api/router.go
|
||||
index 3cd7d42..cf53cd2 100644
|
||||
--- a/api/router.go
|
||||
+++ b/api/router.go
|
||||
@@ -11,9 +11,9 @@
|
||||
"github.com/prometheus/client_golang/prometheus/promhttp"
|
||||
"github.com/rs/zerolog/log"
|
||||
|
||||
- "github.com/aptly-dev/aptly/docs"
|
||||
- swaggerFiles "github.com/swaggo/files"
|
||||
- ginSwagger "github.com/swaggo/gin-swagger"
|
||||
+ // _ "github.com/aptly-dev/aptly/docs" // import docs
|
||||
+ // swaggerFiles "github.com/swaggo/files"
|
||||
+ // ginSwagger "github.com/swaggo/gin-swagger"
|
||||
)
|
||||
|
||||
var context *ctx.AptlyContext
|
||||
@@ -63,14 +63,14 @@ func Router(c *ctx.AptlyContext) http.Handler {
|
||||
|
||||
router.Use(gin.Recovery(), gin.ErrorLogger())
|
||||
|
||||
- if c.Config().EnableSwaggerEndpoint {
|
||||
- router.GET("docs.html", func(c *gin.Context) {
|
||||
- c.Data(http.StatusOK, "text/html; charset=utf-8", docs.DocsHTML)
|
||||
- })
|
||||
- router.Use(redirectSwagger)
|
||||
- url := ginSwagger.URL("/docs/doc.json")
|
||||
- router.GET("/docs/*any", ginSwagger.WrapHandler(swaggerFiles.Handler, url))
|
||||
- }
|
||||
+ // if c.Config().EnableSwaggerEndpoint {
|
||||
+ // router.GET("docs.html", func(c *gin.Context) {
|
||||
+ // c.Data(http.StatusOK, "text/html; charset=utf-8", docs.DocsHTML)
|
||||
+ // })
|
||||
+ // router.Use(redirectSwagger)
|
||||
+ // url := ginSwagger.URL("/docs/doc.json")
|
||||
+ // router.GET("/docs/*any", ginSwagger.WrapHandler(swaggerFiles.Handler, url))
|
||||
+ // }
|
||||
|
||||
if c.Config().EnableMetricsEndpoint {
|
||||
MetricsCollectorRegistrar.Register(router)
|
||||
diff --git a/docs/index.go b/docs/index.go
|
||||
deleted file mode 100644
|
||||
index ca4c914..0000000
|
||||
--- a/docs/index.go
|
||||
+++ /dev/null
|
||||
@@ -1,10 +0,0 @@
|
||||
-package docs
|
||||
-
|
||||
-import (
|
||||
- _ "embed" // embed html below
|
||||
-
|
||||
- _ "github.com/swaggo/swag" // make sure swag is in go.mod
|
||||
-)
|
||||
-
|
||||
-//go:embed docs.html
|
||||
-var DocsHTML []byte
|
||||
diff --git a/docs/index.go.disabled b/docs/index.go.disabled
|
||||
new file mode 100644
|
||||
index 0000000..ca4c914
|
||||
--- /dev/null
|
||||
+++ b/docs/index.go.disabled
|
||||
@@ -0,0 +1,10 @@
|
||||
+package docs
|
||||
+
|
||||
+import (
|
||||
+ _ "embed" // embed html below
|
||||
+
|
||||
+ _ "github.com/swaggo/swag" // make sure swag is in go.mod
|
||||
+)
|
||||
+
|
||||
+//go:embed docs.html
|
||||
+var DocsHTML []byte
|
||||
diff --git a/man/aptly.1 b/man/aptly.1
|
||||
index bd6ad22..11ed990 100644
|
||||
--- a/man/aptly.1
|
||||
+++ b/man/aptly.1
|
||||
@@ -111,8 +111,9 @@ The legacy json configuration is still supported (and also supports comments):
|
||||
// Enable metrics for Prometheus client
|
||||
"enableMetricsEndpoint": false,
|
||||
|
||||
+ // Not implemented in this version\.
|
||||
// Enable API documentation on /docs
|
||||
- "enableSwaggerEndpoint": false,
|
||||
+ //"enableSwaggerEndpoint": false,
|
||||
|
||||
// OBSOLETE: use via url param ?_async=true
|
||||
"AsyncAPI": false,
|
||||
diff --git a/man/aptly.1.ronn.tmpl b/man/aptly.1.ronn.tmpl
|
||||
index 203cc7f..ed2c87c 100644
|
||||
--- a/man/aptly.1.ronn.tmpl
|
||||
+++ b/man/aptly.1.ronn.tmpl
|
||||
@@ -100,8 +100,9 @@ The legacy json configuration is still supported (and also supports comments):
|
||||
// Enable metrics for Prometheus client
|
||||
"enableMetricsEndpoint": false,
|
||||
|
||||
+ // Not implemented in this version.
|
||||
// Enable API documentation on /docs
|
||||
- "enableSwaggerEndpoint": false,
|
||||
+ //"enableSwaggerEndpoint": false,
|
||||
|
||||
// OBSOLETE: use via url param ?_async=true
|
||||
"AsyncAPI": false,
|
||||
+880
@@ -0,0 +1,880 @@
|
||||
From: =?utf-8?q?Andr=C3=A9_Roth?= <neolynx@gmail.com>
|
||||
Date: Sun, 17 Nov 2024 17:58:04 +0100
|
||||
Subject: Disable new azure-sdk
|
||||
|
||||
This reverts commit e2cbd637b82a153a6756f2af0519e8fe769ee9ab.
|
||||
|
||||
We can enable this once the golang-github-azure-azure-sdk-for-go-dev
|
||||
packages are upgraded in Debian:
|
||||
|
||||
- github.com/Azure/azure-sdk-for-go/sdk/internal v1.10.0
|
||||
- github.com/Azure/azure-sdk-for-go/sdk/azcore v1.14.0
|
||||
- github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.4.1
|
||||
|
||||
Forwarded: not-needed
|
||||
---
|
||||
azure/azure.go | 89 +++++++++++++++-----------------
|
||||
azure/package_pool.go | 45 ++++++++--------
|
||||
azure/package_pool_test.go | 8 ++-
|
||||
azure/public.go | 125 +++++++++++++++++++++------------------------
|
||||
azure/public_test.go | 49 +++++++++---------
|
||||
context/context.go | 1 +
|
||||
deb/list.go | 1 +
|
||||
go.mod | 8 +--
|
||||
go.sum | 52 +++++++++++--------
|
||||
9 files changed, 185 insertions(+), 193 deletions(-)
|
||||
|
||||
diff --git a/azure/azure.go b/azure/azure.go
|
||||
index 3f12678..b313f90 100644
|
||||
--- a/azure/azure.go
|
||||
+++ b/azure/azure.go
|
||||
@@ -5,35 +5,28 @@
|
||||
import (
|
||||
"context"
|
||||
"encoding/hex"
|
||||
- "errors"
|
||||
"fmt"
|
||||
"io"
|
||||
- "os"
|
||||
+ "net/url"
|
||||
"path/filepath"
|
||||
"time"
|
||||
|
||||
- "github.com/Azure/azure-sdk-for-go/sdk/azcore"
|
||||
- "github.com/Azure/azure-sdk-for-go/sdk/storage/azblob"
|
||||
- "github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/blob"
|
||||
+ "github.com/Azure/azure-storage-blob-go/azblob"
|
||||
"github.com/aptly-dev/aptly/aptly"
|
||||
)
|
||||
|
||||
func isBlobNotFound(err error) bool {
|
||||
- var respErr *azcore.ResponseError
|
||||
- if errors.As(err, &respErr) {
|
||||
- return respErr.StatusCode == 404 // BlobNotFound
|
||||
- }
|
||||
- return false
|
||||
+ storageError, ok := err.(azblob.StorageError)
|
||||
+ return ok && storageError.ServiceCode() == azblob.ServiceCodeBlobNotFound
|
||||
}
|
||||
|
||||
type azContext struct {
|
||||
- client *azblob.Client
|
||||
- container string
|
||||
+ container azblob.ContainerURL
|
||||
prefix string
|
||||
}
|
||||
|
||||
func newAzContext(accountName, accountKey, container, prefix, endpoint string) (*azContext, error) {
|
||||
- cred, err := azblob.NewSharedKeyCredential(accountName, accountKey)
|
||||
+ credential, err := azblob.NewSharedKeyCredential(accountName, accountKey)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -42,14 +35,15 @@ func newAzContext(accountName, accountKey, container, prefix, endpoint string) (
|
||||
endpoint = fmt.Sprintf("https://%s.blob.core.windows.net", accountName)
|
||||
}
|
||||
|
||||
- serviceClient, err := azblob.NewClientWithSharedKeyCredential(endpoint, cred, nil)
|
||||
+ url, err := url.Parse(fmt.Sprintf("%s/%s", endpoint, container))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
+ containerURL := azblob.NewContainerURL(*url, azblob.NewPipeline(credential, azblob.PipelineOptions{}))
|
||||
+
|
||||
result := &azContext{
|
||||
- client: serviceClient,
|
||||
- container: container,
|
||||
+ container: containerURL,
|
||||
prefix: prefix,
|
||||
}
|
||||
|
||||
@@ -60,6 +54,10 @@ func (az *azContext) blobPath(path string) string {
|
||||
return filepath.Join(az.prefix, path)
|
||||
}
|
||||
|
||||
+func (az *azContext) blobURL(path string) azblob.BlobURL {
|
||||
+ return az.container.NewBlobURL(az.blobPath(path))
|
||||
+}
|
||||
+
|
||||
func (az *azContext) internalFilelist(prefix string, progress aptly.Progress) (paths []string, md5s []string, err error) {
|
||||
const delimiter = "/"
|
||||
paths = make([]string, 0, 1024)
|
||||
@@ -69,33 +67,27 @@ func (az *azContext) internalFilelist(prefix string, progress aptly.Progress) (p
|
||||
prefix += delimiter
|
||||
}
|
||||
|
||||
- ctx := context.Background()
|
||||
- maxResults := int32(1)
|
||||
- pager := az.client.NewListBlobsFlatPager(az.container, &azblob.ListBlobsFlatOptions{
|
||||
- Prefix: &prefix,
|
||||
- MaxResults: &maxResults,
|
||||
- Include: azblob.ListBlobsInclude{Metadata: true},
|
||||
- })
|
||||
-
|
||||
- // Iterate over each page
|
||||
- for pager.More() {
|
||||
- page, err := pager.NextPage(ctx)
|
||||
+ for marker := (azblob.Marker{}); marker.NotDone(); {
|
||||
+ listBlob, err := az.container.ListBlobsFlatSegment(
|
||||
+ context.Background(), marker, azblob.ListBlobsSegmentOptions{
|
||||
+ Prefix: prefix,
|
||||
+ MaxResults: 1,
|
||||
+ Details: azblob.BlobListingDetails{Metadata: true}})
|
||||
if err != nil {
|
||||
return nil, nil, fmt.Errorf("error listing under prefix %s in %s: %s", prefix, az, err)
|
||||
}
|
||||
|
||||
- for _, blob := range page.Segment.BlobItems {
|
||||
- if prefix == "" {
|
||||
- paths = append(paths, *blob.Name)
|
||||
- } else {
|
||||
- name := *blob.Name
|
||||
- paths = append(paths, name[len(prefix):])
|
||||
- }
|
||||
- b := *blob
|
||||
- md5 := b.Properties.ContentMD5
|
||||
- md5s = append(md5s, fmt.Sprintf("%x", md5))
|
||||
+ marker = listBlob.NextMarker
|
||||
|
||||
+ for _, blob := range listBlob.Segment.BlobItems {
|
||||
+ if prefix == "" {
|
||||
+ paths = append(paths, blob.Name)
|
||||
+ } else {
|
||||
+ paths = append(paths, blob.Name[len(prefix):])
|
||||
+ }
|
||||
+ md5s = append(md5s, fmt.Sprintf("%x", blob.Properties.ContentMD5))
|
||||
}
|
||||
+
|
||||
if progress != nil {
|
||||
time.Sleep(time.Duration(500) * time.Millisecond)
|
||||
progress.AddBar(1)
|
||||
@@ -105,27 +97,28 @@ func (az *azContext) internalFilelist(prefix string, progress aptly.Progress) (p
|
||||
return paths, md5s, nil
|
||||
}
|
||||
|
||||
-func (az *azContext) putFile(blobName string, source io.Reader, sourceMD5 string) error {
|
||||
- uploadOptions := &azblob.UploadFileOptions{
|
||||
- BlockSize: 4 * 1024 * 1024,
|
||||
- Concurrency: 8,
|
||||
+func (az *azContext) putFile(blob azblob.BlobURL, source io.Reader, sourceMD5 string) error {
|
||||
+ uploadOptions := azblob.UploadStreamToBlockBlobOptions{
|
||||
+ BufferSize: 4 * 1024 * 1024,
|
||||
+ MaxBuffers: 8,
|
||||
}
|
||||
|
||||
- path := az.blobPath(blobName)
|
||||
if len(sourceMD5) > 0 {
|
||||
decodedMD5, err := hex.DecodeString(sourceMD5)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
- uploadOptions.HTTPHeaders = &blob.HTTPHeaders{
|
||||
- BlobContentMD5: decodedMD5,
|
||||
+ uploadOptions.BlobHTTPHeaders = azblob.BlobHTTPHeaders{
|
||||
+ ContentMD5: decodedMD5,
|
||||
}
|
||||
}
|
||||
|
||||
- var err error
|
||||
- if file, ok := source.(*os.File); ok {
|
||||
- _, err = az.client.UploadFile(context.TODO(), az.container, path, file, uploadOptions)
|
||||
- }
|
||||
+ _, err := azblob.UploadStreamToBlockBlob(
|
||||
+ context.Background(),
|
||||
+ source,
|
||||
+ blob.ToBlockBlobURL(),
|
||||
+ uploadOptions,
|
||||
+ )
|
||||
|
||||
return err
|
||||
}
|
||||
diff --git a/azure/package_pool.go b/azure/package_pool.go
|
||||
index 97be8e6..6d7af1a 100644
|
||||
--- a/azure/package_pool.go
|
||||
+++ b/azure/package_pool.go
|
||||
@@ -5,6 +5,7 @@
|
||||
"os"
|
||||
"path/filepath"
|
||||
|
||||
+ "github.com/Azure/azure-storage-blob-go/azblob"
|
||||
"github.com/aptly-dev/aptly/aptly"
|
||||
"github.com/aptly-dev/aptly/utils"
|
||||
"github.com/pkg/errors"
|
||||
@@ -40,7 +41,10 @@ func (pool *PackagePool) buildPoolPath(filename string, checksums *utils.Checksu
|
||||
return filepath.Join(hash[0:2], hash[2:4], hash[4:32]+"_"+filename)
|
||||
}
|
||||
|
||||
-func (pool *PackagePool) ensureChecksums(poolPath string, checksumStorage aptly.ChecksumStorage) (*utils.ChecksumInfo, error) {
|
||||
+func (pool *PackagePool) ensureChecksums(
|
||||
+ poolPath string,
|
||||
+ checksumStorage aptly.ChecksumStorage,
|
||||
+) (*utils.ChecksumInfo, error) {
|
||||
targetChecksums, err := checksumStorage.Get(poolPath)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
@@ -48,7 +52,8 @@ func (pool *PackagePool) ensureChecksums(poolPath string, checksumStorage aptly.
|
||||
|
||||
if targetChecksums == nil {
|
||||
// we don't have checksums stored yet for this file
|
||||
- download, err := pool.az.client.DownloadStream(context.Background(), pool.az.container, poolPath, nil)
|
||||
+ blob := pool.az.blobURL(poolPath)
|
||||
+ download, err := blob.Download(context.Background(), 0, 0, azblob.BlobAccessConditions{}, false, azblob.ClientProvidedKeyOptions{})
|
||||
if err != nil {
|
||||
if isBlobNotFound(err) {
|
||||
return nil, nil
|
||||
@@ -58,7 +63,7 @@ func (pool *PackagePool) ensureChecksums(poolPath string, checksumStorage aptly.
|
||||
}
|
||||
|
||||
targetChecksums = &utils.ChecksumInfo{}
|
||||
- *targetChecksums, err = utils.ChecksumsForReader(download.Body)
|
||||
+ *targetChecksums, err = utils.ChecksumsForReader(download.Body(azblob.RetryReaderOptions{}))
|
||||
if err != nil {
|
||||
return nil, errors.Wrapf(err, "error checksumming blob at %s", poolPath)
|
||||
}
|
||||
@@ -87,49 +92,46 @@ func (pool *PackagePool) LegacyPath(_ string, _ *utils.ChecksumInfo) (string, er
|
||||
}
|
||||
|
||||
func (pool *PackagePool) Size(path string) (int64, error) {
|
||||
- serviceClient := pool.az.client.ServiceClient()
|
||||
- containerClient := serviceClient.NewContainerClient(pool.az.container)
|
||||
- blobClient := containerClient.NewBlobClient(path)
|
||||
-
|
||||
- props, err := blobClient.GetProperties(context.TODO(), nil)
|
||||
+ blob := pool.az.blobURL(path)
|
||||
+ props, err := blob.GetProperties(context.Background(), azblob.BlobAccessConditions{}, azblob.ClientProvidedKeyOptions{})
|
||||
if err != nil {
|
||||
return 0, errors.Wrapf(err, "error examining %s from %s", path, pool)
|
||||
}
|
||||
|
||||
- return *props.ContentLength, nil
|
||||
+ return props.ContentLength(), nil
|
||||
}
|
||||
|
||||
func (pool *PackagePool) Open(path string) (aptly.ReadSeekerCloser, error) {
|
||||
+ blob := pool.az.blobURL(path)
|
||||
+
|
||||
temp, err := os.CreateTemp("", "blob-download")
|
||||
if err != nil {
|
||||
- return nil, errors.Wrapf(err, "error creating tempfile for %s", path)
|
||||
+ return nil, errors.Wrap(err, "error creating temporary file for blob download")
|
||||
}
|
||||
+
|
||||
defer func () { _ = os.Remove(temp.Name()) }()
|
||||
|
||||
- _, err = pool.az.client.DownloadFile(context.TODO(), pool.az.container, path, temp, nil)
|
||||
+ err = azblob.DownloadBlobToFile(context.Background(), blob, 0, 0, temp, azblob.DownloadFromBlobOptions{})
|
||||
if err != nil {
|
||||
- return nil, errors.Wrapf(err, "error downloading blob %s", path)
|
||||
+ return nil, errors.Wrapf(err, "error downloading blob at %s", path)
|
||||
}
|
||||
|
||||
return temp, nil
|
||||
}
|
||||
|
||||
func (pool *PackagePool) Remove(path string) (int64, error) {
|
||||
- serviceClient := pool.az.client.ServiceClient()
|
||||
- containerClient := serviceClient.NewContainerClient(pool.az.container)
|
||||
- blobClient := containerClient.NewBlobClient(path)
|
||||
-
|
||||
- props, err := blobClient.GetProperties(context.TODO(), nil)
|
||||
+ blob := pool.az.blobURL(path)
|
||||
+ props, err := blob.GetProperties(context.Background(), azblob.BlobAccessConditions{}, azblob.ClientProvidedKeyOptions{})
|
||||
if err != nil {
|
||||
- return 0, errors.Wrapf(err, "error examining %s from %s", path, pool)
|
||||
+ return 0, errors.Wrapf(err, "error getting props of %s from %s", path, pool)
|
||||
}
|
||||
|
||||
- _, err = pool.az.client.DeleteBlob(context.Background(), pool.az.container, path, nil)
|
||||
+ _, err = blob.Delete(context.Background(), azblob.DeleteSnapshotsOptionNone, azblob.BlobAccessConditions{})
|
||||
if err != nil {
|
||||
return 0, errors.Wrapf(err, "error deleting %s from %s", path, pool)
|
||||
}
|
||||
|
||||
- return *props.ContentLength, nil
|
||||
+ return props.ContentLength(), nil
|
||||
}
|
||||
|
||||
func (pool *PackagePool) Import(srcPath, basename string, checksums *utils.ChecksumInfo, _ bool, checksumStorage aptly.ChecksumStorage) (string, error) {
|
||||
@@ -143,6 +145,7 @@ func (pool *PackagePool) Import(srcPath, basename string, checksums *utils.Check
|
||||
}
|
||||
|
||||
path := pool.buildPoolPath(basename, checksums)
|
||||
+ blob := pool.az.blobURL(path)
|
||||
targetChecksums, err := pool.ensureChecksums(path, checksumStorage)
|
||||
if err != nil {
|
||||
return "", err
|
||||
@@ -158,7 +161,7 @@ func (pool *PackagePool) Import(srcPath, basename string, checksums *utils.Check
|
||||
}
|
||||
defer func() { _ = source.Close() }()
|
||||
|
||||
- err = pool.az.putFile(path, source, checksums.MD5)
|
||||
+ err = pool.az.putFile(blob, source, checksums.MD5)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
diff --git a/azure/package_pool_test.go b/azure/package_pool_test.go
|
||||
index ef562cb..6b1341d 100644
|
||||
--- a/azure/package_pool_test.go
|
||||
+++ b/azure/package_pool_test.go
|
||||
@@ -7,7 +7,7 @@
|
||||
"path/filepath"
|
||||
"runtime"
|
||||
|
||||
- "github.com/Azure/azure-sdk-for-go/sdk/storage/azblob"
|
||||
+ "github.com/Azure/azure-storage-blob-go/azblob"
|
||||
"github.com/aptly-dev/aptly/aptly"
|
||||
"github.com/aptly-dev/aptly/files"
|
||||
"github.com/aptly-dev/aptly/utils"
|
||||
@@ -50,10 +50,8 @@ func (s *PackagePoolSuite) SetUpTest(c *C) {
|
||||
|
||||
s.pool, err = NewPackagePool(s.accountName, s.accountKey, container, "", s.endpoint)
|
||||
c.Assert(err, IsNil)
|
||||
- publicAccessType := azblob.PublicAccessTypeContainer
|
||||
- _, err = s.pool.az.client.CreateContainer(context.TODO(), s.pool.az.container, &azblob.CreateContainerOptions{
|
||||
- Access: &publicAccessType,
|
||||
- })
|
||||
+ cnt := s.pool.az.container
|
||||
+ _, err = cnt.Create(context.Background(), azblob.Metadata{}, azblob.PublicAccessContainer)
|
||||
c.Assert(err, IsNil)
|
||||
|
||||
s.prefixedPool, err = NewPackagePool(s.accountName, s.accountKey, container, prefix, s.endpoint)
|
||||
diff --git a/azure/public.go b/azure/public.go
|
||||
index 6775e14..efd2e7a 100644
|
||||
--- a/azure/public.go
|
||||
+++ b/azure/public.go
|
||||
@@ -3,22 +3,21 @@
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
+ "net/http"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"time"
|
||||
|
||||
- "github.com/Azure/azure-sdk-for-go/sdk/azcore/to"
|
||||
- "github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/blob"
|
||||
- "github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/lease"
|
||||
+ "github.com/Azure/azure-storage-blob-go/azblob"
|
||||
"github.com/aptly-dev/aptly/aptly"
|
||||
"github.com/aptly-dev/aptly/utils"
|
||||
- "github.com/google/uuid"
|
||||
"github.com/pkg/errors"
|
||||
)
|
||||
|
||||
// PublishedStorage abstract file system with published files (actually hosted on Azure)
|
||||
type PublishedStorage struct {
|
||||
// FIXME: unused ???? prefix string
|
||||
+ container azblob.ContainerURL
|
||||
az *azContext
|
||||
pathCache map[string]map[string]string
|
||||
}
|
||||
@@ -67,7 +66,7 @@ func (storage *PublishedStorage) PutFile(path string, sourceFilename string) err
|
||||
}
|
||||
defer func() { _ = source.Close() }()
|
||||
|
||||
- err = storage.az.putFile(path, source, sourceMD5)
|
||||
+ err = storage.az.putFile(storage.az.blobURL(path), source, sourceMD5)
|
||||
if err != nil {
|
||||
err = errors.Wrap(err, fmt.Sprintf("error uploading %s to %s", sourceFilename, storage))
|
||||
}
|
||||
@@ -77,15 +76,14 @@ func (storage *PublishedStorage) PutFile(path string, sourceFilename string) err
|
||||
|
||||
// RemoveDirs removes directory structure under public path
|
||||
func (storage *PublishedStorage) RemoveDirs(path string, _ aptly.Progress) error {
|
||||
- path = storage.az.blobPath(path)
|
||||
filelist, err := storage.Filelist(path)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, filename := range filelist {
|
||||
- blob := filepath.Join(path, filename)
|
||||
- _, err := storage.az.client.DeleteBlob(context.Background(), storage.az.container, blob, nil)
|
||||
+ blob := storage.az.blobURL(filepath.Join(path, filename))
|
||||
+ _, err := blob.Delete(context.Background(), azblob.DeleteSnapshotsOptionNone, azblob.BlobAccessConditions{})
|
||||
if err != nil {
|
||||
return fmt.Errorf("error deleting path %s from %s: %s", filename, storage, err)
|
||||
}
|
||||
@@ -96,8 +94,8 @@ func (storage *PublishedStorage) RemoveDirs(path string, _ aptly.Progress) error
|
||||
|
||||
// Remove removes single file under public path
|
||||
func (storage *PublishedStorage) Remove(path string) error {
|
||||
- path = storage.az.blobPath(path)
|
||||
- _, err := storage.az.client.DeleteBlob(context.Background(), storage.az.container, path, nil)
|
||||
+ blob := storage.az.blobURL(path)
|
||||
+ _, err := blob.Delete(context.Background(), azblob.DeleteSnapshotsOptionNone, azblob.BlobAccessConditions{})
|
||||
if err != nil {
|
||||
err = errors.Wrap(err, fmt.Sprintf("error deleting %s from %s: %s", path, storage, err))
|
||||
}
|
||||
@@ -116,8 +114,9 @@ func (storage *PublishedStorage) LinkFromPool(publishedPrefix, publishedRelPath,
|
||||
sourcePath string, sourceChecksums utils.ChecksumInfo, force bool) error {
|
||||
|
||||
relFilePath := filepath.Join(publishedRelPath, fileName)
|
||||
- prefixRelFilePath := filepath.Join(publishedPrefix, relFilePath)
|
||||
- poolPath := storage.az.blobPath(prefixRelFilePath)
|
||||
+ // prefixRelFilePath := filepath.Join(publishedPrefix, relFilePath)
|
||||
+ // FIXME: check how to integrate publishedPrefix:
|
||||
+ poolPath := storage.az.blobPath(fileName)
|
||||
|
||||
if storage.pathCache == nil {
|
||||
storage.pathCache = make(map[string]map[string]string)
|
||||
@@ -160,7 +159,7 @@ func (storage *PublishedStorage) LinkFromPool(publishedPrefix, publishedRelPath,
|
||||
}
|
||||
defer func() { _ = source.Close() }()
|
||||
|
||||
- err = storage.az.putFile(relFilePath, source, sourceMD5)
|
||||
+ err = storage.az.putFile(storage.az.blobURL(relFilePath), source, sourceMD5)
|
||||
if err == nil {
|
||||
pathCache[relFilePath] = sourceMD5
|
||||
} else {
|
||||
@@ -177,60 +176,59 @@ func (storage *PublishedStorage) Filelist(prefix string) ([]string, error) {
|
||||
}
|
||||
|
||||
// Internal copy or move implementation
|
||||
-func (storage *PublishedStorage) internalCopyOrMoveBlob(src, dst string, metadata map[string]*string, move bool) error {
|
||||
+func (storage *PublishedStorage) internalCopyOrMoveBlob(src, dst string, metadata azblob.Metadata, move bool) error {
|
||||
const leaseDuration = 30
|
||||
- leaseID := uuid.NewString()
|
||||
|
||||
- serviceClient := storage.az.client.ServiceClient()
|
||||
- containerClient := serviceClient.NewContainerClient(storage.az.container)
|
||||
- srcBlobClient := containerClient.NewBlobClient(src)
|
||||
- blobLeaseClient, err := lease.NewBlobClient(srcBlobClient, &lease.BlobClientOptions{LeaseID: to.Ptr(leaseID)})
|
||||
- if err != nil {
|
||||
- return fmt.Errorf("error acquiring lease on source blob %s", src)
|
||||
- }
|
||||
-
|
||||
- _, err = blobLeaseClient.AcquireLease(context.Background(), leaseDuration, nil)
|
||||
- if err != nil {
|
||||
- return fmt.Errorf("error acquiring lease on source blob %s", src)
|
||||
+ dstBlobURL := storage.az.blobURL(dst)
|
||||
+ srcBlobURL := storage.az.blobURL(src)
|
||||
+ leaseResp, err := srcBlobURL.AcquireLease(context.Background(), "", leaseDuration, azblob.ModifiedAccessConditions{})
|
||||
+ if err != nil || leaseResp.StatusCode() != http.StatusCreated {
|
||||
+ return fmt.Errorf("error acquiring lease on source blob %s", srcBlobURL)
|
||||
}
|
||||
defer func() {
|
||||
- _, _ = blobLeaseClient.BreakLease(context.Background(), &lease.BlobBreakOptions{BreakPeriod: to.Ptr(int32(60))})
|
||||
+ _, _ = srcBlobURL.BreakLease(context.Background(), azblob.LeaseBreakNaturally, azblob.ModifiedAccessConditions{})
|
||||
}()
|
||||
+ srcBlobLeaseID := leaseResp.LeaseID()
|
||||
|
||||
- dstBlobClient := containerClient.NewBlobClient(dst)
|
||||
- copyResp, err := dstBlobClient.StartCopyFromURL(context.Background(), srcBlobClient.URL(), &blob.StartCopyFromURLOptions{
|
||||
- Metadata: metadata,
|
||||
- })
|
||||
-
|
||||
+ copyResp, err := dstBlobURL.StartCopyFromURL(
|
||||
+ context.Background(),
|
||||
+ srcBlobURL.URL(),
|
||||
+ metadata,
|
||||
+ azblob.ModifiedAccessConditions{},
|
||||
+ azblob.BlobAccessConditions{},
|
||||
+ azblob.DefaultAccessTier,
|
||||
+ nil)
|
||||
if err != nil {
|
||||
return fmt.Errorf("error copying %s -> %s in %s: %s", src, dst, storage, err)
|
||||
}
|
||||
|
||||
- copyStatus := *copyResp.CopyStatus
|
||||
+ copyStatus := copyResp.CopyStatus()
|
||||
for {
|
||||
- if copyStatus == blob.CopyStatusTypeSuccess {
|
||||
+ if copyStatus == azblob.CopyStatusSuccess {
|
||||
if move {
|
||||
- _, err := storage.az.client.DeleteBlob(context.Background(), storage.az.container, src, &blob.DeleteOptions{
|
||||
- AccessConditions: &blob.AccessConditions{
|
||||
- LeaseAccessConditions: &blob.LeaseAccessConditions{
|
||||
- LeaseID: &leaseID,
|
||||
- },
|
||||
- },
|
||||
- })
|
||||
+ _, err = srcBlobURL.Delete(
|
||||
+ context.Background(),
|
||||
+ azblob.DeleteSnapshotsOptionNone,
|
||||
+ azblob.BlobAccessConditions{
|
||||
+ LeaseAccessConditions: azblob.LeaseAccessConditions{LeaseID: srcBlobLeaseID},
|
||||
+ })
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
- } else if copyStatus == blob.CopyStatusTypePending {
|
||||
+ } else if copyStatus == azblob.CopyStatusPending {
|
||||
time.Sleep(1 * time.Second)
|
||||
- getMetadata, err := dstBlobClient.GetProperties(context.TODO(), nil)
|
||||
+ blobPropsResp, err := dstBlobURL.GetProperties(
|
||||
+ context.Background(),
|
||||
+ azblob.BlobAccessConditions{LeaseAccessConditions: azblob.LeaseAccessConditions{LeaseID: srcBlobLeaseID}},
|
||||
+ azblob.ClientProvidedKeyOptions{})
|
||||
if err != nil {
|
||||
- return fmt.Errorf("error getting copy progress %s", dst)
|
||||
+ return fmt.Errorf("error getting destination blob properties %s", dstBlobURL)
|
||||
}
|
||||
- copyStatus = *getMetadata.CopyStatus
|
||||
+ copyStatus = blobPropsResp.CopyStatus()
|
||||
|
||||
- _, err = blobLeaseClient.RenewLease(context.Background(), nil)
|
||||
+ _, err = srcBlobURL.RenewLease(context.Background(), srcBlobLeaseID, azblob.ModifiedAccessConditions{})
|
||||
if err != nil {
|
||||
- return fmt.Errorf("error renewing source blob lease %s", src)
|
||||
+ return fmt.Errorf("error renewing source blob lease %s", srcBlobURL)
|
||||
}
|
||||
} else {
|
||||
return fmt.Errorf("error copying %s -> %s in %s: %s", dst, src, storage, copyStatus)
|
||||
@@ -245,9 +243,7 @@ func (storage *PublishedStorage) RenameFile(oldName, newName string) error {
|
||||
|
||||
// SymLink creates a copy of src file and adds link information as meta data
|
||||
func (storage *PublishedStorage) SymLink(src string, dst string) error {
|
||||
- metadata := make(map[string]*string)
|
||||
- metadata["SymLink"] = &src
|
||||
- return storage.internalCopyOrMoveBlob(src, dst, metadata, false /* do not remove src */)
|
||||
+ return storage.internalCopyOrMoveBlob(src, dst, azblob.Metadata{"SymLink": src}, false /* move */)
|
||||
}
|
||||
|
||||
// HardLink using symlink functionality as hard links do not exist
|
||||
@@ -257,33 +253,28 @@ func (storage *PublishedStorage) HardLink(src string, dst string) error {
|
||||
|
||||
// FileExists returns true if path exists
|
||||
func (storage *PublishedStorage) FileExists(path string) (bool, error) {
|
||||
- serviceClient := storage.az.client.ServiceClient()
|
||||
- containerClient := serviceClient.NewContainerClient(storage.az.container)
|
||||
- blobClient := containerClient.NewBlobClient(path)
|
||||
- _, err := blobClient.GetProperties(context.Background(), nil)
|
||||
+ blob := storage.az.blobURL(path)
|
||||
+ resp, err := blob.GetProperties(context.Background(), azblob.BlobAccessConditions{}, azblob.ClientProvidedKeyOptions{})
|
||||
if err != nil {
|
||||
if isBlobNotFound(err) {
|
||||
return false, nil
|
||||
}
|
||||
- return false, fmt.Errorf("error checking if blob %s exists: %v", path, err)
|
||||
+ return false, err
|
||||
+ } else if resp.StatusCode() == http.StatusOK {
|
||||
+ return true, nil
|
||||
}
|
||||
- return true, nil
|
||||
+ return false, fmt.Errorf("error checking if blob %s exists %d", blob, resp.StatusCode())
|
||||
}
|
||||
|
||||
// ReadLink returns the symbolic link pointed to by path.
|
||||
// This simply reads text file created with SymLink
|
||||
func (storage *PublishedStorage) ReadLink(path string) (string, error) {
|
||||
- serviceClient := storage.az.client.ServiceClient()
|
||||
- containerClient := serviceClient.NewContainerClient(storage.az.container)
|
||||
- blobClient := containerClient.NewBlobClient(path)
|
||||
- props, err := blobClient.GetProperties(context.Background(), nil)
|
||||
+ blob := storage.az.blobURL(path)
|
||||
+ resp, err := blob.GetProperties(context.Background(), azblob.BlobAccessConditions{}, azblob.ClientProvidedKeyOptions{})
|
||||
if err != nil {
|
||||
- return "", fmt.Errorf("failed to get blob properties: %v", err)
|
||||
+ return "", err
|
||||
+ } else if resp.StatusCode() != http.StatusOK {
|
||||
+ return "", fmt.Errorf("error checking if blob %s exists %d", blob, resp.StatusCode())
|
||||
}
|
||||
-
|
||||
- metadata := props.Metadata
|
||||
- if originalBlob, exists := metadata["original_blob"]; exists {
|
||||
- return *originalBlob, nil
|
||||
- }
|
||||
- return "", fmt.Errorf("error reading link %s: %v", path, err)
|
||||
+ return resp.NewMetadata()["SymLink"], nil
|
||||
}
|
||||
diff --git a/azure/public_test.go b/azure/public_test.go
|
||||
index 5c912c5..f58ad51 100644
|
||||
--- a/azure/public_test.go
|
||||
+++ b/azure/public_test.go
|
||||
@@ -7,11 +7,8 @@
|
||||
"io"
|
||||
"os"
|
||||
"path/filepath"
|
||||
- "bytes"
|
||||
|
||||
- "github.com/Azure/azure-sdk-for-go/sdk/azcore"
|
||||
- "github.com/Azure/azure-sdk-for-go/sdk/storage/azblob"
|
||||
- "github.com/Azure/azure-sdk-for-go/sdk/storage/azblob/blob"
|
||||
+ "github.com/Azure/azure-storage-blob-go/azblob"
|
||||
"github.com/aptly-dev/aptly/files"
|
||||
"github.com/aptly-dev/aptly/utils"
|
||||
. "gopkg.in/check.v1"
|
||||
@@ -69,10 +66,8 @@ func (s *PublishedStorageSuite) SetUpTest(c *C) {
|
||||
|
||||
s.storage, err = NewPublishedStorage(s.accountName, s.accountKey, container, "", s.endpoint)
|
||||
c.Assert(err, IsNil)
|
||||
- publicAccessType := azblob.PublicAccessTypeContainer
|
||||
- _, err = s.storage.az.client.CreateContainer(context.Background(), s.storage.az.container, &azblob.CreateContainerOptions{
|
||||
- Access: &publicAccessType,
|
||||
- })
|
||||
+ cnt := s.storage.az.container
|
||||
+ _, err = cnt.Create(context.Background(), azblob.Metadata{}, azblob.PublicAccessContainer)
|
||||
c.Assert(err, IsNil)
|
||||
|
||||
s.prefixedStorage, err = NewPublishedStorage(s.accountName, s.accountKey, container, prefix, s.endpoint)
|
||||
@@ -80,39 +75,41 @@ func (s *PublishedStorageSuite) SetUpTest(c *C) {
|
||||
}
|
||||
|
||||
func (s *PublishedStorageSuite) TearDownTest(c *C) {
|
||||
- _, err := s.storage.az.client.DeleteContainer(context.Background(), s.storage.az.container, nil)
|
||||
+ cnt := s.storage.az.container
|
||||
+ _, err := cnt.Delete(context.Background(), azblob.ContainerAccessConditions{})
|
||||
c.Assert(err, IsNil)
|
||||
}
|
||||
|
||||
func (s *PublishedStorageSuite) GetFile(c *C, path string) []byte {
|
||||
- resp, err := s.storage.az.client.DownloadStream(context.Background(), s.storage.az.container, path, nil)
|
||||
+ blob := s.storage.az.container.NewBlobURL(path)
|
||||
+ resp, err := blob.Download(context.Background(), 0, azblob.CountToEnd, azblob.BlobAccessConditions{}, false, azblob.ClientProvidedKeyOptions{})
|
||||
c.Assert(err, IsNil)
|
||||
- data, err := io.ReadAll(resp.Body)
|
||||
+ body := resp.Body(azblob.RetryReaderOptions{MaxRetryRequests: 3})
|
||||
+ data, err := io.ReadAll(body)
|
||||
c.Assert(err, IsNil)
|
||||
return data
|
||||
}
|
||||
|
||||
func (s *PublishedStorageSuite) AssertNoFile(c *C, path string) {
|
||||
- serviceClient := s.storage.az.client.ServiceClient()
|
||||
- containerClient := serviceClient.NewContainerClient(s.storage.az.container)
|
||||
- blobClient := containerClient.NewBlobClient(path)
|
||||
- _, err := blobClient.GetProperties(context.Background(), nil)
|
||||
+ _, err := s.storage.az.container.NewBlobURL(path).GetProperties(
|
||||
+ context.Background(), azblob.BlobAccessConditions{}, azblob.ClientProvidedKeyOptions{})
|
||||
c.Assert(err, NotNil)
|
||||
-
|
||||
- storageError, ok := err.(*azcore.ResponseError)
|
||||
+ storageError, ok := err.(azblob.StorageError)
|
||||
c.Assert(ok, Equals, true)
|
||||
- c.Assert(storageError.StatusCode, Equals, 404)
|
||||
+ c.Assert(string(storageError.ServiceCode()), Equals, string(string(azblob.StorageErrorCodeBlobNotFound)))
|
||||
}
|
||||
|
||||
func (s *PublishedStorageSuite) PutFile(c *C, path string, data []byte) {
|
||||
hash := md5.Sum(data)
|
||||
- uploadOptions := &azblob.UploadStreamOptions{
|
||||
- HTTPHeaders: &blob.HTTPHeaders{
|
||||
- BlobContentMD5: hash[:],
|
||||
- },
|
||||
- }
|
||||
- reader := bytes.NewReader(data)
|
||||
- _, err := s.storage.az.client.UploadStream(context.Background(), s.storage.az.container, path, reader, uploadOptions)
|
||||
+ _, err := azblob.UploadBufferToBlockBlob(
|
||||
+ context.Background(),
|
||||
+ data,
|
||||
+ s.storage.az.container.NewBlockBlobURL(path),
|
||||
+ azblob.UploadToBlockBlobOptions{
|
||||
+ BlobHTTPHeaders: azblob.BlobHTTPHeaders{
|
||||
+ ContentMD5: hash[:],
|
||||
+ },
|
||||
+ })
|
||||
c.Assert(err, IsNil)
|
||||
}
|
||||
|
||||
@@ -333,7 +330,7 @@ func (s *PublishedStorageSuite) TestLinkFromPool(c *C) {
|
||||
|
||||
// 2nd link from pool, providing wrong path for source file
|
||||
//
|
||||
- // this test should check that file already exists in Azure and skip upload (which would fail if not skipped)
|
||||
+ // this test should check that file already exists in S3 and skip upload (which would fail if not skipped)
|
||||
s.prefixedStorage.pathCache = nil
|
||||
err = s.prefixedStorage.LinkFromPool("", filepath.Join("pool", "main", "m/mars-invaders"), "mars-invaders_1.03.deb", pool, "wrong-looks-like-pathcache-doesnt-work", cksum1, false)
|
||||
c.Check(err, IsNil)
|
||||
diff --git a/context/context.go b/context/context.go
|
||||
index 0ffc3f7..503cad2 100644
|
||||
--- a/context/context.go
|
||||
+++ b/context/context.go
|
||||
@@ -100,6 +100,7 @@ func (context *AptlyContext) config() *utils.ConfigStructure {
|
||||
configLocations := []string{homeLocation, "/usr/local/etc/aptly.conf", "/etc/aptly.conf"}
|
||||
|
||||
for _, configLocation := range configLocations {
|
||||
+ // FIXME: check if exists, check if readable
|
||||
err = utils.LoadConfig(configLocation, &utils.Config)
|
||||
if os.IsPermission(err) || os.IsNotExist(err) {
|
||||
continue
|
||||
diff --git a/deb/list.go b/deb/list.go
|
||||
index 25a2d28..9eda528 100644
|
||||
--- a/deb/list.go
|
||||
+++ b/deb/list.go
|
||||
@@ -598,6 +598,7 @@ func (l *PackageList) Filter(options FilterOptions) (*PackageList, error) {
|
||||
//
|
||||
// when follow-all-variants is enabled, we need to try to expand anyway,
|
||||
// as even if dependency is satisfied now, there might be other ways to satisfy dependency
|
||||
+ // FIXME: do not search twice
|
||||
if result.Search(dep, false, true) != nil {
|
||||
if options.DependencyOptions&DepVerboseResolve == DepVerboseResolve && options.Progress != nil {
|
||||
options.Progress.ColoredPrintf("@{y}Already satisfied dependency@|: %s with %s", &dep, result.Search(dep, true, true))
|
||||
diff --git a/go.mod b/go.mod
|
||||
index 53c5e78..d7f145a 100644
|
||||
--- a/go.mod
|
||||
+++ b/go.mod
|
||||
@@ -4,6 +4,7 @@ go 1.24
|
||||
|
||||
require (
|
||||
github.com/AlekSi/pointer v1.1.0
|
||||
+ github.com/Azure/azure-storage-blob-go v0.15.0
|
||||
github.com/DisposaBoy/JsonConfigReader v0.0.0-20171218180944-5ea4d0ddac55
|
||||
github.com/awalterschulze/gographviz v2.0.1+incompatible
|
||||
github.com/cavaliergopher/grab/v3 v3.0.1
|
||||
@@ -41,7 +42,7 @@ require (
|
||||
)
|
||||
|
||||
require (
|
||||
- github.com/Azure/azure-sdk-for-go/sdk/internal v1.10.0 // indirect
|
||||
+ github.com/Azure/azure-pipeline-go v0.2.3 // indirect
|
||||
github.com/KyleBanks/depth v1.2.1 // indirect
|
||||
github.com/PuerkitoBio/purell v1.1.1 // indirect
|
||||
github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 // indirect
|
||||
@@ -87,6 +88,7 @@ require (
|
||||
github.com/kr/text v0.2.0 // indirect
|
||||
github.com/leodido/go-urn v1.2.4 // indirect
|
||||
github.com/mailru/easyjson v0.7.6 // indirect
|
||||
+ github.com/mattn/go-ieproxy v0.0.9 // indirect
|
||||
github.com/mattn/go-isatty v0.0.20 // indirect
|
||||
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
|
||||
github.com/modern-go/reflect2 v1.0.2 // indirect
|
||||
@@ -96,7 +98,7 @@ require (
|
||||
github.com/prometheus/common v0.59.1 // indirect
|
||||
github.com/prometheus/procfs v0.15.1 // indirect
|
||||
github.com/rivo/uniseg v0.4.7 // indirect
|
||||
- github.com/rogpeppe/go-internal v1.12.0 // indirect
|
||||
+ github.com/rogpeppe/go-internal v1.10.0 // indirect
|
||||
github.com/twitchyliquid64/golang-asm v0.15.1 // indirect
|
||||
go.etcd.io/etcd/api/v3 v3.5.15 // indirect
|
||||
go.etcd.io/etcd/client/pkg/v3 v3.5.15 // indirect
|
||||
@@ -115,8 +117,6 @@ require (
|
||||
)
|
||||
|
||||
require (
|
||||
- github.com/Azure/azure-sdk-for-go/sdk/azcore v1.14.0
|
||||
- github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.4.1
|
||||
github.com/ProtonMail/go-crypto v1.0.0
|
||||
github.com/aws/aws-sdk-go-v2 v1.32.5
|
||||
github.com/aws/aws-sdk-go-v2/config v1.28.5
|
||||
diff --git a/go.sum b/go.sum
|
||||
index 502f4b2..453a288 100644
|
||||
--- a/go.sum
|
||||
+++ b/go.sum
|
||||
@@ -1,17 +1,20 @@
|
||||
github.com/AlekSi/pointer v1.1.0 h1:SSDMPcXD9jSl8FPy9cRzoRaMJtm9g9ggGTxecRUbQoI=
|
||||
github.com/AlekSi/pointer v1.1.0/go.mod h1:y7BvfRI3wXPWKXEBhU71nbnIEEZX0QTSB2Bj48UJIZE=
|
||||
-github.com/Azure/azure-sdk-for-go/sdk/azcore v1.14.0 h1:nyQWyZvwGTvunIMxi1Y9uXkcyr+I7TeNrr/foo4Kpk8=
|
||||
-github.com/Azure/azure-sdk-for-go/sdk/azcore v1.14.0/go.mod h1:l38EPgmsp71HHLq9j7De57JcKOWPyhrsW1Awm1JS6K0=
|
||||
-github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.7.0 h1:tfLQ34V6F7tVSwoTf/4lH5sE0o6eCJuNDTmH09nDpbc=
|
||||
-github.com/Azure/azure-sdk-for-go/sdk/azidentity v1.7.0/go.mod h1:9kIvujWAA58nmPmWB1m23fyWic1kYZMxD9CxaWn4Qpg=
|
||||
-github.com/Azure/azure-sdk-for-go/sdk/internal v1.10.0 h1:ywEEhmNahHBihViHepv3xPBn1663uRv2t2q/ESv9seY=
|
||||
-github.com/Azure/azure-sdk-for-go/sdk/internal v1.10.0/go.mod h1:iZDifYGJTIgIIkYRNWPENUnqx6bJ2xnSDFI2tjwZNuY=
|
||||
-github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage v1.6.0 h1:PiSrjRPpkQNjrM8H0WwKMnZUdu1RGMtd/LdGKUrOo+c=
|
||||
-github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/storage/armstorage v1.6.0/go.mod h1:oDrbWx4ewMylP7xHivfgixbfGBT6APAwsSoHRKotnIc=
|
||||
-github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.4.1 h1:cf+OIKbkmMHBaC3u78AXomweqM0oxQSgBXRZf3WH4yM=
|
||||
-github.com/Azure/azure-sdk-for-go/sdk/storage/azblob v1.4.1/go.mod h1:ap1dmS6vQKJxSMNiGJcq4QuUQkOynyD93gLw6MDF7ek=
|
||||
-github.com/AzureAD/microsoft-authentication-library-for-go v1.2.2 h1:XHOnouVk1mxXfQidrMEnLlPk9UMeRtyBTnEFtxkV0kU=
|
||||
-github.com/AzureAD/microsoft-authentication-library-for-go v1.2.2/go.mod h1:wP83P5OoQ5p6ip3ScPr0BAq0BvuPAvacpEuSzyouqAI=
|
||||
+github.com/Azure/azure-pipeline-go v0.2.3 h1:7U9HBg1JFK3jHl5qmo4CTZKFTVgMwdFHMVtCdfBE21U=
|
||||
+github.com/Azure/azure-pipeline-go v0.2.3/go.mod h1:x841ezTBIMG6O3lAcl8ATHnsOPVl2bqk7S3ta6S6u4k=
|
||||
+github.com/Azure/azure-storage-blob-go v0.15.0 h1:rXtgp8tN1p29GvpGgfJetavIG0V7OgcSXPpwp3tx6qk=
|
||||
+github.com/Azure/azure-storage-blob-go v0.15.0/go.mod h1:vbjsVbX0dlxnRc4FFMPsS9BsJWPcne7GB7onqlPvz58=
|
||||
+github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
|
||||
+github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
|
||||
+github.com/Azure/go-autorest/autorest/adal v0.9.13 h1:Mp5hbtOePIzM8pJVRa3YLrWWmZtoxRXqUEzCfJt3+/Q=
|
||||
+github.com/Azure/go-autorest/autorest/adal v0.9.13/go.mod h1:W/MM4U6nLxnIskrw4UwWzlHfGjwUS50aOsc/I3yuU8M=
|
||||
+github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
|
||||
+github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
|
||||
+github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
|
||||
+github.com/Azure/go-autorest/logger v0.2.1 h1:IG7i4p/mDa2Ce4TRyAO8IHnVhAVF3RFU+ZtXWSmf4Tg=
|
||||
+github.com/Azure/go-autorest/logger v0.2.1/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
|
||||
+github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
|
||||
+github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
|
||||
github.com/DisposaBoy/JsonConfigReader v0.0.0-20171218180944-5ea4d0ddac55 h1:jbGlDKdzAZ92NzK65hUP98ri0/r50vVVvmZsFP/nIqo=
|
||||
github.com/DisposaBoy/JsonConfigReader v0.0.0-20171218180944-5ea4d0ddac55/go.mod h1:GCzqZQHydohgVLSIqRKZeTt8IGb1Y4NaFfim3H40uUI=
|
||||
github.com/KyleBanks/depth v1.2.1 h1:5h8fQADFrWtarTdtDudMmGsC7GPbOAu6RVB3ffsVFHc=
|
||||
@@ -91,6 +94,8 @@ github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c
|
||||
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
|
||||
github.com/fatih/color v1.17.0 h1:GlRw1BRJxkpqUCBKzKOw098ed57fEsKeNjpTe3cSjK4=
|
||||
github.com/fatih/color v1.17.0/go.mod h1:YZ7TlrGPkiz6ku9fK3TLD/pl3CpsiFyu8N92HLgmosI=
|
||||
+github.com/form3tech-oss/jwt-go v3.2.2+incompatible h1:TcekIExNqud5crz4xD2pavyTgWiPvpYe4Xau31I0PRk=
|
||||
+github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
|
||||
github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo=
|
||||
github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ=
|
||||
github.com/fsnotify/fsnotify v1.5.4 h1:jRbGcIw6P2Meqdwuo0H1p6JVLbL5DHKAKlYndzMwVZI=
|
||||
@@ -127,8 +132,6 @@ github.com/goccy/go-json v0.10.2/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MG
|
||||
github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA=
|
||||
github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q=
|
||||
github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q=
|
||||
-github.com/golang-jwt/jwt/v5 v5.2.1 h1:OuVbFODueb089Lh128TAcimifWaLhJwVflnrgM17wHk=
|
||||
-github.com/golang-jwt/jwt/v5 v5.2.1/go.mod h1:pqrtFR0X4osieyHYxtmOUWsAWrfe1Q5UVIyoH402zdk=
|
||||
github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
|
||||
github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8=
|
||||
github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA=
|
||||
@@ -149,7 +152,8 @@ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/
|
||||
github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI=
|
||||
github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY=
|
||||
github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
|
||||
-github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE=
|
||||
+github.com/google/uuid v1.0.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
+github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0=
|
||||
github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/h2non/filetype v1.1.3 h1:FKkx9QbD7HR/zjK1Ia5XiBsq9zdLi5Kf3zGyFTAFkGg=
|
||||
@@ -197,6 +201,9 @@ github.com/mailru/easyjson v0.7.6/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJ
|
||||
github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4=
|
||||
github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA=
|
||||
github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg=
|
||||
+github.com/mattn/go-ieproxy v0.0.1/go.mod h1:pYabZ6IHcRpFh7vIaLfK7rdcWgFEb3SFJ6/gNWuh88E=
|
||||
+github.com/mattn/go-ieproxy v0.0.9 h1:RvVbLiMv/Hbjf1gRaC2AQyzwbdVhdId7D2vPnXIml4k=
|
||||
+github.com/mattn/go-ieproxy v0.0.9/go.mod h1:eF30/rfdQUO9EnzNIZQr0r9HiLMlZNCpJkHbmMuOAE0=
|
||||
github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94=
|
||||
github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM=
|
||||
github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY=
|
||||
@@ -235,8 +242,6 @@ github.com/onsi/gomega v1.19.0 h1:4ieX6qQjPP/BfC3mpsAtIGGlxTWPeA3Inl/7DtXw1tw=
|
||||
github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro=
|
||||
github.com/pelletier/go-toml/v2 v2.1.0 h1:FnwAJ4oYMvbT/34k9zzHuZNrhlz48GB3/s6at6/MHO4=
|
||||
github.com/pelletier/go-toml/v2 v2.1.0/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc=
|
||||
-github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c h1:+mdjkGKdHQG3305AYmdv1U2eRNDiU2ErMBj1gwrq8eQ=
|
||||
-github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c/go.mod h1:7rwL4CYBLnjLxUqIJNnCWiEdr3bn6IUYi15bNlnbCCU=
|
||||
github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA=
|
||||
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
|
||||
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
|
||||
@@ -254,8 +259,8 @@ github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJ
|
||||
github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ=
|
||||
github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88=
|
||||
github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs=
|
||||
-github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8=
|
||||
-github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4=
|
||||
+github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ=
|
||||
+github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog=
|
||||
github.com/rs/xid v1.4.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg=
|
||||
github.com/rs/zerolog v1.29.1 h1:cO+d60CHkknCbvzEWxP0S9K6KqyTjrCNUy1LdQLCGPc=
|
||||
github.com/rs/zerolog v1.29.1/go.mod h1:Le6ESbR7hc+DP6Lt1THiV8CQSdkkNrd3R0XbEgp3ZBU=
|
||||
@@ -319,6 +324,8 @@ golang.org/x/arch v0.3.0/go.mod h1:5om86z9Hs0C8fWVUuoMHwpExlXzs5Tkyp9hOrfG7pp8=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI=
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
+golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
+golang.org/x/crypto v0.0.0-20201016220609-9e8e0b390897/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc=
|
||||
golang.org/x/crypto v0.3.1-0.20221117191849-2c476679df9a/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4=
|
||||
golang.org/x/crypto v0.7.0/go.mod h1:pYwdfH91IfpZVANVyUOhSIPZaFoJGxTFbZhFTx+dXZU=
|
||||
@@ -333,14 +340,14 @@ golang.org/x/mod v0.23.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY=
|
||||
golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4=
|
||||
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
||||
golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
+golang.org/x/net v0.0.0-20191112182307-2180aed22343/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s=
|
||||
golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A=
|
||||
golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU=
|
||||
golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg=
|
||||
golang.org/x/net v0.0.0-20210421230115-4e50805a0758/go.mod h1:72T/g9IO56b78aLF+1Kcs5dz7/ng1VjMUvfKvpfy+jM=
|
||||
-golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk=
|
||||
-golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk=
|
||||
-golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
|
||||
+golang.org/x/net v0.0.0-20210610132358-84b48f89b13b/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y=
|
||||
+golang.org/x/net v0.0.0-20220630215102-69896b714898/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
|
||||
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
|
||||
golang.org/x/net v0.2.0/go.mod h1:KqCZLdyyvdV855qA2rE3GC2aiw5xGR5TEjj8smXukLY=
|
||||
golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs=
|
||||
@@ -362,6 +369,7 @@ golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5h
|
||||
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
+golang.org/x/sys v0.0.0-20191112214154-59a1497f0cea/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
From: =?utf-8?q?S=C3=A9bastien_Delafond?= <seb@debian.org>
|
||||
Date: Mon, 17 Feb 2025 10:11:55 +0100
|
||||
Subject: tests: no upstream's etcd install as it's arch-specific,
|
||||
and no swagger-related or modules tasks
|
||||
|
||||
Forwarded: not-needed
|
||||
---
|
||||
Makefile | 11 +++--------
|
||||
1 file changed, 3 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/Makefile b/Makefile
|
||||
index ffe2e8a..91f96a8 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -89,17 +89,12 @@ install:
|
||||
# go install -v
|
||||
@out=`mktemp`; if ! go install -v > $$out 2>&1; then cat $$out; rm -f $$out; echo "\nBuild failed\n"; exit 1; else rm -f $$out; fi
|
||||
|
||||
-test: prepare swagger etcd-install ## Run unit tests (add TEST=regex to specify which tests to run)
|
||||
- @echo "\e[33m\e[1mStarting etcd ...\e[0m"
|
||||
- @mkdir -p /tmp/aptly-etcd-data; system/t13_etcd/start-etcd.sh > /tmp/aptly-etcd-data/etcd.log 2>&1 &
|
||||
+test: ## Run unit tests
|
||||
@echo "\e[33m\e[1mRunning go test ...\e[0m"
|
||||
- faketime "$(TEST_FAKETIME)" go test -v ./... -gocheck.v=true -check.f "$(TEST)" -coverprofile=unit.out; echo $$? > .unit-test.ret
|
||||
- @echo "\e[33m\e[1mStopping etcd ...\e[0m"
|
||||
- @pid=`cat /tmp/etcd.pid`; kill $$pid
|
||||
- @rm -f /tmp/aptly-etcd-data/etcd.log
|
||||
+ go test -v ./... -gocheck.v=true -coverprofile=unit.out; echo $$? > .unit-test.ret
|
||||
@ret=`cat .unit-test.ret`; if [ "$$ret" = "0" ]; then echo "\n\e[32m\e[1mUnit Tests SUCCESSFUL\e[0m"; else echo "\n\e[31m\e[1mUnit Tests FAILED\e[0m"; fi; rm -f .unit-test.ret; exit $$ret
|
||||
|
||||
-system-test: prepare swagger etcd-install ## Run system tests
|
||||
+system-test: ## Run system tests
|
||||
# build coverage binary
|
||||
go test -v -coverpkg="./..." -c -tags testruncli
|
||||
# Download fixture-db, fixture-pool, etcd.db
|
||||
@@ -0,0 +1,40 @@
|
||||
From: =?utf-8?q?S=C3=A9bastien_Delafond?= <seb@debian.org>
|
||||
Date: Wed, 24 Sep 2025 07:23:24 +0200
|
||||
Subject: Revert "system-tests: abort on failure"
|
||||
|
||||
We'd rather have the test suite always run completely, and report
|
||||
every failed test at the end.
|
||||
|
||||
Forwarded: not-needed
|
||||
---
|
||||
system/run.py | 8 --------
|
||||
1 file changed, 8 deletions(-)
|
||||
|
||||
diff --git a/system/run.py b/system/run.py
|
||||
index 4e73fb2..599afe5 100755
|
||||
--- a/system/run.py
|
||||
+++ b/system/run.py
|
||||
@@ -50,7 +50,6 @@ def run(include_long_tests=False, capture_results=False, tests=None, filters=Non
|
||||
if not coverage_dir:
|
||||
coverage_dir = mkdtemp(suffix="aptly-coverage")
|
||||
|
||||
- failed = False
|
||||
for test in tests:
|
||||
orig_stdout = sys.stdout
|
||||
orig_stderr = sys.stderr
|
||||
@@ -158,15 +157,8 @@ def run(include_long_tests=False, capture_results=False, tests=None, filters=Non
|
||||
|
||||
t.shutdown()
|
||||
|
||||
- if failed:
|
||||
- break
|
||||
- if failed:
|
||||
- break
|
||||
-
|
||||
sys.stdout = orig_stdout
|
||||
sys.stderr = orig_stderr
|
||||
- if failed:
|
||||
- break
|
||||
|
||||
if lastBase is not None:
|
||||
lastBase.shutdown_class()
|
||||
Vendored
+4
@@ -0,0 +1,4 @@
|
||||
0001-disable-swagger.patch
|
||||
0002-disable-new-azure-sdk.patch
|
||||
0003-tests-no-upstream-s-etcd-install-as-it-s-arch-specif.patch
|
||||
0004-Revert-system-tests-abort-on-failure.patch
|
||||
Vendored
+4
-34
@@ -2,47 +2,17 @@
|
||||
|
||||
include /usr/share/dpkg/pkg-info.mk
|
||||
|
||||
export GOPATH=$(shell pwd)/.go
|
||||
export DEB_BUILD_OPTIONS=crossbuildcanrunhostbinaries
|
||||
|
||||
export GOARCH := $(shell if [ $(DEB_TARGET_ARCH) = "i386" ]; then echo "386"; elif [ $(DEB_TARGET_ARCH) = "armhf" ]; then echo "arm"; else echo $(DEB_TARGET_ARCH); fi)
|
||||
export CGO_ENABLED=1
|
||||
|
||||
ifneq ($(DEB_HOST_GNU_TYPE), $(DEB_BUILD_GNU_TYPE))
|
||||
export CC=$(DEB_HOST_GNU_TYPE)-gcc
|
||||
endif
|
||||
|
||||
%:
|
||||
dh $@ --buildsystem=golang --with=golang,bash-completion
|
||||
|
||||
override_dh_auto_clean:
|
||||
rm -rf build/
|
||||
rm -rf obj-$(DEB_TARGET_GNU_TYPE)/
|
||||
dh_auto_clean
|
||||
|
||||
override_dh_auto_test:
|
||||
# run during autopkgtests
|
||||
|
||||
override_dh_auto_install:
|
||||
dh_auto_install -- --no-source
|
||||
|
||||
override_dh_strip:
|
||||
dh_strip --dbg-package=aptly-dbg
|
||||
|
||||
override_dh_golang: # fails on non native debian build
|
||||
|
||||
# override_dh_makeshlibs: # fails with cross compiling on non native debian build
|
||||
|
||||
override_dh_dwz: # somehow dwz works only with certain newer debhelper versions
|
||||
dhver=`dpkg-query -f '$${Version}' -W debhelper`; (dpkg --compare-versions "$$dhver" lt 13 || test "$$dhver" = "13.3.4" || test "$$dhver" = "13.6ubuntu1") || dh_dwz
|
||||
|
||||
override_dh_shlibdeps:
|
||||
ifneq ($(DEB_HOST_GNU_TYPE), $(DEB_BUILD_GNU_TYPE))
|
||||
LD_LIBRARY_PATH=/usr/$(DEB_HOST_GNU_TYPE)/lib:$$LD_LIBRARY_PATH dh_shlibdeps
|
||||
else
|
||||
dh_shlibdeps
|
||||
endif
|
||||
|
||||
override_dh_auto_build:
|
||||
echo $(DEB_VERSION) > VERSION
|
||||
go build -buildmode=pie -o usr/bin/aptly
|
||||
echo $(DEB_VERSION) > obj-$(DEB_TARGET_GNU_TYPE)/src/github.com/aptly-dev/aptly/VERSION
|
||||
mkdir -p obj-$(DEB_TARGET_GNU_TYPE)/src/github.com/aptly-dev/aptly/debian
|
||||
cp debian/aptly.conf obj-$(DEB_TARGET_GNU_TYPE)/src/github.com/aptly-dev/aptly/debian/
|
||||
dh_auto_build
|
||||
|
||||
Vendored
+1
-1
@@ -1 +1 @@
|
||||
3.0 (git)
|
||||
3.0 (quilt)
|
||||
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
#!/bin/sh
|
||||
|
||||
# run upstream's unit tests with Debian-supplied dependencies
|
||||
|
||||
# FIXME: right now this fails hard because many prerequisites are only
|
||||
# handled in `make test`
|
||||
|
||||
set -e
|
||||
set -u
|
||||
set -x
|
||||
|
||||
BUILD_DIR="${PWD}/_build"
|
||||
DH_OPTIONS="-O--buildsystem=golang -O--builddirectory=$BUILD_DIR"
|
||||
APTLY_DIR="${BUILD_DIR}/src/github.com/aptly-dev/aptly"
|
||||
|
||||
dpkg-source --before-build .
|
||||
|
||||
dh_update_autotools_config $DH_OPTIONS
|
||||
dh_autoreconf $DH_OPTIONS
|
||||
dh_auto_configure $DH_OPTIONS
|
||||
|
||||
dpkg-parsechangelog --show-field Version | perl -pe 's/\n//' >| ${APTLY_DIR}/VERSION
|
||||
find . -name VERSION
|
||||
|
||||
mkdir -p ${APTLY_DIR}/debian
|
||||
cp debian/aptly.conf ${APTLY_DIR}/debian/
|
||||
|
||||
dh_auto_build $DH_OPTIONS
|
||||
|
||||
export PATH=${BUILD_DIR}/bin:$PATH
|
||||
|
||||
dh_auto_test $DH_OPTIONS --no-parallel
|
||||
Vendored
+6
-3
@@ -1,4 +1,7 @@
|
||||
# This file is an addition to the autodep8 tests.
|
||||
|
||||
Test-Command: HOME=/tmp aptly repo create autopkgtest
|
||||
Tests: unit-test
|
||||
Depends: @, @builddeps@, ca-certificates, curl, git, gpg, gpg-agent
|
||||
Restrictions: allow-stderr
|
||||
|
||||
Tests: system-test
|
||||
Depends: @, @builddeps@, ca-certificates, curl, dirmngr, git, gpg, gpg-agent, gpgconf, graphviz, procps, python3, python3-requests-unixsocket, python3-termcolor, python3-swiftclient, python3-boto3, python3-azure-storage, python3-etcd3, python3-plyvel, sudo, zip
|
||||
Restrictions: allow-stderr, needs-internet
|
||||
|
||||
+20
@@ -0,0 +1,20 @@
|
||||
#!/bin/sh
|
||||
|
||||
set -eux
|
||||
|
||||
TMP_DIR="$(mktemp -d)"
|
||||
APTLY_SRC_DIR="${TMP_DIR}/src/github.com/aptly-dev/aptly"
|
||||
|
||||
# apply patches
|
||||
dpkg-source --before-build .
|
||||
|
||||
# copy source to GOPATH-compatible dir
|
||||
mkdir -p $(dirname $APTLY_SRC_DIR)
|
||||
cp -a . $APTLY_SRC_DIR
|
||||
|
||||
# not in a git tree, so we need to generate the version ourselves
|
||||
dpkg-parsechangelog --show-field Version | perl -pe 's/\n//' > ${APTLY_SRC_DIR}/VERSION
|
||||
|
||||
# use only apt-supplied go libraries
|
||||
export GOPATH="${TMP_DIR}:/usr/share/gocode"
|
||||
export GO111MODULE=off
|
||||
+42
@@ -0,0 +1,42 @@
|
||||
#!/bin/sh
|
||||
|
||||
# run upstream's integration tests
|
||||
|
||||
set -eux
|
||||
|
||||
. debian/tests/setup
|
||||
|
||||
## env
|
||||
TESTS_DIR="${APTLY_SRC_DIR}/system"
|
||||
|
||||
## functions
|
||||
disable_test() {
|
||||
local file=${1}.py
|
||||
local name=$2
|
||||
local reason=$3
|
||||
|
||||
echo "${name}.skipTest = 'Debian autopkgtest: $reason'" >> ${TESTS_DIR}/${file}
|
||||
}
|
||||
|
||||
## main
|
||||
export USER=root # for t07/RootDirInaccessible
|
||||
|
||||
disable_test t01_version/version VersionTest "version"
|
||||
disable_test t02_config/config CreateConfigTest "different conf"
|
||||
disable_test t04_mirror/create CreateMirror18Test "target repo down"
|
||||
disable_test t04_mirror/create CreateMirror31Test "public key not found"
|
||||
disable_test t04_mirror/create CreateMirror35Test "flaky on s390"
|
||||
disable_test t07_serve/serve Serve1Test "minor html diff"
|
||||
disable_test t09_repo/edit EditRepo4Test "flaky on riscv64"
|
||||
disable_test t10_task/run RunTask1Test "version"
|
||||
disable_test t12_api/docs TaskAPITestSwaggerDocs "no recent swag"
|
||||
disable_test t12_api/gpg GPGAPITestAddKey "flaky on s390"
|
||||
disable_test t12_api/unix_socket UnixSocketAPITest "type mismatch"
|
||||
disable_test t12_api/version VersionAPITest "type mismatch"
|
||||
disable_test t14_graph/graph CreateGraphTest "no viewer"
|
||||
disable_test t14_graph/graph CreateGraphOutputTest "no viewer"
|
||||
|
||||
# etcd fixture is entirely arch-specific
|
||||
rm -fr ${TESTS_DIR}/t13_etcd
|
||||
|
||||
make -C $APTLY_SRC_DIR system-test
|
||||
+20
@@ -0,0 +1,20 @@
|
||||
#!/bin/sh
|
||||
|
||||
# run upstream's unit tests with their full etcd fixtures, etc
|
||||
|
||||
set -eux
|
||||
|
||||
. debian/tests/setup
|
||||
|
||||
# FIXME: errors with non-constant format string in call to
|
||||
# github.com/aptly-dev/aptly/s3.fatalError
|
||||
rm ${APTLY_SRC_DIR}/s3/server_test.go
|
||||
rm ${APTLY_SRC_DIR}/s3/public_test.go
|
||||
|
||||
# upstream's etcd fixture is arch-specific
|
||||
rm ${APTLY_SRC_DIR}/database/etcddb/database_test.go
|
||||
|
||||
# TestVerifyClearsigned fails because of an extra signature
|
||||
perl -i -pe 's/(TestVerifyClearsigned)/No$1/' ${APTLY_SRC_DIR}/pgp/verify_test.go
|
||||
|
||||
make -C $APTLY_SRC_DIR test
|
||||
Vendored
+6
-5
@@ -1,5 +1,6 @@
|
||||
version=4
|
||||
opts=\
|
||||
repacksuffix=+ds1,\
|
||||
dversionmangle=s/\+ds\d*$// \
|
||||
https://github.com/aptly-dev/aptly/tags .*/v(\d[\d\.]*)\.tar\.gz debian uupdate
|
||||
Version: 5
|
||||
Template: Github
|
||||
Owner: aptly-dev
|
||||
Project: aptly
|
||||
Dversion-Mangle: s/\+ds\d*$//
|
||||
Repacksuffix: +ds1
|
||||
|
||||
Reference in New Issue
Block a user