Commit Graph

3381 Commits

Author SHA1 Message Date
Steven Zou
ebc5d2482b do improvements to the scan all job
- update scan all job to avoid sending too many HTTP requets
- update scan controller to support scan options
- update the db schema of the scan report to introduce requester
- introduce scan all metrics to report the overall progress of scan all job
- fix the status updating bug in scan report
- enhance the admin job status updats
- add duplicate checking before triggering generic admin job
- update the db scheme of admin job

fix #9705
fix #9722
fix #9670

Signed-off-by: Steven Zou <szou@vmware.com>
2019-11-05 15:12:07 +08:00
Steven Zou
a928928a43
Merge pull request #9686 from heww/fix-project-severity-mapping
fix(policy-checker): add func to transform project severity to vuln.Severity
2019-11-01 11:12:13 +08:00
jwangyangls
a21349fc66
Merge pull request #9676 from jwangyangls/modify-ui-style-quota
Improve the style of quota ui
2019-11-01 11:10:49 +08:00
Daniel Jiang
f2beee16b1
Merge pull request #9673 from steven-zou/fix/issue_#9668_status_conflicts
return more clear error message for scan related API
2019-11-01 11:08:43 +08:00
Wenkai Yin(尹文开)
2101d7125c
Merge pull request #9680 from heww/install-clair-adapter-imporvement
fix(scanner): imporve clair adapter initializing
2019-11-01 10:42:04 +08:00
Will Sun
1c8105e837
Merge pull request #9663 from AllForNothing/nav-modify
Modify harbor-shell UI
2019-11-01 10:26:54 +08:00
sshijun
b4fa143aa4 Modify harbor-shell UI
Signed-off-by: sshijun <sshijun@vmware.com>
2019-11-01 09:31:33 +08:00
He Weiwei
ae8931e816 fix(policy-checker): add func to transform project severity to vuln.Severity
The severity saved in db is lowercase but the severities in vuln pkg
begin with upper letter, this fix use func to transform project severity
value from db to vuln.Severity.

Signed-off-by: He Weiwei <hweiwei@vmware.com>
2019-10-31 14:11:44 +00:00
Steven Zou
eb8ec49f4f add UT cases for the common error pkg
Signed-off-by: Steven Zou <szou@vmware.com>
2019-10-31 21:55:27 +08:00
Daniel Jiang
bc65609a10
Merge pull request #9657 from wy65701436/quota-sync-switcher
add a switcher for quota sync on core launch
2019-10-31 19:22:23 +08:00
Wang Yan
fa784d7514
Merge pull request #9649 from wy65701436/fix-9081
add ldflags for harbor compiler and linker
2019-10-31 19:14:16 +08:00
Yogi_Wang
bdeddd4d95 Improve the style of quota ui
Signed-off-by: Yogi_Wang <yawang@vmware.com>
2019-10-31 16:38:20 +08:00
wang yan
c46d7e856a add a switcher for quota sync on core launch
As the quota sync is default called by harbor-core on every launch, and it will break the launch process if any failure throwed.

1, The commit is to provide an switcher for the system admin to bypass the quota sync.
2, In case Harbor goes into the restarting cycle.

Harbor already provides an internal API to sync quota data, in the failure case,
system admin can launch harbor and call the /api/internal/syncquota to sync quota.

Signed-off-by: wang yan <wangyan@vmware.com>
2019-10-31 16:17:27 +08:00
He Weiwei
7170485a9b fix(scanner): imporve clair adapter initializing
1. Remove ping action when initialize clair adapter installed by harbor.
2. Remvoe the `IsDefault` property when initialize clair adapter that
make it switch to auto detecting.

Signed-off-by: He Weiwei <hweiwei@vmware.com>
2019-10-31 08:03:37 +00:00
jwangyangls
b0b63fdeae
Merge pull request #9666 from jwangyangls/fix-ut-warning
Fix a warning that appears when running the test
2019-10-31 15:37:21 +08:00
Yogi_Wang
7aa47f8450 Fix a warning that appears when running the test
Signed-off-by: Yogi_Wang <yawang@vmware.com>
2019-10-31 14:28:59 +08:00
Steven Zou
afb46188b2 return more clear error message for scan related API
- add a common error pkg to support error with code and AsError check
- replace some errors in scan with coded errors
- fix #9668

Signed-off-by: Steven Zou <szou@vmware.com>
2019-10-31 11:35:55 +08:00
jwangyangls
cfffbb5e37
Merge pull request #9659 from jwangyangls/fix-ui-style-margin-top-0
Fix page style confusion caused by error margin-top
2019-10-31 10:03:04 +08:00
wang yan
253e87d186 inject ldflags for harbor compiler and linker
1, replace the UIVERSION file with ldflags, which is generarted by make to inject into the UI core.
2, inject additional ldflags for harbor compiler

