Advertisement
Guest User

Untitled

a guest
Apr 23rd, 2024
30
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 3.36 KB | None | 0 0
  1. $ cat hello.html
  2. <head>
  3.     <body>
  4.         HELLO WORLD!
  5.     </body>
  6. </head>
  7. $ pulp file repository create --name static
  8. {
  9.   "pulp_href": "/pulp/api/v3/repositories/file/file/018f0aec-a274-7e6c-a41e-f965274dc45c/",
  10.   "pulp_created": "2024-04-23T12:27:11.349786Z",
  11.   "pulp_last_updated": "2024-04-23T12:27:11.380726Z",
  12.   "versions_href": "/pulp/api/v3/repositories/file/file/018f0aec-a274-7e6c-a41e-f965274dc45c/versions/",
  13.   "pulp_labels": {},
  14.   "latest_version_href": "/pulp/api/v3/repositories/file/file/018f0aec-a274-7e6c-a41e-f965274dc45c/versions/0/",
  15.   "name": "static",
  16.   "description": null,
  17.   "retain_repo_versions": null,
  18.   "remote": null,
  19.   "autopublish": false,
  20.   "manifest": "PULP_MANIFEST"
  21. }
  22. $ pulp file content upload --repository file:file:static --file ./hello.html --relative-path hello.html
  23. Started background task /pulp/api/v3/tasks/018f0aee-9bb1-70af-aa21-d31ac9ad3c06/
  24. .Done.
  25. {
  26.   "pulp_href": "/pulp/api/v3/repositories/file/file/018f0aec-a274-7e6c-a41e-f965274dc45c/versions/1/",
  27.   "pulp_created": "2024-04-23T12:29:21.380667Z",
  28.   "pulp_last_updated": "2024-04-23T12:29:21.698089Z",
  29.   "number": 1,
  30.   "repository": "/pulp/api/v3/repositories/file/file/018f0aec-a274-7e6c-a41e-f965274dc45c/",
  31.   "base_version": null,
  32.   "content_summary": {
  33.     "added": {
  34.       "file.file": {
  35.         "count": 1,
  36.         "href": "/pulp/api/v3/content/file/files/?repository_version_added=/pulp/api/v3/repositories/file/file/018f0aec-a274-7e6c-a41e-f965274dc45c/versions/1/"
  37.       }
  38.     },
  39.     "removed": {},
  40.     "present": {
  41.       "file.file": {
  42.         "count": 1,
  43.         "href": "/pulp/api/v3/content/file/files/?repository_version=/pulp/api/v3/repositories/file/file/018f0aec-a274-7e6c-a41e-f965274dc45c/versions/1/"
  44.       }
  45.     }
  46.   }
  47. }
  48. $ pulp file publication create --repository static
  49. Started background task /pulp/api/v3/tasks/018f0aee-eb45-7161-83ed-06075b16e706/
  50. .Done.
  51. {
  52.   "pulp_href": "/pulp/api/v3/publications/file/file/018f0aee-eba1-7109-ba74-cd022c129cb7/",
  53.   "pulp_created": "2024-04-23T12:29:41.154808Z",
  54.   "pulp_last_updated": "2024-04-23T12:29:41.908315Z",
  55.   "repository_version": "/pulp/api/v3/repositories/file/file/018f0aec-a274-7e6c-a41e-f965274dc45c/versions/1/",
  56.   "repository": "/pulp/api/v3/repositories/file/file/018f0aec-a274-7e6c-a41e-f965274dc45c/",
  57.   "distributions": [],
  58.   "manifest": "PULP_MANIFEST"
  59. }
  60. $ pulp file distribution create --name static --repository static --base-path static
  61. Started background task /pulp/api/v3/tasks/018f0aef-4e8f-79f6-9d38-9fe29d65e028/
  62. Done.
  63. {
  64.   "pulp_href": "/pulp/api/v3/distributions/file/file/018f0aef-4f54-7f1a-8918-4103fe1d6349/",
  65.   "pulp_created": "2024-04-23T12:30:06.677718Z",
  66.   "pulp_last_updated": "2024-04-23T12:30:06.677729Z",
  67.   "base_path": "static",
  68.   "base_url": "http://localhost:5001/pulp/content/static/",
  69.   "content_guard": null,
  70.   "hidden": false,
  71.   "pulp_labels": {},
  72.   "name": "static",
  73.   "repository": "/pulp/api/v3/repositories/file/file/018f0aec-a274-7e6c-a41e-f965274dc45c/",
  74.   "publication": null
  75. }
  76. $ http GET http://localhost:5001/pulp/content/static/hello.html
  77. HTTP/1.1 200 OK
  78. Accept-Ranges: bytes
  79. Connection: keep-alive
  80. Content-Length: 59
  81. Content-Type: text/html
  82. Date: Tue, 23 Apr 2024 12:30:43 GMT
  83. Etag: "17c8e88f34e51ccd-3b"
  84. Last-Modified: Tue, 23 Apr 2024 12:29:20 GMT
  85. Server: nginx/1.22.1
  86.  
  87. <head>
  88.     <body>
  89.         HELLO WORLD!
  90.     </body>
  91. </head>
  92.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement