AllForNothing
41dd5656e6
Upgrade api level to v2
...
Signed-off-by: AllForNothing <sshijun@vmware.com>
2020-02-26 10:13:34 +08:00
Wenkai Yin(尹文开)
b156c74f6a
Merge pull request #10831 from wy65701436/readonly-global
...
add readonly to beego middleware
2020-02-25 16:10:55 +08:00
wang yan
b336875ebf
add readonly to beego middleware
...
Signed-off-by: wang yan <wangyan@vmware.com>
2020-02-25 15:00:39 +08:00
Wenkai Yin(尹文开)
5f9c976e95
Merge pull request #10837 from heww/scan-api
...
feat(scan): add scan API in v2.0
2020-02-25 14:45:19 +08:00
Wenkai Yin(尹文开)
90d1c9f287
Merge pull request #10834 from ywk253100/200225_repo
...
Implement the API to get the specified repository
2020-02-25 14:39:52 +08:00
He Weiwei
55a21cd444
feat(scan): add scan API in v2.0
...
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-02-25 06:01:37 +00:00
jwangyangls
3174734473
Merge pull request #10819 from jwangyangls/add-ut-oci
...
Add copy artifact and update repo info and add ut
2020-02-25 12:43:04 +08:00
Wenkai Yin
bb3ff0d752
Implement the API to get the specified repository
...
Implement the API to get the specified repository
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-25 12:02:50 +08:00
Yogi_Wang
92f84f2aee
Add copy artifact and update repo info and add ut
...
Signed-off-by: Yogi_Wang <yawang@vmware.com>
2020-02-25 10:39:03 +08:00
Wenkai Yin(尹文开)
bf4d141a77
Merge pull request #10827 from reasonerjt/refresh-notary-test-data
...
Refresh notary test data
2020-02-25 08:08:27 +08:00
Daniel Jiang
340726f7d3
Refresh notary test data
...
Refresh the valid signature data before it's expired
Signed-off-by: Daniel Jiang <jiangd@vmware.com>
2020-02-24 19:46:17 +08:00
Wang Yan
948d45604c
Revise the GC job flow,
...
1, set harbor to readonly
2, select the candidate artifacts from Harbor DB.
3, call registry API(--delete-untagged=false) to delete manifest bases on the results of #2
4, clean keys of redis DB of registry, clean artifact trash and untagged from DB.
5, roll back readonly.
Signed-off-by: wang yan <wangyan@vmware.com>
2020-02-24 18:29:55 +08:00
Wenkai Yin
528f598268
Reimplement the registry client
...
This commit reimplements the registry client under directory src/pkg/registry and removes the useless code
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-24 14:36:26 +08:00
stonezdj(Daojun Zhang)
c2a77c2825
Merge pull request #10751 from ywk253100/200213_delete_useless
...
Remove dead code
2020-02-24 10:22:58 +08:00
Will Sun
ca871d0eb5
Merge pull request #10790 from AllForNothing/routing-modify
...
Improve routing and UI for artifact pages
2020-02-24 09:39:36 +08:00
Wenkai Yin(尹文开)
c446774d23
Merge pull request #10816 from reasonerjt/merge-art-mani-middleware
...
Merge artifactInfo and ManifestInfo
2020-02-24 08:10:32 +08:00
Daniel Jiang
46c72ae372
Merge artifactInfo and ManifestInfo
...
This commit gets rid of middleware info middleware, and make artifact
info the single source of truth in terms of the artifact a request
handles. Fixes #10574
Signed-off-by: Daniel Jiang <jiangd@vmware.com>
2020-02-23 18:07:19 +08:00
Wenkai Yin
bd204464f3
Remove dead code
...
Remove dead code
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-23 17:11:46 +08:00
Wenkai Yin
ab3aad4d50
Implement the resolver for CNAB
...
This commit introduces a new resolver to resolver metadata for CNAB
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-23 07:23:22 +08:00
He Weiwei
f36152a560
feat(vulnerability): assemble vulnerabilities info for artifact ( #10800 )
...
1. Assemble scan overview to artifact when scanner enabled in the
project of the artifact.
2. Set addition link for vulnerabilities to artifact when scanner
enabled in the project of the artifact.
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-02-22 13:29:58 +08:00
stonezdj
29aa59ff18
Move core/notifier to pkg/notifier
...
Update package reference in related components
Signed-off-by: stonezdj <stonezdj@gmail.com>
2020-02-22 11:05:27 +08:00
Wenkai Yin(尹文开)
f7d248b968
Merge pull request #10789 from ywk253100/200203_upgrade
...
Upgrade the artifact table
2020-02-21 21:24:34 +08:00
Wenkai Yin
9312b788dc
Upgrade the artifact table
...
Split the table artifact into artifact and tags, and populate related data
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-21 20:37:31 +08:00
He Weiwei
d1cef70cd1
refactor(scan,auth): remove bearer token auth support for scan job ( #10781 )
...
Harbor v2.0 has changed to use basic auth to pull image so remove bearer
token support for scan job
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-02-21 17:58:24 +08:00
AllForNothing
8bff170c89
Improve routing and UI for artifact pages
...
Signed-off-by: AllForNothing <sshijun@vmware.com>
2020-02-21 15:00:49 +08:00
He Weiwei
88fcacd4b7
feat(middleware): add blob middlewares ( #10710 )
...
1. Add middleware to record the accepted blob size for stream blob
upload.
2. Add middleware to create blob and associate it with project after blob upload
complete.
3. Add middleware to sync blobs, create blob for manifest and associate blobs
with the manifest after put manifest.
4. Add middleware to associate blob with project after mount blob.
5. Cleanup associations for the project when artifact deleted.
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-02-20 23:20:34 +08:00
Ziming
0bc32410f3
Merge pull request #10742 from bitsf/oci_tag_retention
...
requirement(oci) implement tag retention for oci
not include ChartClient yet
2020-02-20 20:31:49 +08:00
Wenkai Yin(尹文开)
86b3e47f81
Merge pull request #10733 from ywk253100/200213_copy_artifact
...
Implement copy artifact API
2020-02-20 17:31:26 +08:00
Wenkai Yin
c4d4850845
Implement copy artifact API
...
Copy artifact into the repository from the specified artifact
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-20 16:59:35 +08:00
Yogi_Wang
99d02a14f5
Fix issue from louis and improve artifact list
...
Signed-off-by: Yogi_Wang <yawang@vmware.com>
2020-02-20 10:15:33 +08:00
Wenkai Yin
1db0077096
Implement delete/update repository API
...
Implement delete/update repository API
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-20 08:39:26 +08:00
Ziming Zhang
94e23dc954
requirement(oci) implement tag retention for oci
...
Change-Id: Ib36660835d2666b35124e66254c33b5fc19aaf77
Signed-off-by: Ziming Zhang <zziming@vmware.com>
2020-02-20 00:43:20 +08:00
Wang Yan
22021a988e
Merge pull request #10753 from wy65701436/artifact-trash
...
add artifact trash manager
2020-02-19 19:14:48 +08:00
Steven Zou
f1374737f6
Merge pull request #10694 from danielpacak/feature/install_with_trivy
...
chore(install): Add --with-trivy arg to the installation script
2020-02-19 16:27:57 +08:00
Wang Yan
f160505686
add artifact trash manager
...
1, move the deleted artifact into trash
2, disable GC to delete the untagged manifest
Signed-off-by: wang yan <wangyan@vmware.com>
2020-02-19 14:52:58 +08:00
He Weiwei
4ad02de348
Scan reorganize ( #10735 )
...
* refactor(scan,scanner): move scan and scanner controllers to api pkg
Signed-off-by: He Weiwei <hweiwei@vmware.com>
* feat(scan-all-job): move artifacts query from job to notification
Move artifact query from scan all job to its notification handler to
ensure that the components in pkg will not call controllers in api.
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-02-19 12:21:54 +08:00
Daniel Pacak
1fbc3dcb39
refactor: Allow EnsureScanners to accept multiple scanner registrations
...
Signed-off-by: Daniel Pacak <pacak.daniel@gmail.com>
2020-02-18 17:31:26 +01:00
Daniel Pacak
93f05b3643
refactor(scanners): Allow RemoveImmutableScanners() to accept multiple endpoint URLs
...
Signed-off-by: Daniel Pacak <pacak.daniel@gmail.com>
2020-02-18 12:47:27 +01:00
Wenkai Yin
9d2f1d4d66
Refactor the logic of deleting artifact
...
Delete the child artifacts along with the parent when deleting an artifact
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-18 16:20:17 +08:00
Wenkai Yin
c8c944c6e8
Move the scan overview populating logic to API handler
...
Move the scan overview populating logic to API handler to avoid importing cycle
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-18 13:34:08 +08:00
Wenkai Yin(尹文开)
560dd8ce7b
Merge pull request #10745 from reasonerjt/artifact-signature-populate-v2
...
Artifact signature populate
2020-02-18 13:24:55 +08:00
jwangyangls
360e342d56
Merge pull request #10719 from jwangyangls/oci-master-1
...
Oci ui include artifact list and artifact summary
2020-02-18 13:04:59 +08:00
Yogi_Wang
2553ee3831
Oci ui include artifact list and artifact summary
...
Signed-off-by: Yogi_Wang <yawang@vmware.com>
Signed-off-by: AllForNothing <sshijun@vmware.com>
Signed-off-by: Yogi_Wang <yawang@vmware.com>
2020-02-18 12:37:03 +08:00
Wenkai Yin(尹文开)
341cb88cba
Merge pull request #10727 from ywk253100/200214_bump_up_legacy_api_version
...
Bump up legacy api version to v2.0
2020-02-18 10:37:25 +08:00
Daniel Jiang
5a6e9331fd
Artifact signature populate ( #7 )
...
* Populate signature status in artifact API
This Commit add signature status into response of list artifact API.
Signed-off-by: Daniel Jiang <jiangd@vmware.com>
2020-02-18 01:42:56 +08:00
Wang Yan
e5eb711827
Merge pull request #10720 from wy65701436/chart-details
...
Get addition properties for chart
2020-02-17 13:36:24 +08:00
wang yan
8029f70ae5
Get addition properties for chart
...
1, Get readme.md content into addition
2, Get dependency of chart
3, Get values of chart
Signed-off-by: wang yan <wangyan@vmware.com>
2020-02-17 12:19:10 +08:00
Wenkai Yin(尹文开)
d7903fcf1b
Merge pull request #10682 from ywk253100/200126_label
...
Support add/remove label to/from artifact
2020-02-17 11:33:45 +08:00
Wenkai Yin
eceb9b2345
Fix bugs when pushing image(with index) and CNAB
...
1. As "List" method of artifact DAO doesn't return the artifacts that referenced by other and without tag, so we introduce a new method "GetByDigest" to check the existence of artifact
2. The "Www-Authenticate" header is needed to be returned when the request is unauthorized. This is required in the OCI distribution spec and is needed when pushing CNAB
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-14 15:24:14 +08:00
AllForNothing
121314358a
Switch APIs to v2.0
...
Signed-off-by: AllForNothing <sshijun@vmware.com>
2020-02-14 13:16:31 +08:00
Wenkai Yin
94787ea60d
Bump up the version of legacy APIs to v2.0
...
Bump up the version of legacy APIs to v2.0
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-14 13:16:30 +08:00
Daniel Pacak
fdf70f5dc9
refactor: Use if/else statements
...
Signed-off-by: Daniel Pacak <pacak.daniel@gmail.com>
2020-02-13 16:26:06 +01:00
Daniel Pacak
5f110c800a
feat: Initialize scanner registrations properly
...
Signed-off-by: Daniel Pacak <pacak.daniel@gmail.com>
2020-02-13 14:02:04 +01:00
Wenkai Yin
93731eeb2e
Support add/remove label to/from artifact
...
This commit add supporting for adding/removing label to/from artifacts and populates labels when listing artifacts
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-13 10:46:23 +08:00
Daniel Pacak
a642667ffc
chore(install): Add --with-trivy arg to the installation script
...
Signed-off-by: Daniel Pacak <pacak.daniel@gmail.com>
2020-02-12 23:47:56 +01:00
He Weiwei
75bbf9d0bf
fix(middleware): escape and clean path for the skipper ( #10674 )
...
1. Escape and clean request path for `legacyAPISkipper`.
2. Escape and clean request path for `MethodAndPathSkipper`.
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-02-11 22:29:55 +08:00
Wenkai Yin(尹文开)
d66c1a4a21
Merge pull request #10612 from ywk253100/200202_replication_basic_auth
...
Do enhancement for the registry authorizer
2020-02-11 22:09:40 +08:00
Wenkai Yin
a4ebbc6ecf
Do enhancement for the registry authorizer
...
This commit introduces a new wrapper authorizer which can authorize the request according to the auth scheme automatically
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-11 21:21:49 +08:00
Will Sun
647f11f26b
Merge pull request #10688 from AllForNothing/relative
...
UI should use relative path for back-end APIs
2020-02-11 18:06:42 +08:00
Daniel Jiang
9fb676c219
Fix nilpointer issue in v2 auth middleware
...
Signed-off-by: Daniel Jiang <jiangd@vmware.com>
2020-02-11 15:49:39 +08:00
Wang Yan
582fac5dae
Merge pull request #10687 from wy65701436/fix-catalog
...
fix catalog pagination issue
2020-02-11 10:40:35 +08:00
He Weiwei
c4f77069c8
Hide projects in global logs where user has limited guest role ( #10639 )
...
Signed-off-by: Mark Huang <mhuang@pivotal.io>
Co-authored-by: Mark Huang <mhuang@pivotal.io>
2020-02-11 10:14:30 +08:00
Wang Yan
e68b474dbc
Merge pull request #10581 from ywk253100/100123_list_artifact
...
Add query string to listing artifact API to support specify only show the tagged artifacts
2020-02-10 18:12:06 +08:00
wang yan
beb7664b33
fix catalog pagenation issue
...
Signed-off-by: wang yan <wangyan@vmware.com>
2020-02-10 18:03:33 +08:00
Wang Yan
65dc54b059
Merge pull request #10626 from ywk253100/200125_handle_error
...
Unify the method/style to handle error in handler/middleware
2020-02-10 17:47:12 +08:00
AllForNothing
c932ca9d2b
UI should use relative path for back-end APIs
...
Signed-off-by: AllForNothing <sshijun@vmware.com>
2020-02-10 15:37:09 +08:00
Wenkai Yin
0373e08e58
Add query string to listing artifact API to support specify only show the tagged artifacts
...
Specify the query string "tags=NOT_NULL" to the listing artifact API to only return the tagged artifacts
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-10 14:53:51 +08:00
Wang Yan
71414a9bc3
Merge pull request #10670 from wy65701436/upgrade-beego-12.1
...
update beego version to v1.12.1
2020-02-10 13:57:07 +08:00
wy65701436
b2e3761f62
update beego version to v1.12.1
...
Signed-off-by: wang yan <wangyan@vmware.com>
2020-02-09 16:39:48 +08:00
Wenkai Yin
af4dd142bc
Unify the method/style to handle error in handler/middleware
...
This commit provides a "SendError" method to unify the way to handle error in handlers/middlewares
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-08 07:37:00 +08:00
Wenkai Yin
0f6057a22c
Implement get addition API for image
...
This commit implements the API to get build history of image with manifest version 2 and populates the addition links when listing/getting the artifact
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-07 20:21:38 +08:00
Wenkai Yin(尹文开)
8a74fcb074
Merge pull request #10652 from wy65701436/fix-10552
...
Use controller rather than manager in the API handler and middleware
2020-02-07 19:30:51 +08:00
Wang Yan
6bad9f62ba
Merge pull request #10662 from ywk253100/200206_delete_repo
...
Implement repository deletion API
2020-02-07 17:51:03 +08:00
Wang Yan
5679c174c6
Merge pull request #10643 from ywk253100/200204_auth
...
Add permission check for artifact related APIs
2020-02-07 11:25:37 +08:00
wang yan
0fbbd674c2
Use controller rather than manager in the API handler and middleware
...
Signed-off-by: wang yan <wangyan@vmware.com>
2020-02-07 11:23:17 +08:00
Wenkai Yin
c267aaa474
Implement repository deletion API
...
Implement repository deletion API based on the new design
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-07 09:36:35 +08:00
Wang Yan
72f9e02dd9
Merge pull request #10628 from wy65701436/af-immu
...
set the immutable status on getting/listting tag
2020-02-05 21:03:29 +08:00
wang yan
596a6261ca
set the immutable status on getting/listting tag
...
Signed-off-by: wang yan <wangyan@vmware.com>
2020-02-05 16:24:13 +08:00
Wenkai Yin
6087647895
Add permission check for artifact related APIs
...
Add permission check for artifact related APIs
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-05 15:58:39 +08:00
Wenkai Yin(尹文开)
260d43db4f
Merge pull request #10627 from ywk253100/200202_reference
...
Add child artifact digest in reference model
2020-02-05 13:31:12 +08:00
wang yan
a53df4863d
fix issue on listing robot accounts
...
Update the query FuzzyMatch when to list robot accounts per project
Signed-off-by: wang yan <wangyan@vmware.com>
2020-02-05 11:36:18 +08:00
Wenkai Yin
7930e4f38a
Add child artifact digest in reference model
...
As we only provide the API to get artifact information via project name, repository name and digest, the digest of child artifact must be returned
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-04 15:59:06 +08:00
Wenkai Yin
c1746cc675
Update the method called by registry handler
...
Use ListTags instead in the registry tag listing handler
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-04 15:16:28 +08:00
Wang Yan
fa41168e8e
Merge pull request #10587 from ywk253100/200122_route
...
Register registry handler with the new methods of Route
2020-02-04 14:28:15 +08:00
Wenkai Yin(尹文开)
26ade207d3
Merge pull request #10588 from ywk253100/200126_delete_get_artifact
...
Implement artifact/tag related API
2020-02-04 14:14:28 +08:00
Wenkai Yin
793b23a444
Implement artifact/tag related API
...
Implement APIs:
1. Get artifact
2. Delete artifact
3. Create tag
4. Delete tag
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-04 13:46:55 +08:00
He Weiwei
791439086d
feat(api,permission): add HasPermission, HasProjectPermission in BaseAPI ( #10618 )
...
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-02-04 08:42:00 +08:00
He Weiwei
b1437c1341
refactor(security): add NewContext
and FromContext
to security pkg ( #10617 )
...
1. Add `NewContext` and `FromContext` funcs in security pkg.
2. Add `Name` func in `security.Context` interface to make the checking
for the `/api/internal/configurations` API clear.
3. Get the security from the context to prepare change the security
filter to middleware.
4. Remove `GetSecurityContext` in filter pkg.
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-02-03 17:43:36 +08:00
Wenkai Yin
ef3af85a5b
Register registry handler with the new methods of Route
...
Register registry handler with the new methods of Route
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-02-03 16:55:08 +08:00
Wang Yan
9c0d400817
Merge pull request #10549 from wy65701436/middleware-pc
...
add Middleware policycheck into v2 handler
2020-02-03 15:58:45 +08:00
Will Sun
acfcd2d175
Merge pull request #10489 from AllForNothing/postinstall
...
Fix postinstall script in Docker
2020-02-03 14:13:12 +08:00
wang yan
661f7a7902
resolve conflict with latest code
...
Signed-off-by: wang yan <wangyan@vmware.com>
2020-02-03 10:34:09 +08:00
Daniel Jiang
2064a1cd6d
Switch to basic authentication for registry
...
1. Add basic authorizer for registry which modify the request
to add basic authorization header to request based on configuration.
2. Set basic auth header for proxy when accessing registry
3. Switche the registry to use basic auth by default and use the basic
authorizer to access Harbor.
4. Make necessary change to test cases, particularly
"test_robot_account.py" and "docker_api.py", because the error is
changed after siwtched to basic auth from token auth. #10604 is opened
to track the follow up work.
Signed-off-by: Daniel Jiang <jiangd@vmware.com>
2020-01-31 21:46:47 +09:00
Wenkai Yin(尹文开)
a1b25e1fec
Switch to new registry API handlers ( #10596 )
...
Switch to new registry API handlers
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-30 21:21:07 +08:00
Wenkai Yin
d0ac70d26c
Implement the get/delete handler for registry API
...
Implement the get/delete handler for registry API
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-28 11:01:17 +08:00
Wang Yan
9db84f2880
add Middleware policycheck into v2 handler
...
1, add content trust middleware in new v2 handler
2, add vulnable middlware in new v2 hanlder
Signed-off-by: wang yan <wangyan@vmware.com>
2020-01-28 00:24:58 +09:00
Daniel Jiang
5f8acc3896
Add middlewares for permission checking for v2 API
...
When the registry shifts from token auth to basic auth, we'll use the middleware to check permission.
This commit add middlewares for populate the artifact info and check
permission based on request to /v2/* api via security context
Signed-off-by: Daniel Jiang <jiangd@vmware.com>
2020-01-27 12:53:15 +08:00
He Weiwei
b594861658
feat(middleware): add transaction middleware for v2 and v2.0 APIs
...
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-01-22 05:00:39 +00:00
Wenkai Yin(尹文开)
f9d8951aed
Merge pull request #10519 from ywk253100/200116_router
...
Wrap the beego router and provide a unified view for users to register routes
2020-01-22 10:20:36 +08:00
Wenkai Yin(尹文开)
a774a19823
Merge pull request #10537 from ywk253100/200115_artifact_api
...
Implement the listing artifact API
2020-01-22 08:05:12 +08:00
Wenkai Yin
19f4bad042
Implement the listing artifact API
...
Implement the listing artifact API
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-22 07:35:29 +08:00
Wenkai Yin(尹文开)
17318aedc3
Merge pull request #10547 from ywk253100/200120_artifact
...
Add foreign key to avoid the concurrent issue
2020-01-21 17:44:27 +08:00
Wenkai Yin
8aeabc7717
Wrap the beego router and provide a unified view for users to register routes
...
Wrap the beego router and provide a unified view for users to register routes
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-21 17:26:20 +08:00
Wenkai Yin
7dc28bcff9
Add foreign key to avoid the concurrent issue
...
Add foreign key to avoid the concurrent issue when operating the artifacts, tags and references
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-21 16:03:51 +08:00
Wenkai Yin(尹文开)
8b3313a1ce
Merge pull request #10525 from ywk253100/200117_chart_resolver
...
Implement the resolver for helm chart
2020-01-21 15:12:57 +08:00
Wenkai Yin(尹文开)
4dc59c5e39
Merge pull request #10541 from ywk253100/200120_default_resolver
...
Try to parse the type of the artifact based on the media type when no resolver found
2020-01-21 14:41:35 +08:00
Wenkai Yin
f759c8fd64
Implement the resolver for helm chart
...
Implement the resolver for helm chart
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-21 14:38:53 +08:00
Wenkai Yin
1f3fcbde36
Try to parse the type of the artifact based on the media type when no resolver found
...
Try to parse the type of the artifact based on the media type when no resolver found, if parse failed, set it's type to unknown. This won't block the pushing for artifacts that has no resolver registered in Harbor
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-21 14:15:33 +08:00
wang yan
8fae15b803
add immutable tag middleware into new v2 handler
...
Signed-off-by: wang yan <wangyan@vmware.com>
2020-01-20 22:41:08 +08:00
Steven Zou
e8a617e0bd
Merge pull request #10429 from steven-zou/fix/job_hung_issue
...
fix[jobservice]:job status is hung after restart
2020-01-20 16:46:22 +08:00
He Weiwei
33dfa1ea11
feat(beego): upgrade beego to v1.12 which support middleware ( #10524 )
...
1. Upgrade beego to v1.12.0
2. Add RequestID middleware to all HTTP requests.
3. Add Orm middleware to v2 and v2.0 APIs.
4. Remove OrmFilter from all HTTP requests.
5. Fix some test cases which cause panic in API controllers.
6. Enable XSRF for test cases of CommonController.
7. Imporve ReadOnly middleware.
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-01-20 16:41:49 +08:00
Wenkai Yin(尹文开)
603cc0f5f3
Merge pull request #10526 from heww/send-error
...
feat(swagger): implement SendError for BaseAPI handler
2020-01-20 14:51:01 +08:00
wang yan
7ebb337e3f
add regtoken middleware in new v2 handler
...
To move the regtoken middlware to new v2 handler framework, it parses the docker pull bearer token and check whether it's a scanner pull.
Signed-off-by: wang yan <wangyan@vmware.com>
2020-01-20 11:02:10 +08:00
Wang Yan
63ef743ba7
Merge pull request #10482 from wy65701436/api-list-repo
...
add code for catalog and list tag API
2020-01-19 15:26:13 +08:00
wang yan
986989af3c
add code for catalog and list tag API
...
Signed-off-by: wang yan <wangyan@vmware.com>
2020-01-19 13:00:02 +08:00
wang yan
bffbc4009b
add get manifest information middleware in new v2 hanlder
...
To add a new middleware to resolve the manifest information from request path, then pass
it into the request context for later use.
Signed-off-by: wang yan <wangyan@vmware.com>
2020-01-19 12:31:38 +08:00
He Weiwei
5daa3f4fb3
feat(swagger): implement SendError for BaseAPI handler
...
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-01-19 00:46:18 +00:00
Wenkai Yin(尹文开)
8809b7aa5d
Merge pull request #9887 from chlins/fix/replication-huawei-adapter-authorization
...
fix(replication): huawei adapter multi authorization
2020-01-17 19:04:52 +08:00
Wang Yan
2ea41ca78a
Merge pull request #10481 from ywk253100/200114_orm
...
Get the ormer from context instead of creating a new one
2020-01-17 17:54:00 +08:00
Wang Yan
a27a5986ab
Merge pull request #10448 from ywk253100/200111_index
...
Implement the index/manifest list image resolver
2020-01-17 14:39:01 +08:00
Wenkai Yin(尹文开)
6e3733aa7f
Merge pull request #10490 from wy65701436/middleware-readonly
...
move readonly middleware to new v2 handler
2020-01-17 14:09:20 +08:00
Daniel Jiang
a200947666
Merge pull request #10449 from ywk253100/200111_manifest_v1
...
Implement the manifest v1 image resolver
2020-01-17 11:13:50 +08:00
wang yan
935303a476
move readonly middleware to new v2 handler
...
Signed-off-by: wang yan <wangyan@vmware.com>
2020-01-17 11:12:10 +08:00
sshijun
3175d5f646
Fix postinstall script in Docker
...
Signed-off-by: sshijun <sshijun@vmware.com>
2020-01-15 16:28:57 +08:00
Will Sun
a49c0640fd
Merge pull request #10434 from AllForNothing/swagger
...
Add ng-swagger-gen to automatically generate models and services with swagger.yaml
2020-01-14 17:58:32 +08:00
Wenkai Yin(尹文开)
4f3024191b
Merge pull request #10458 from ywk253100/20013_middleware
...
Provide a util function to apply middlewares to handler
2020-01-14 17:11:59 +08:00
Wenkai Yin
ff1a03cccc
Get the ormer from context instead of creating a new one
...
This commit updates the dao methods with the ormer got from context
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-14 16:35:36 +08:00
Will Sun
88e6b0a743
Merge pull request #10443 from AllForNothing/express
...
Add express module
2020-01-14 15:22:23 +08:00
sshijun
679a6e0b05
Add ng-swagger-gen to automatically generate models and services with
...
swagger.yaml
Signed-off-by: sshijun <sshijun@vmware.com>
2020-01-14 15:18:32 +08:00
Will Sun
a3e84380fa
Merge pull request #10436 from AllForNothing/nightly
...
Improve tag-retention and project search function
2020-01-14 13:54:40 +08:00
Wenkai Yin(尹文开)
7e8bc0173d
Merge pull request #10390 from heww/gen-apis
...
feat(swagger): generate apis v2.0 from swagger.yaml
2020-01-14 13:39:59 +08:00
sshijun
95287db4b5
Improve tag-retention and project search function
...
Signed-off-by: sshijun <sshijun@vmware.com>
Improve tag-retention and project search function
Signed-off-by: sshijun <sshijun@vmware.com>
2020-01-14 13:26:30 +08:00
He Weiwei
c729e3b9e0
feat(swagger): generate apis v2.0 from swagger.yaml
...
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-01-14 02:20:18 +00:00
Wenkai Yin
c5cc7cf49e
Provide a util function to apply middlewares to handler
...
Provide a util function to apply middlewares to handler
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-13 19:27:00 +08:00
Ziming Zhang
ed3bf041e2
fix(replication): aws ecr delete image
...
Signed-off-by: Ziming Zhang <zziming@vmware.com>
Change-Id: I5e38b813c2840e0270973c38680cb8f815e5ece9
Signed-off-by: Ziming Zhang <zziming@vmware.com>
2020-01-13 10:58:13 +08:00
Wenkai Yin
e91dbea76d
Implement the manifest v1 image resolver
...
The manifest v1 image resolver populates the architecture info into the artifact
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-11 16:33:02 +08:00
Wenkai Yin
40d5043d5c
Implement the index/manifest list image resolver
...
The index/manifest list image resolver populates the references of the artifact
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-11 16:02:16 +08:00
Wenkai Yin
df551e1310
Implement the artifact abstractor and resolver
...
1. Define the interface for artifact abstractor and resolver
2. Implement the artifact abstractor
3. Implement the resolver for image with manifest v2
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-11 15:09:08 +08:00
sshijun
8afc524adb
Add express module
...
Signed-off-by: sshijun <sshijun@vmware.com>
2020-01-10 16:21:16 +08:00
Steven Zou
e899d659f3
fix[jobservice]:job status is hung after restart
...
- improve the status hook sending/resending approach
- improve the status compare and set approach
- simplify the relevant flow
- add reaper to fix the out of sync jobs
- fix #10244 , fix #9963
Signed-off-by: Steven Zou <szou@vmware.com>
2020-01-09 17:10:35 +08:00
jwangyangls
fb82cd6bd1
Merge pull request #10412 from jwangyangls/refactor-styles.css
...
Refactor styles.css
2020-01-09 17:06:48 +08:00
Qian Deng
ceb4bbf849
Merge pull request #10394 from heww/cherry-pick-pr-10393
...
[Cherry pick]fix(scanner): use new created ormer for transaction
2020-01-09 14:29:47 +08:00
Wenkai Yin(尹文开)
1ea9e68178
Merge pull request #10366 from ywk253100/191219_manager
...
Implement tag/artifact manager and artifact controller
2020-01-08 21:24:52 +08:00
Wenkai Yin
400a47a5c5
Implement tag/artifact manager and artifact controller
...
1. Implement tag/artifact manager
2. Implement artifact controller
3. Onboard the artifact when pushing artifacts
Signed-off-by: Wenkai Yin <yinw@vmware.com>
2020-01-08 20:19:48 +08:00
Will Sun
593b99d1c1
Merge pull request #10408 from AllForNothing/modify-project-tab1
...
Add more UT
2020-01-07 18:05:54 +08:00
Yogi_Wang
2308519596
Refactor styles.css
...
1.refactor styles.css
2.modify theme mode
3.fix bug #9939
Signed-off-by: Yogi_Wang <yawang@vmware.com>
2020-01-07 14:37:26 +08:00
sshijun
fc78aeacc9
Add more UT
...
Signed-off-by: sshijun <sshijun@vmware.com>
2020-01-07 09:23:33 +08:00
wang yan
a0f3709b3c
add expiration data time when to create a robot account
...
Update API of creating robot accout, user can specify expiration time per account.
Signed-off-by: wang yan <wangyan@vmware.com>
2020-01-03 13:47:06 +08:00
He Weiwei
b90ac468c5
fix(scanner): use new created ormer for transaction
...
Use new created ormer for transaction in SetDefaultRegistration
Closes #10284
Signed-off-by: He Weiwei <hweiwei@vmware.com>
2020-01-03 05:25:32 +00:00
Will Sun
76dcedb4f3
Merge pull request #10375 from AllForNothing/more-ut-v2
...
Add more UT for project-quota-component
2020-01-02 13:43:56 +08:00