Signed-off-by: wang yan <wangyan@vmware.com>
2019-10-30 18:31:42 +08:00
Wenkai Yin(尹文开)
5d6cbe9aa1
Merge pull request #9654 from heww/fix-qutoa-order-by
fix(quota): order by quotas only on support resources
2019-10-30 17:20:17 +08:00
Yogi_Wang
f7532ff6a1 Fix page style confusion caused by error margin-top
Signed-off-by: Yogi_Wang <yawang@vmware.com>
2019-10-30 16:46:10 +08:00
jwangyangls
b964d0411b
Merge pull request #9622 from jwangyangls/fix-ui-immutable-style
Improve immutable ui style
2019-10-30 15:03:18 +08:00
Yogi_Wang
a9adc50550 Improve immutable ui style
Signed-off-by: Yogi_Wang <yawang@vmware.com>
2019-10-30 12:07:48 +08:00
Will Sun
5f62b5778b
Merge pull request #9611 from AllForNothing/scanner-bug
Improve scanner UI
2019-10-30 10:43:48 +08:00
He Weiwei
3c80832341 fix(quota): order by quotas only on support resources
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2019-10-30 02:42:34 +00:00
sshijun
0c41a01f83 Improve scanner UI
Signed-off-by: sshijun <sshijun@vmware.com>
2019-10-29 18:47:57 +08:00
Steven Zou
19eb0ae7f4
Merge pull request #9637 from steven-zou/fix/bug_#9629
fix the bug of returning errors when nothing is updated
2019-10-29 17:37:06 +08:00
Steven Zou
adf780c2a5
Merge pull request #9634 from steven-zou/fix/#9632_and_#9633
fix bug found in the pluggable scanner
2019-10-29 17:36:19 +08:00
Will Sun
afd3b76001
Merge pull request #9567 from AllForNothing/scanner-css
Fix package vulnerabilities
2019-10-29 16:51:04 +08:00
jwangyangls
26453e8806
Merge pull request #9607 from jwangyangls/fix-delete-repositories-error
Fix the error when delete some images
2019-10-29 15:49:29 +08:00
Will Sun
c31b08ac3d
Merge pull request #8610 from AllForNothing/rep
change adapterInfo from by hardcode to by getting from backend API
2019-10-29 15:49:07 +08:00
Steven Zou
cb8d4d0daf fix the bug of returning errors nothing is updated
- bug details: #9629
- root cause: the preconditions for updating may not be matched

Signed-off-by: Steven Zou <szou@vmware.com>
2019-10-29 15:34:34 +08:00
Steven Zou
35d074e849 fix bug found in the pluggable scanner
- fix #9632
- fix #9633

Signed-off-by: Steven Zou <szou@vmware.com>
2019-10-29 15:32:51 +08:00
Daniel Jiang
b17711abbf
Merge pull request #9592 from qyqcswill/code_clean
remove useless code
2019-10-29 15:08:59 +08:00
sshijun
4a97cf40c6 change adapterInfo from by hardcode to by getting
from backend API

Signed-off-by: sshijun <sshijun@vmware.com>
2019-10-29 14:13:19 +08:00
Steven Zou
10c30fde3d
Merge pull request #9618 from steven-zou/fix/bug_#9608
permission grant for scanner related actions are not correctly
2019-10-28 22:12:56 +08:00
Steven Zou
5b2ab34e03 permission grant for scanner related actions are not correctly
- add new endpoint for getting scanner candidates of specified project
- adjust the permission granting functions
- fix #9608

Signed-off-by: Steven Zou <szou@vmware.com>
2019-10-28 18:20:47 +08:00
Wang Yan
e0fd4cd609
Merge pull request #9599 from wy65701436/fix-quota-migration
Fix quota sync crash on getting the unknown mainfest
2019-10-28 17:47:46 +08:00
Yogi_Wang
e7c7e7ac25 Fix the error when delete some images
Signed-off-by: Yogi_Wang <yawang@vmware.com>
fix #9604 fix #9603
2019-10-28 15:43:50 +08:00
wang yan
fc347fc4eb Fix quota sync crash on getting the unknown mainfest
1, eat the unknown manifest error, and log it. The migration process will not crashed on it.
2, enable to persist DB of sync quota API.
3, add empty project support.

Signed-off-by: wang yan <wangyan@vmware.com>
2019-10-28 15:17:08 +08:00
Steven Zou
5c4c04a122
Merge pull request #9602 from heww/upgrade-clair-adapter
Upgrade clair adapter to v1.0.0
2019-10-28 12:19:28 +08:00
jwangyangls
987da4212d
Merge pull request #9559 from jwangyangls/fix-immutable-bug
Improve Immutable tag UI
2019-10-28 11:27:38 +08:00
Wenkai Yin(尹文开)
f007a62b04
Merge pull request #9588 from stonezdj/fix_ldap_group_sql
Fix User Group Search SQL error
2019-10-28 11:22:14 +08:00
Yogi_Wang
26381c93be Improve Immutable tag UI
Signed-off-by: Yogi_Wang <yawang@vmware.com>
2019-10-28 10:07:40 +08:00
jwangyangls
e8554b9d66
Merge pull request #9587 from jwangyangls/add-webhook-tests-1.10
Add webhook nightly case
2019-10-28 10:05:16 +08:00
He Weiwei
28e0c0693b Upgrade clair adapter to v1.0.0
1. Upgrade clair adapter to v1.0.0.
2. Make the clair adapter which installed by harbor immutable and using internal registry address.
3. Add support to build clair adapter image from binary.
4. Switch to ScannerPull action when make authorization for the scan request.

Signed-off-by: He Weiwei <hweiwei@vmware.com>
2019-10-26 17:25:36 +00:00
Steven Zou
eba1a01ac2
Merge pull request #9595 from steven-zou/fix/update_scanner_failure
property use_internal_addr can not be updated
2019-10-25 17:39:34 +08:00
jwangyangls
8d35d36537
Merge pull request #9552 from jwangyangls/add-ut
Add front ut in app
2019-10-25 15:45:13 +08:00
Wang Yan
20a867a13c
Merge pull request #9579 from wy65701436/fix-id
update immutable rule API
2019-10-25 15:43:08 +08:00
Steven Zou
9d0263fc9a property use_internal_addr can not be updated
- pick up `use_internal_addr` in the update API

Signed-off-by: Steven Zou <szou@vmware.com>
2019-10-25 15:35:43 +08:00