Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[NOTE] Missing "DELETE /policies/replication" API #32

Open
moooofly opened this issue Nov 8, 2018 · 0 comments
Open

[NOTE] Missing "DELETE /policies/replication" API #32

moooofly opened this issue Nov 8, 2018 · 0 comments
Assignees
Labels
note markdown some conclusions v1.6.0-66709daa

Comments

@moooofly
Copy link
Owner

moooofly commented Nov 8, 2018

by swagger file

image

by harborctl

[#963#root@ubuntu-1604 /go/src/github.com/moooofly/harborctl]$./harborctl policy replication get -i 18
==> GET https://localhost/api/policies/replication/18
<==
<== Rsp Status: 200 OK
<== Rsp Body: {
  "id": 18,
  "name": "sync-fifth-5th",
  "description": "fifth-5th",
  "filters": null,
  "replicate_deletion": false,
  "trigger": {
    "kind": "Scheduled",
    "schedule_param": {
      "type": "Weekly",
      "weekday": 1,
      "offtime": 0
    }
  },
  "projects": [
    {
      "project_id": 6,
      "owner_id": 1,
      "name": "temp_5",
      "creation_time": "2018-11-02T06:58:11Z",
      "update_time": "2018-11-02T06:58:11Z",
      "deleted": false,
      "owner_name": "",
      "togglable": false,
      "current_user_role_id": 0,
      "repo_count": 0,
      "metadata": {
        "public": "true"
      }
    }
  ],
  "targets": [
    {
      "id": 1,
      "endpoint": "http://11.11.11.22",
      "name": "fake endpoint",
      "username": "admin",
      "password": "",
      "type": 0,
      "insecure": true,
      "creation_time": "2018-11-07T14:42:31.876842Z",
      "update_time": "2018-11-07T14:42:31.876842Z"
    }
  ],
  "creation_time": "2018-11-08T06:06:14Z",
  "update_time": "2018-11-08T06:32:42.117608Z",
  "replicate_existing_image_now": false,
  "error_job_count": 1
}
[#964#root@ubuntu-1604 /go/src/github.com/moooofly/harborctl]$
[#965#root@ubuntu-1604 /go/src/github.com/moooofly/harborctl]$./harborctl policy replication delete -i 18
==> DELETE https://localhost/api/policies/replication/18
<==
<== Rsp Status: 200 OK
<== Rsp Body:
[#966#root@ubuntu-1604 /go/src/github.com/moooofly/harborctl]$
[#966#root@ubuntu-1604 /go/src/github.com/moooofly/harborctl]$./harborctl policy replication get -i 18
==> GET https://localhost/api/policies/replication/18
<==
<== Rsp Status: 404 Not Found
<== Rsp Body: policy 18 not found

[#967#root@ubuntu-1604 /go/src/github.com/moooofly/harborctl]$
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
note markdown some conclusions v1.6.0-66709daa
Projects
None yet
Development

No branches or pull requests

1 participant