Commit Graph

1348 Commits

Author SHA1 Message Date
Aaron Dewes caee762b51
Upgrade to distribution (registry) v3 alpha (#19784)
* registryctl/api/registry/blob: fix dropped test error (#19721)

Signed-off-by: Lars Lehtonen <lars.lehtonen@gmail.com>

* Remove robot account update quota permission (#19819)

Signed-off-by: Yang Jiao <yang.jiao@broadcom.com>
Co-authored-by: Yang Jiao <yang.jiao@broadcom.com>

* Cache image list with digest key (#19801)

fixes #19429

Signed-off-by: stonezdj <daojunz@vmware.com>
Co-authored-by: stonezdj <daojunz@vmware.com>

* Add quota permissions testcase (#19822)

Signed-off-by: Yang Jiao <yang.jiao@broadcom.com>
Co-authored-by: Yang Jiao <yang.jiao@broadcom.com>

* deprecate gosec in makefile (#19828)

remove the unused the part from makefile

Signed-off-by: wang yan <wangyan@vmware.com>

* Add verification that robot account duration is not 0 (#19829)

Signed-off-by: Yang Jiao <yang.jiao@broadcom.com>

* fix artifact page bug (#19807)

* fix artifact page bug

* update testcase

* Upgrade to distribution (registry) v3 alpha

This includes all the benefits of the v3 distribution, but also all breaking changes.

Most notably, Image Manifest v2 Schema v1 support has been dropped, as well as the `oss` and `swift` storage drivers.

Currently, this still relies on v2's github.com/docker/distribution/registry/client/auth/challenge, because that code has been removed from the public API in v3.

Signed-off-by: Aaron Dewes <aaron.dewes@protonmail.com>

---------

Signed-off-by: Lars Lehtonen <lars.lehtonen@gmail.com>
Signed-off-by: Yang Jiao <yang.jiao@broadcom.com>
Signed-off-by: stonezdj <daojunz@vmware.com>
Signed-off-by: wang yan <wangyan@vmware.com>
Signed-off-by: Aaron Dewes <aaron.dewes@protonmail.com>
Co-authored-by: Lars Lehtonen <lars.lehtonen@gmail.com>
Co-authored-by: Yang Jiao <72076317+YangJiao0817@users.noreply.github.com>
Co-authored-by: Yang Jiao <yang.jiao@broadcom.com>
Co-authored-by: stonezdj(Daojun Zhang) <stonezdj@gmail.com>
Co-authored-by: stonezdj <daojunz@vmware.com>
Co-authored-by: Wang Yan <wangyan@vmware.com>
Co-authored-by: ShengqiWang <124650040+ShengqiWang@users.noreply.github.com>
2024-01-26 22:48:06 +01:00
Liang Zheng 4378c15b1c
fix invalid links in harbor.yml.tmpl (#19786)
Signed-off-by: Liang Zheng <zhengliang0901@gmail.com>
2024-01-04 06:55:42 +00:00
Yang Jiao aefe1bce9d
Bump up PostgreSQL from 14 to 15 (#19789)
Fix #19512

Signed-off-by: Yang Jiao <yang.jiao@broadcom.com>
Co-authored-by: Yang Jiao <yang.jiao@broadcom.com>
2024-01-04 14:01:00 +08:00
Yang Jiao e397e86478
Fix docker version to 20.10.10 (#19751)
Signed-off-by: Yang Jiao <yang.jiao@broadcom.com>
Co-authored-by: Yang Jiao <yang.jiao@broadcom.com>
2023-12-26 16:57:25 +08:00
MinerYang b38de22054
bump golang 1.21.5 & fix golangci-lint error (#19722)
bump golang 1.21.5

update golangci-lint && fix revive error

fix white space lint

Signed-off-by: yminer <yminer@vmware.com>
2023-12-19 09:41:26 +08:00
Wang Yan aa1f79cd0c
bump distribution (#19669)
Bump up the distribution to v2.8.3

Signed-off-by: wang yan <wangyan@vmware.com>
2023-12-11 10:11:39 +08:00
MinerYang 3b127bc477
fix 2.10 prepare migration version (#19665)
fix 2.10 prepare migration

Signed-off-by: yminer <yminer@vmware.com>
2023-12-05 15:31:17 +08:00
MinerYang 9875965837
add prepare migration script for 2.10 (#19600)
Signed-off-by: yminer <yminer@vmware.com>
Co-authored-by: Wang Yan <wangyan@vmware.com>
2023-11-22 13:58:45 +08:00
Chlins Zhang 43ccd2f09f
perf: optimize the performance of accessory query (#19557)
1. Add db index for subject_artifact_id in table artifact_accessory.
2. Optimize the SQL of excluding the accessory for artifact count.

Signed-off-by: chlins <chenyuzh@vmware.com>
2023-11-22 02:11:11 +00:00
MinerYang 17c17ffd8e
bump golang to 1.21.4 (#19601)
Signed-off-by: yminer <yminer@vmware.com>
2023-11-21 19:23:16 +08:00
MinerYang 193b00b9e6
bump golang to 1.21.3 (#19504)
update ut mock

update go mod

Signed-off-by: yminer <yminer@vmware.com>
2023-10-31 15:01:23 +08:00
MinerYang 1f975edb9c
bump golang to 1.20.10 (#19430)
Signed-off-by: yminer <yminer@vmware.com>
2023-10-11 13:05:31 +08:00
Wang Yan ed370a496b
deprecate resource label (#19349)
There is no api is using the DAO, remove it from the source code.

Signed-off-by: wang yan <wangyan@vmware.com>
2023-09-14 01:25:52 +08:00
MinerYang eb0724d130
fix storage.redirect.disable migrate template error (#19335)
Signed-off-by: yminer <yminer@vmware.com>

update boolean to lowercase
2023-09-12 03:56:12 +00:00
Chlins Zhang c7e25295fe
fix: support customize cache db for business (#19182)
Support to configure the customized redis db for cache layer and other
misc business for core, by default the behavior is same with
previous(stored in db 0).

Signed-off-by: chlins <chenyuzh@vmware.com>
2023-08-18 11:04:16 +08:00
Chlins Zhang 56f6c27c4f
chore: fix incorrect otel timeout in harbor yaml template (#19120)
Update the incorrect otel timeout sample value in the harbor YAML
configuration template.

Signed-off-by: chlins <chenyuzh@vmware.com>
2023-08-16 16:26:16 +08:00
MinerYang b8f2ef9c9e
bump golang 1.20.7 on main (#19111)
Signed-off-by: yminer <yminer@vmware.com>
2023-08-07 15:40:44 +08:00
stonezdj(Daojun Zhang) 0e92eaea18
Sort most dangerous vulnerabilities by score and severity level (#19103)
Check it is referred by a scan_report
  Add index to report_vulnerability_record to improve performance
  Fixes #19014 #19028

Signed-off-by: stonezdj <daojunz@vmware.com>
2023-08-07 10:13:34 +08:00
MinerYang e1c1f5625d
bump golang 1.20.6 on main (#19066)
bump golang 1.20.6

Signed-off-by: yminer <yminer@vmware.com>
2023-08-02 11:01:32 +08:00
Yang Jiao 5e130bd06c
Bump up photon version from 4.0 to 5.0 (#19006)
Signed-off-by: Yang Jiao <jiaoya@vmware.com>
2023-08-01 11:52:33 +08:00
Alexis Leroux 84a131773a
Conserve sentinel_master_set value between upgraded versions (#18875)
fix(migration): Conserve sentinel_master_set value between upgraded versions

Signed-off-by: Alexis Leroux <alexis.leroux@worldline.com>
Co-authored-by: Alexis Leroux <alexis.leroux@worldline.com>
Co-authored-by: MinerYang <yminer@vmware.com>
2023-07-27 18:35:01 +08:00
MinerYang 3af605eedc
update installation hint (#19024)
Signed-off-by: yminer <yminer@vmware.com>
2023-07-27 10:41:05 +08:00
stonezdj(Daojun Zhang) c25a7ca68d
Skip to run migrate script when data available (#18976) 2023-07-25 19:41:35 +08:00
MinerYang 8102304621
add migration script for 2.9 (#18997)
add miigration script for 2.9

Signed-off-by: yminer <yminer@vmware.com>

update quota_update_provider

update typo

update comment
2023-07-25 17:52:37 +08:00
Yang Jiao 70554fe4f1
Fix build harbor-db-base error (#19003)
Fix #19002

Signed-off-by: Yang Jiao <jiaoya@vmware.com>
2023-07-25 16:45:23 +08:00
Shengwen YU 320c0d63ca
feat: add config for job_loggers (#18970)
Signed-off-by: Shengwen Yu <yshengwen@vmware.com>
2023-07-24 22:10:36 +08:00
Chlins Zhang 8ff095d68f
feat: add the configuration for quota update provider (#18928)
Add the related configurations for the quota update provider to the
harbor.yml.

Signed-off-by: chlins <chenyuzh@vmware.com>
2023-07-24 16:28:19 +08:00
stonezdj(Daojun Zhang) 5e4163b53b
Create index in vulnerability_record table (#18949)
add index for better query performance

Signed-off-by: stonezdj <daojunz@vmware.com>
2023-07-20 14:00:40 +08:00
Chlins Zhang 970bdab936
fix: correct the operator in the webhook payload (#18906)
Fix the incorrect or meaningless operator in the webhook payload.

Fixes: #18438

Signed-off-by: chlins <chenyuzh@vmware.com>
2023-07-19 15:40:29 +08:00
stonezdj(Daojun Zhang) d4aa9b13c4
Add vulnerability search API (#18924)
use q.Query to pass all query conditions

Signed-off-by: stonezdj <daojunz@vmware.com>
2023-07-19 10:17:14 +08:00
stonezdj(Daojun Zhang) d84b1d07d2
Update table scan_report and extract cvss_v3_score from vendor attribute (#18854)
For better performance when query cve information, add summary information to scan_report
    Extract cve_score from vendor attribute in vulnerability_record
    SQL migrate script for the update

Signed-off-by: stonezdj <daojunz@vmware.com>
2023-06-29 17:30:50 +08:00
MinerYang 14192dfb06
add strong_ssl_ciphers for nginx https jinja template (#18748)
Signed-off-by: yminer <yminer@vmware.com>
2023-05-29 21:57:15 +08:00
Stephan Hohn 4f3393e615
http2 enabled and ciphers changed to get an A+ rating instead of B fr… (#16990)
* Make strong cipher cfg optional
Signed-off-by: Stephan Hohn <stephan.hohn@tech11.com>

---------

Signed-off-by: Stephan Hohn <stephan.hohn@tech11.com>
Signed-off-by: MinerYang <yminer@vmware.com>
Co-authored-by: Stephan Hohn <stephan.hohn@tech11.com>
Co-authored-by: Wang Yan <wangyan@vmware.com>
Co-authored-by: MinerYang <yminer@vmware.com>
2023-05-29 10:37:57 +08:00
malmor 135ca37e3f
Add support for TLSv1.3 in nginx configurations (#18659)
Signed-off-by: malmor <62105800+malmor@users.noreply.github.com>
Co-authored-by: MinerYang <yminer@vmware.com>
2023-05-26 10:29:54 +08:00
David van der Spek 982ff0aeea
chore: bump registry release to 2.8.2 (#18685)
Signed-off-by: David van der Spek <vanderspek.david@gmail.com>
2023-05-26 09:37:45 +08:00
Wang Yan bf7c82b9a8
remove the notary from backend (#18668)
Since harbor deprecates notary since v2.9.0, this pull request targets to remove the code related with notary.

Signed-off-by: Wang Yan <wangyan@vmware.com>
2023-05-18 18:47:42 +08:00
Yang Jiao cb8a3d0c74
Fix build db base image symlink error (#18673)
Fix #18672

Signed-off-by: Yang Jiao <jiaoya@vmware.com>
2023-05-12 15:45:27 +08:00
Chlins Zhang 2958d7b7ff
fix: cherry pick the migration sql (#18644)
Cherry pick the migration SQL of 2.8.1 to main branch.

Signed-off-by: chlins <chenyuzh@vmware.com>
2023-05-10 16:35:07 +08:00
Chlins Zhang 36c2b93fe6
fix: sweep executions of image scan job (#18649)
1. Change the SCAN_ALL job execution retain counts from 5 to 1(per
   current design, only one report be stored for every artifact, so
   retain latest 1 is enough).
2. Enable the sweep for IMAGE_SCAN job(retain latest 1).

Fixes: #18633

Signed-off-by: chlins <chenyuzh@vmware.com>
2023-05-10 13:23:54 +08:00
MinerYang 220383147e
bump golang 1.20.4 on main (#18647)
Signed-off-by: yminer <yminer@vmware.com>
2023-05-09 23:27:26 +08:00
Shijun Sun 2fec790148
Copy swagger.json to the dist folder (#18646)
Signed-off-by: AllForNothing <sshijun@vmware.com>
2023-05-09 09:27:03 +08:00
Yang Jiao aaea068cce
Upgrade the internal PostgreSQL to 14 in 2.9.0 (#18612)
Fix #18338

Signed-off-by: Yang Jiao <jiaoya@vmware.com>
Co-authored-by: Wang Yan <wangyan@vmware.com>
2023-05-05 10:32:39 +08:00
Shijun Sun 0a3509f8a7
Replace python script with node script for portal Dockerfile (#18635)
Signed-off-by: AllForNothing <sshijun@vmware.com>
2023-05-04 17:38:03 +08:00
Chlins Zhang 362387f914
fix: improve the performance of list artifacts (#18610)
1. Change the query for listing tasks of scan which can use the db
   index.
2. Add the gin index for task.extra_attrs.report_uuids

Fixes: #18013

Signed-off-by: chlins <chenyuzh@vmware.com>
2023-04-30 09:10:28 +08:00
Per e20e4401cb
fix: link to Github's rate limiting documentation. (#18588)
Co-authored-by: Orlix <7236111+OrlinVasilev@users.noreply.github.com>
2023-04-25 13:11:40 +03:00
MinerYang 2d98e8fe1e
Allow redis password using safe special characters (#18566)
allow redis password safe special characters

Signed-off-by: yminer <yminer@vmware.com>

string and None type conversion
2023-04-24 11:01:46 +08:00
Maxi_Mega 96bc43f7ab
Fix typos in common.sh (#18151)
* Fix typos in common.sh

Signed-off-by: Maxi_Mega <52792549+Maxi-Mega@users.noreply.github.com>

* Apply suggestions from code review

Signed-off-by: Orlix <OrlinVasilev@users.noreply.github.com>

* Add a new line at the end of make/common.sh

Co-authored-by: Orlix <OrlinVasilev@users.noreply.github.com>
Signed-off-by: Maxi_Mega <52792549+Maxi-Mega@users.noreply.github.com>

---------

Signed-off-by: Maxi_Mega <52792549+Maxi-Mega@users.noreply.github.com>
Signed-off-by: Orlix <OrlinVasilev@users.noreply.github.com>
Co-authored-by: Orlix <OrlinVasilev@users.noreply.github.com>
2023-04-17 16:56:19 +08:00
MinerYang 7afdb932b2
bump golang 1.20.3 on main (#18492)
Signed-off-by: yminer <yminer@vmware.com>
Co-authored-by: Wang Yan <wangyan@vmware.com>
2023-04-10 09:27:31 +08:00
Chlins Zhang 72a6ef2514
style: adjust the style of migration SQL (#18475)
Signed-off-by: chlins <chenyuzh@vmware.com>
2023-04-04 17:37:27 +08:00
MinerYang de20659da5
bump golang 1.20.2 (#18469)
Signed-off-by: yminer <yminer@vmware.com>
2023-04-04 10:59:16 +08:00