Compare commits

..

8 Commits

Author SHA1 Message Date
054585c7f5 1.2.0 2024-06-08 15:03:20 +02:00
c0cebbe614 feat(imagestore): now processing images with extraction, retagging, repackaging and long term storage 2024-06-08 15:03:19 +02:00
740f83114c 1.1.4 2024-06-06 00:32:51 +02:00
e48023d490 fix(core): update 2024-06-06 00:32:50 +02:00
eaaf313442 1.1.3 2024-06-06 00:25:40 +02:00
68b2baadae fix(core): update 2024-06-06 00:25:39 +02:00
6743dc35e7 1.1.2 2024-06-06 00:14:31 +02:00
bbf265716d fix(core): update 2024-06-06 00:14:30 +02:00
14 changed files with 462 additions and 94 deletions

View File

@ -1,6 +1,6 @@
{
"name": "@apiclient.xyz/docker",
"version": "1.1.1",
"version": "1.2.0",
"description": "Provides easy communication with Docker remote API from Node.js, with TypeScript support.",
"private": false,
"main": "dist_ts/index.js",
@ -34,16 +34,18 @@
"homepage": "https://gitlab.com/mojoio/docker#readme",
"dependencies": {
"@push.rocks/lik": "^6.0.15",
"@push.rocks/smartarchive": "^4.0.22",
"@push.rocks/smartfile": "^11.0.16",
"@push.rocks/smartarchive": "^4.0.36",
"@push.rocks/smartbucket": "^3.0.10",
"@push.rocks/smartfile": "^11.0.20",
"@push.rocks/smartjson": "^5.0.20",
"@push.rocks/smartlog": "^3.0.6",
"@push.rocks/smartlog": "^3.0.7",
"@push.rocks/smartnetwork": "^3.0.0",
"@push.rocks/smartpath": "^5.0.18",
"@push.rocks/smartpromise": "^4.0.3",
"@push.rocks/smartrequest": "^2.0.22",
"@push.rocks/smartstream": "^3.0.44",
"@push.rocks/smartstring": "^4.0.15",
"@push.rocks/smartunique": "^3.0.9",
"@push.rocks/smartversion": "^3.0.5",
"@tsclass/tsclass": "^4.0.54",
"rxjs": "^7.5.7"
@ -53,7 +55,7 @@
"@git.zone/tsrun": "^1.2.12",
"@git.zone/tstest": "^1.0.90",
"@push.rocks/tapbundle": "^5.0.23",
"@types/node": "20.14.1"
"@types/node": "20.14.2"
},
"files": [
"ts/**/*",

356
pnpm-lock.yaml generated
View File

@ -12,17 +12,20 @@ importers:
specifier: ^6.0.15
version: 6.0.15
'@push.rocks/smartarchive':
specifier: ^4.0.22
version: 4.0.22
specifier: ^4.0.36
version: 4.0.36
'@push.rocks/smartbucket':
specifier: ^3.0.10
version: 3.0.10
'@push.rocks/smartfile':
specifier: ^11.0.16
version: 11.0.16
specifier: ^11.0.20
version: 11.0.20
'@push.rocks/smartjson':
specifier: ^5.0.20
version: 5.0.20
'@push.rocks/smartlog':
specifier: ^3.0.6
version: 3.0.6
specifier: ^3.0.7
version: 3.0.7
'@push.rocks/smartnetwork':
specifier: ^3.0.0
version: 3.0.2
@ -41,6 +44,9 @@ importers:
'@push.rocks/smartstring':
specifier: ^4.0.15
version: 4.0.15
'@push.rocks/smartunique':
specifier: ^3.0.9
version: 3.0.9
'@push.rocks/smartversion':
specifier: ^3.0.5
version: 3.0.5
@ -56,19 +62,22 @@ importers:
version: 2.1.80
'@git.zone/tsrun':
specifier: ^1.2.12
version: 1.2.46(@types/node@20.14.1)
version: 1.2.46(@types/node@20.14.2)
'@git.zone/tstest':
specifier: ^1.0.90
version: 1.0.90(@types/node@20.14.1)
version: 1.0.90(@types/node@20.14.2)
'@push.rocks/tapbundle':
specifier: ^5.0.23
version: 5.0.23
'@types/node':
specifier: 20.14.1
version: 20.14.1
specifier: 20.14.2
version: 20.14.2
packages:
'@api.global/typedrequest-interfaces@2.0.2':
resolution: {integrity: sha512-D+mkr4IiUZ/eUgrdp5jXjBKOW/iuMcl0z2ZLQsLLypKX/psFGD3viZJ58FNRa+/1OSM38JS5wFyoWl8oPEFLrw==}
'@api.global/typedrequest-interfaces@3.0.19':
resolution: {integrity: sha512-uuHUXJeOy/inWSDrwD0Cwax2rovpxYllDhM2RWh+6mVpQuNmZ3uw6IVg6dA2G1rOe24Ebs+Y9SzEogo+jYN7vw==}
@ -335,12 +344,15 @@ packages:
'@push.rocks/lik@6.0.15':
resolution: {integrity: sha512-rZxln6l4NAU931MTxnsjy1pue+S3AXtDCidHH/tbkqBtrWIzWuXduo6Nz3zYkndbD64Knyta7F60JRvcOe4XqA==}
'@push.rocks/smartarchive@4.0.22':
resolution: {integrity: sha512-8bj+J962edFUgdNh/951gkOD3gjQHgbwvMFxePWbJm5hXM9MOH7VgWA8XeNBUMnHrEHAlx/D5VYe1qulxF8lEA==}
'@push.rocks/smartarchive@4.0.36':
resolution: {integrity: sha512-zFd0xKK2TsE/mOxsxp4MrAmH9skFOJijMG0VuHjkYB5WRspvoaOssMypiILCXy/m7vEhqAVGmgrk8Ed0p4gDMQ==}
'@push.rocks/smartbrowser@2.0.6':
resolution: {integrity: sha512-Ne+KCVhV/DROc1rHRRw59K6h0+LpQAK9fdOUtgDZ7laLPmB/tmnbUh3IuRDNcIY1iVA9pydoobwjnTjVgio9eQ==}
'@push.rocks/smartbucket@3.0.10':
resolution: {integrity: sha512-KzEDWtrZbs5gD042LGa61jtIgOz6+MmQIIccPO0d2YQRNpgrO+CAAKyhOHgvWaPPTlaj72XGM8pBhn/2hCdSUA==}
'@push.rocks/smartbuffer@3.0.4':
resolution: {integrity: sha512-TLfhx/JD61YC8XGO9TI6Ux6US38R14HaIM84QT8hZZod8axfXrg+h8xA8tMUBpSV8PXsQy9LzxmOq0Il1fmDXw==}
@ -377,8 +389,8 @@ packages:
'@push.rocks/smartfile@10.0.41':
resolution: {integrity: sha512-xOOy0duI34M2qrJZggpk51EHGXmg9+mBL1Q55tNiQKXzfx89P3coY1EAZG8tvmep3qB712QEKe7T+u04t42Kjg==}
'@push.rocks/smartfile@11.0.16':
resolution: {integrity: sha512-tl0IJj1mWqNUkqZLjlFKR0OEixhX8cafws7WcxuhNZymkK9axo03O9DiFbUZb4XUbcfYaYNWGTqHUyppWpwRHQ==}
'@push.rocks/smartfile@11.0.20':
resolution: {integrity: sha512-gJERlNE2fNah9HLq6W3srcl1GZwlz2vFVZRmb50TQLabmWF4qyTlaMYAwY8ffgf8np4TsHAa4s+kL5F0zUfUUg==}
'@push.rocks/smarthash@3.0.4':
resolution: {integrity: sha512-HJ/fSx41jm0CvSaqMLa6b2nuNK5rHAqAeAq3dAB7Sq9BCPm2M0J5ZVDTzEAH8pS91XYniUiwuE0jwPERNn9hmw==}
@ -395,8 +407,11 @@ packages:
'@push.rocks/smartlog-interfaces@3.0.0':
resolution: {integrity: sha512-dfRqiSolGQwaF9gWmkixWOoXZxcWBjK3u6A1CpcfhCbVr2VSUMIrZ5t74/DgdfedsTrhDqoD0NGezsMXF2pFHQ==}
'@push.rocks/smartlog@3.0.6':
resolution: {integrity: sha512-HvZtgur6PY+n6skw5Jx+KWwHciCiWNm+WNLkqRreuLXJrWKknwYvy/Ea+f61RqJBHEkOYTYxRoddBuC+6HAoWw==}
'@push.rocks/smartlog-interfaces@3.0.2':
resolution: {integrity: sha512-8hGRTJehbsFSJxLhCQkA018mZtXVPxPTblbg9VaE/EqISRzUw+eosJ2EJV7M4Qu0eiTJZjnWnNLn8CkD77ziWw==}
'@push.rocks/smartlog@3.0.7':
resolution: {integrity: sha512-WHOw0iHHjCEbYY4KGX40iFtLI11QJvvWIbC9yFn3Mt+nrdupMnry7Ztc5v/PqO8lu33Q6xDBMXiNQ9yNY0HVGw==}
'@push.rocks/smartmanifest@2.0.2':
resolution: {integrity: sha512-QGc5C9vunjfUbYsPGz5bynV/mVmPHkrQDkWp8ZO8VJtK1GZe+njgbrNyxn2SUHR0IhSAbSXl1j4JvBqYf5eTVg==}
@ -729,8 +744,8 @@ packages:
'@types/minimatch@5.1.2':
resolution: {integrity: sha512-K0VQKziLUWkVKiRVrx4a40iPaxTUefQmjtkQofBkYRcoaaL/8rhwDWww9qWbrgicNOgnpIsMxyNIUM4+n6dUIA==}
'@types/node@20.14.1':
resolution: {integrity: sha512-T2MzSGEu+ysB/FkWfqmhV3PLyQlowdptmmgD20C6QxsS8Fmv5SjpZ1ayXaEC0S21/h5UJ9iA6W/5vSNU5l00OA==}
'@types/node@20.14.2':
resolution: {integrity: sha512-xyu6WAMVwv6AKFLB+e/7ySZVr/0zLCzOa7rSpq6jNwpqOrUbcACDWC+53d4n2QHOnDou0fbIsg8wZu/sxrnI4Q==}
'@types/parse5@6.0.3':
resolution: {integrity: sha512-SuT16Q1K51EAVPz1K29DJ/sXjhSQ0zjvsypYJ6tlwVsRV9jwW5Adq2ch8Dq8kDBCkYnELS7N7VNCSB5nC56t/g==}
@ -821,6 +836,9 @@ packages:
resolution: {integrity: sha512-2hESALx/UFsAzK+ApWXAkFp2eCmwcs2yj1v4YjwV8F38sQumJ40P3px3BMjFwkOYDORtQOicW0RUeSw1g3BMLA==}
engines: {node: '>=18.0.0'}
'@zxing/text-encoding@0.9.0':
resolution: {integrity: sha512-U/4aVJ2mxI0aDNI8Uq0wEhMgY+u4CNtEb0om3+y3+niDAsoTCOB33UF0sxpzqzdqXLqmvc+vZyAt4O8pPdfkwA==}
accepts@1.3.8:
resolution: {integrity: sha512-PYAthTa2m2VKxuvSD3DPC/Gy+U+sOA1LAuT8mkmRuvw+NACSaeXEQ+NHcVF7rONl6qcaxV3Uuemwawk+7+SJLw==}
engines: {node: '>= 0.6'}
@ -904,9 +922,16 @@ packages:
resolution: {integrity: sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==}
engines: {node: '>=8'}
async@3.2.5:
resolution: {integrity: sha512-baNZyqaaLhyLVKm/DlvdW051MSgO6b8eVfIezl9E5PqWxFgzLm/wQntEW4zOytVburDEr0JlALEpdOFwvErLsg==}
asynckit@0.4.0:
resolution: {integrity: sha1-x57Zf380y48robyXkLzDZkdLS3k=}
available-typed-arrays@1.0.7:
resolution: {integrity: sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==}
engines: {node: '>= 0.4'}
axe-core@4.9.1:
resolution: {integrity: sha512-QbUdXJVTpvUTHU7871ppZkdOLBeGUKBQWHkHrvN2V9IQWGMt61zf3B45BtzjxEJzYuj0JBjBZP/hmYS/R9pmAw==}
engines: {node: '>=4'}
@ -934,6 +959,9 @@ packages:
bl@4.1.0:
resolution: {integrity: sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==}
block-stream2@2.1.0:
resolution: {integrity: sha512-suhjmLI57Ewpmq00qaygS8UgEq2ly2PCItenIyhMqVjo4t4pGzqMvfgJuX8iWTeSDdfSSqS6j38fL4ToNL7Pfg==}
body-parser@1.20.2:
resolution: {integrity: sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==}
engines: {node: '>= 0.8', npm: 1.2.8000 || >= 1.4.16}
@ -948,9 +976,16 @@ packages:
resolution: {integrity: sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==}
engines: {node: '>=8'}
browser-or-node@2.1.1:
resolution: {integrity: sha512-8CVjaLJGuSKMVTxJ2DpBl5XnlNDiT4cQFeuCJJrvJmts9YrTZDizTX7PjC2s6W4x+MBGZeEY6dGMrF04/6Hgqg==}
buffer-crc32@0.2.13:
resolution: {integrity: sha1-DTM+PwDqxQqhRUq9MO+MKl2ackI=}
buffer-crc32@1.0.0:
resolution: {integrity: sha512-Db1SbgBS/fg/392AblrMJk97KggmvYhr4pB5ZIMTWtaivCPMWLkmb7m21cJvpvgK+J3nsU2CmmixNBZx4vFj/w==}
engines: {node: '>=8.0.0'}
buffer-json@2.0.0:
resolution: {integrity: sha512-+jjPFVqyfF1esi9fvfUs3NqM0pH1ziZ36VP4hmA/y/Ssfo/5w5xHKfTw9BwQjoJ1w/oVtpLomqwUHKdefGyuHw==}
@ -1143,6 +1178,10 @@ packages:
supports-color:
optional: true
decode-uri-component@0.2.2:
resolution: {integrity: sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ==}
engines: {node: '>=0.10'}
decompress-response@6.0.0:
resolution: {integrity: sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==}
engines: {node: '>=10'}
@ -1288,6 +1327,9 @@ packages:
resolution: {integrity: sha1-Qa4u62XvpiJorr/qg6x9eSmbCIc=}
engines: {node: '>= 0.6'}
eventemitter3@5.0.1:
resolution: {integrity: sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==}
express-force-ssl@0.3.2:
resolution: {integrity: sha1-AbK0mK5v0uQRUrIrV6Phc3c69n4=}
engines: {node: '>=0.2.2'}
@ -1347,6 +1389,10 @@ packages:
resolution: {integrity: sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==}
engines: {node: '>=8'}
filter-obj@1.1.0:
resolution: {integrity: sha1-mzERErxsYSehbgFsbF1/GeCAXFs=}
engines: {node: '>=0.10.0'}
finalhandler@1.2.0:
resolution: {integrity: sha512-5uXcUVftlQMFnWC9qu/svkWv3GTd2PfUhK/3PLkYNAe7FbqJMt3515HaxE6eRL74GdsriiwujiawdaB1BpEISg==}
engines: {node: '>= 0.8'}
@ -1355,6 +1401,9 @@ packages:
resolution: {integrity: sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==}
engines: {node: '>=8'}
for-each@0.3.3:
resolution: {integrity: sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==}
foreground-child@2.0.0:
resolution: {integrity: sha512-dCIq9FpEcyQyXKCkyzmlPTFNgrCzPudOe+mhvJU5zAtlBnGVy2yKxtfsxK2tQBThwq225jcvBjpw1Gr40uzZCA==}
engines: {node: '>=8.0.0'}
@ -1558,10 +1607,22 @@ packages:
resolution: {integrity: sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==}
engines: {node: '>= 0.10'}
ipaddr.js@2.2.0:
resolution: {integrity: sha512-Ag3wB2o37wslZS19hZqorUnrnzSkpOVy+IiiDEiTqNubEYpYuHWIf6K4psgN2ZWKExS4xhVCrRVfb/wfW8fWJA==}
engines: {node: '>= 10'}
is-arguments@1.1.1:
resolution: {integrity: sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==}
engines: {node: '>= 0.4'}
is-binary-path@2.1.0:
resolution: {integrity: sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==}
engines: {node: '>=8'}
is-callable@1.2.7:
resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==}
engines: {node: '>= 0.4'}
is-docker@2.2.1:
resolution: {integrity: sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==}
engines: {node: '>=8'}
@ -1607,6 +1668,10 @@ packages:
resolution: {integrity: sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==}
engines: {node: '>=8'}
is-typed-array@1.1.13:
resolution: {integrity: sha512-uZ25/bUAlUY5fR4OKT4rZQEBrzQWYV9ZJYGGsUmEJ6thodVJ1HX64ePQ6Z0qPWP+m+Uq6e9UugrE38jeYsDSMw==}
engines: {node: '>= 0.4'}
is-unicode-supported@2.0.0:
resolution: {integrity: sha512-FRdAyx5lusK1iHG0TWpVtk9+1i+GjrzRffhDg4ovQ7mcidMQ6mj+MhKPmvh7Xwyv5gIS06ns49CA7Sqg7lC22Q==}
engines: {node: '>=18'}
@ -1652,8 +1717,8 @@ packages:
resolution: {integrity: sha512-N3yCS/NegsOBokc8GAdM8UcmfsKiSS8cipheD/nivzr700H+nsMOxJjQnvwOcRYVuFkdH0wGUvW2WbXGmrZGbQ==}
engines: {node: '>=14'}
jackspeak@3.2.3:
resolution: {integrity: sha512-htOzIMPbpLid/Gq9/zaz9SfExABxqRe1sSCdxntlO/aMD6u0issZQiY25n2GKQUtJ02j7z5sfptlAOMpWWOmvw==}
jackspeak@3.4.0:
resolution: {integrity: sha512-JVYhQnN59LVPFCEcVa2C3CrEKYacvjRfqIQl+h8oi91aLYQVWRYbxjPcv1bUiUy/kLmQaANrYfNMCO3kuEDHfw==}
engines: {node: '>=14'}
js-base64@3.7.7:
@ -1758,6 +1823,9 @@ packages:
lodash.restparam@3.6.1:
resolution: {integrity: sha1-k2pOMJ7zMKdkXtQUWYbIWuWyCAU=}
lodash@4.17.21:
resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==}
log-update@4.0.0:
resolution: {integrity: sha512-9fkkDevMefjg0mmzWFBW8YkFP91OrizzkW3diF7CpG+S2EYdy4+TVfGwz1zeF8x7hCx1ovSPTOE9Ngib74qqUg==}
engines: {node: '>=10'}
@ -1865,6 +1933,10 @@ packages:
resolution: {integrity: sha512-KqWh+VchfxcMNRAJjj2tnsSJdNbHsVgnkBhTNrW7AjVo6OvLtxw8zfT9oLw1JSohlFzJ8jCoTgaoXvJ+kHt6fw==}
engines: {node: '>=16 || 14 >=14.17'}
minio@8.0.0:
resolution: {integrity: sha512-GkM/lk+Gzwd4fAQvLlB+cy3NV3PRADe0tNXnH9JD5BmdAHKIp+5vypptbjdkU85xWBIQsa2xK35GpXjmYXBBYA==}
engines: {node: ^16 || ^18 || >=20}
minipass@7.1.0:
resolution: {integrity: sha512-oGZRv2OT1lO2UF1zUcwdTb3wqUwI0kBGTgt/T7OdSj6M6N5m3o5uPf0AIW6lVxGGoiWUR7e2AwTE+xiwK8WQig==}
engines: {node: '>=16 || 14 >=14.17'}
@ -2063,6 +2135,10 @@ packages:
resolution: {integrity: sha512-HRDzbaKjC+AOWVXxAU/x54COGeIv9eb+6CkDSQoNTt4XyWoIJvuPsXizxu/Fr23EiekbtZwmh1IcIG/l/a10GQ==}
engines: {node: '>=8'}
possible-typed-array-names@1.0.0:
resolution: {integrity: sha512-d7Uw+eZoloe0EHDIYoe+bQ5WXnGMOpmiZFTuMWCwpjzzkL2nTjcKiAk4hh8TjnGye2TwWOk3UXucZ+3rbmBa8Q==}
engines: {node: '>= 0.4'}
pretty-ms@7.0.1:
resolution: {integrity: sha512-973driJZvxiGOQ5ONsFhOF/DtzPMOMtgC11kCpUrPGMTgqp2q/1gwzCquocrN33is0VZ5GFHXZYMM9l6h67v2Q==}
engines: {node: '>=10'}
@ -2110,6 +2186,10 @@ packages:
resolution: {integrity: sha512-zWmv4RSuB9r2mYQw3zxQuHWeU+42aKi1wWig/j4ele4ygELZ7PEO6MM7rim9oAQH2A5MWfsAVf/jPvTPgCbvUQ==}
engines: {node: '>=0.6'}
query-string@7.1.3:
resolution: {integrity: sha512-hh2WYhq4fi8+b+/2Kg9CEge4fDPvHS534aOOvOZeQ3+Vf2mCFsaFBYj0i+iXcAq6I9Vzp5fjMFBlONvayDC1qg==}
engines: {node: '>=6'}
queue-microtask@1.2.3:
resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==}
@ -2280,6 +2360,10 @@ packages:
resolution: {integrity: sha512-EeajNjfN9zMnULLwhZZQU3GWBoFNkbngTUPfaawT4RkMiviTxcX0qfhVbGey39mfctfDHkWtuecgQ8NJcyQWHg==}
engines: {node: '>=8'}
split-on-first@1.1.0:
resolution: {integrity: sha512-43ZssAJaMusuKWL8sKUBQXHWOpq8d6CfN/u1p4gUzfJkM05C8rxTmYrkIPTXapZpORA6LkkzcUulJ8FqA7Uudw==}
engines: {node: '>=6'}
sprintf-js@1.0.3:
resolution: {integrity: sha1-BOaSb2YolTVPPdAVIDYzuFcpfiw=}
@ -2291,9 +2375,19 @@ packages:
resolution: {integrity: sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==}
engines: {node: '>= 0.8'}
stream-chain@2.2.5:
resolution: {integrity: sha512-1TJmBx6aSWqZ4tx7aTpBDXK0/e2hhcNSTV8+CbFJtDjbb+I1mZ8lHit0Grw9GRT+6JbIrrDd8esncgBi8aBXGA==}
stream-json@1.8.0:
resolution: {integrity: sha512-HZfXngYHUAr1exT4fxlbc1IOce1RYxp2ldeaf97LYCOPSoOqY/1Psp7iGvpb+6JIOgkra9zDYnPX01hGAHzEPw==}
streamx@2.18.0:
resolution: {integrity: sha512-LLUC1TWdjVdn1weXGcSxyTR3T4+acB6tVGXT95y0nGbca4t4o/ng1wKAGTljm9VicuCVLvRlqFYXYy5GwgM7sQ==}
strict-uri-encode@2.0.0:
resolution: {integrity: sha1-ucczDHBChi9rFC3CdLvMWGbONUY=}
engines: {node: '>=4'}
string-width@4.2.3:
resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==}
engines: {node: '>=8'}
@ -2478,6 +2572,9 @@ packages:
util-deprecate@1.0.2:
resolution: {integrity: sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=}
util@0.12.5:
resolution: {integrity: sha512-kZf/K6hEIrWHI6XqOFUiiMa+79wE/D8Q+NCNAWclkyg3b4d2k7s0QGepNjiABc+aR3N1PAyHL7p6UcLY6LmrnA==}
utils-merge@1.0.1:
resolution: {integrity: sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM=}
engines: {node: '>= 0.4.0'}
@ -2493,12 +2590,19 @@ packages:
resolution: {integrity: sha1-IpnwLG3tMNSllhsLn3RSShj2NPw=}
engines: {node: '>= 0.8'}
web-encoding@1.1.5:
resolution: {integrity: sha512-HYLeVCdJ0+lBYV2FvNZmv3HJ2Nt0QYXqZojk3d9FJOLkwnuhzM9tmamh8d7HPM8QqjKH8DeHkFTx+CFlWpZZDA==}
webidl-conversions@3.0.1:
resolution: {integrity: sha1-JFNCdeKnvGvnvIZhHMFq4KVlSHE=}
whatwg-url@5.0.0:
resolution: {integrity: sha1-lmRU6HZUYuN2RNNib2dCzotwll0=}
which-typed-array@1.1.15:
resolution: {integrity: sha512-oV0jmFtUky6CXfkqehVvBP/LSWJ2sy4vWMioiENyJLePrBO/yKyV9OyJySfAKosh+RYkIl5zJCNZ8/4JncrpdA==}
engines: {node: '>= 0.4'}
which@1.3.1:
resolution: {integrity: sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==}
hasBin: true
@ -2612,6 +2716,8 @@ packages:
snapshots:
'@api.global/typedrequest-interfaces@2.0.2': {}
'@api.global/typedrequest-interfaces@3.0.19': {}
'@api.global/typedrequest@3.0.23':
@ -2635,9 +2741,9 @@ snapshots:
'@push.rocks/smartdelay': 3.0.5
'@push.rocks/smartenv': 5.0.12
'@push.rocks/smartfeed': 1.0.11
'@push.rocks/smartfile': 11.0.16
'@push.rocks/smartfile': 11.0.20
'@push.rocks/smartjson': 5.0.20
'@push.rocks/smartlog': 3.0.6
'@push.rocks/smartlog': 3.0.7
'@push.rocks/smartlog-destination-devtools': 1.0.10
'@push.rocks/smartmanifest': 2.0.2
'@push.rocks/smartmime': 1.0.6
@ -2777,8 +2883,8 @@ snapshots:
'@push.rocks/early': 4.0.4
'@push.rocks/smartcli': 4.0.11
'@push.rocks/smartdelay': 3.0.5
'@push.rocks/smartfile': 11.0.16
'@push.rocks/smartlog': 3.0.6
'@push.rocks/smartfile': 11.0.20
'@push.rocks/smartlog': 3.0.7
'@push.rocks/smartpath': 5.0.18
'@push.rocks/smartpromise': 4.0.3
typescript: 5.4.5
@ -2788,8 +2894,8 @@ snapshots:
'@push.rocks/early': 4.0.4
'@push.rocks/smartcli': 4.0.10
'@push.rocks/smartdelay': 3.0.5
'@push.rocks/smartfile': 11.0.16
'@push.rocks/smartlog': 3.0.6
'@push.rocks/smartfile': 11.0.20
'@push.rocks/smartlog': 3.0.7
'@push.rocks/smartlog-destination-local': 9.0.2
'@push.rocks/smartpath': 5.0.18
'@push.rocks/smartpromise': 4.0.3
@ -2801,27 +2907,27 @@ snapshots:
transitivePeerDependencies:
- supports-color
'@git.zone/tsrun@1.2.46(@types/node@20.14.1)':
'@git.zone/tsrun@1.2.46(@types/node@20.14.2)':
dependencies:
'@push.rocks/smartfile': 10.0.41
'@push.rocks/smartshell': 3.0.5
ts-node: 10.9.2(@types/node@20.14.1)(typescript@5.1.6)
ts-node: 10.9.2(@types/node@20.14.2)(typescript@5.1.6)
typescript: 5.1.6
transitivePeerDependencies:
- '@swc/core'
- '@swc/wasm'
- '@types/node'
'@git.zone/tstest@1.0.90(@types/node@20.14.1)':
'@git.zone/tstest@1.0.90(@types/node@20.14.2)':
dependencies:
'@api.global/typedserver': 3.0.29
'@git.zone/tsbundle': 2.0.15
'@git.zone/tsrun': 1.2.46(@types/node@20.14.1)
'@git.zone/tsrun': 1.2.46(@types/node@20.14.2)
'@push.rocks/consolecolor': 2.0.2
'@push.rocks/smartbrowser': 2.0.6
'@push.rocks/smartdelay': 3.0.5
'@push.rocks/smartfile': 11.0.16
'@push.rocks/smartlog': 3.0.6
'@push.rocks/smartfile': 11.0.20
'@push.rocks/smartlog': 3.0.7
'@push.rocks/smartpromise': 4.0.3
'@push.rocks/smartshell': 3.0.5
'@push.rocks/tapbundle': 5.0.23
@ -2948,10 +3054,10 @@ snapshots:
'@types/symbol-tree': 3.2.5
symbol-tree: 3.2.4
'@push.rocks/smartarchive@4.0.22':
'@push.rocks/smartarchive@4.0.36':
dependencies:
'@push.rocks/smartdelay': 3.0.5
'@push.rocks/smartfile': 11.0.16
'@push.rocks/smartfile': 11.0.20
'@push.rocks/smartpath': 5.0.18
'@push.rocks/smartpromise': 4.0.3
'@push.rocks/smartrequest': 2.0.22
@ -2977,6 +3083,17 @@ snapshots:
- supports-color
- utf-8-validate
'@push.rocks/smartbucket@3.0.10':
dependencies:
'@push.rocks/smartmime': 2.0.2
'@push.rocks/smartpath': 5.0.18
'@push.rocks/smartpromise': 4.0.3
'@push.rocks/smartrx': 3.0.7
'@push.rocks/smartstream': 3.0.44
'@push.rocks/smartunique': 3.0.9
'@tsclass/tsclass': 4.0.54
minio: 8.0.0
'@push.rocks/smartbuffer@3.0.4':
dependencies:
uint8array-extras: 1.1.0
@ -2999,7 +3116,7 @@ snapshots:
'@push.rocks/smartcli@4.0.10':
dependencies:
'@push.rocks/lik': 6.0.15
'@push.rocks/smartlog': 3.0.6
'@push.rocks/smartlog': 3.0.7
'@push.rocks/smartparam': 1.1.10
'@push.rocks/smartpromise': 4.0.3
'@push.rocks/smartrx': 3.0.7
@ -3008,7 +3125,7 @@ snapshots:
'@push.rocks/smartcli@4.0.11':
dependencies:
'@push.rocks/lik': 6.0.15
'@push.rocks/smartlog': 3.0.6
'@push.rocks/smartlog': 3.0.7
'@push.rocks/smartobject': 1.0.12
'@push.rocks/smartpromise': 4.0.3
'@push.rocks/smartrx': 3.0.7
@ -3062,7 +3179,7 @@ snapshots:
glob: 10.3.12
js-yaml: 4.1.0
'@push.rocks/smartfile@11.0.16':
'@push.rocks/smartfile@11.0.20':
dependencies:
'@push.rocks/lik': 6.0.15
'@push.rocks/smartdelay': 3.0.5
@ -3109,10 +3226,15 @@ snapshots:
dependencies:
'@apiglobal/typedrequest-interfaces': 2.0.1
'@push.rocks/smartlog@3.0.6':
'@push.rocks/smartlog-interfaces@3.0.2':
dependencies:
'@api.global/typedrequest-interfaces': 2.0.2
'@tsclass/tsclass': 4.0.54
'@push.rocks/smartlog@3.0.7':
dependencies:
'@push.rocks/isounique': 1.0.5
'@push.rocks/smartlog-interfaces': 3.0.0
'@push.rocks/smartlog-interfaces': 3.0.2
'@push.rocks/smartmanifest@2.0.2': {}
@ -3161,7 +3283,7 @@ snapshots:
dependencies:
'@push.rocks/smartbuffer': 3.0.4
'@push.rocks/smartdelay': 3.0.5
'@push.rocks/smartfile': 11.0.16
'@push.rocks/smartfile': 11.0.20
'@push.rocks/smartnetwork': 3.0.2
'@push.rocks/smartpath': 5.0.18
'@push.rocks/smartpromise': 4.0.3
@ -3233,7 +3355,7 @@ snapshots:
'@push.rocks/smartdelay': 3.0.5
'@push.rocks/smartenv': 5.0.12
'@push.rocks/smartjson': 5.0.20
'@push.rocks/smartlog': 3.0.6
'@push.rocks/smartlog': 3.0.7
'@push.rocks/smartpromise': 4.0.3
'@push.rocks/smartrx': 3.0.7
'@push.rocks/smarttime': 4.0.6
@ -3522,14 +3644,14 @@ snapshots:
'@types/accepts@1.3.7':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/babel__code-frame@7.0.6': {}
'@types/body-parser@1.19.5':
dependencies:
'@types/connect': 3.4.38
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/buffer-json@2.0.3': {}
@ -3541,17 +3663,17 @@ snapshots:
'@types/clean-css@4.2.11':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
source-map: 0.6.1
'@types/co-body@6.1.3':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/qs': 6.9.15
'@types/connect@3.4.38':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/content-disposition@0.5.8': {}
@ -3564,11 +3686,11 @@ snapshots:
'@types/connect': 3.4.38
'@types/express': 4.17.21
'@types/keygrip': 1.0.6
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/cors@2.8.17':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/debounce@1.2.4': {}
@ -3576,7 +3698,7 @@ snapshots:
'@types/express-serve-static-core@4.19.0':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/qs': 6.9.15
'@types/range-parser': 1.2.7
'@types/send': 0.17.4
@ -3590,17 +3712,17 @@ snapshots:
'@types/from2@2.3.5':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/fs-extra@11.0.4':
dependencies:
'@types/jsonfile': 6.1.4
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/glob@8.1.0':
dependencies:
'@types/minimatch': 5.1.2
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/html-minifier@4.0.5':
dependencies:
@ -3630,7 +3752,7 @@ snapshots:
'@types/jsonfile@6.1.4':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/keygrip@1.0.6': {}
@ -3647,7 +3769,7 @@ snapshots:
'@types/http-errors': 2.0.4
'@types/keygrip': 1.0.6
'@types/koa-compose': 3.2.8
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/mime-types@2.1.4': {}
@ -3657,7 +3779,7 @@ snapshots:
'@types/minimatch@5.1.2': {}
'@types/node@20.14.1':
'@types/node@20.14.2':
dependencies:
undici-types: 5.26.5
@ -3678,12 +3800,12 @@ snapshots:
'@types/send@0.17.4':
dependencies:
'@types/mime': 1.3.5
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/serve-static@1.15.7':
dependencies:
'@types/http-errors': 2.0.4
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/send': 0.17.4
'@types/sinon-chai@3.2.12':
@ -3701,11 +3823,11 @@ snapshots:
'@types/tar-stream@3.1.3':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/through2@2.0.41':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/trusted-types@2.0.7': {}
@ -3721,15 +3843,15 @@ snapshots:
'@types/ws@7.4.7':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/ws@8.5.10':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
'@types/yauzl@2.10.3':
dependencies:
'@types/node': 20.14.1
'@types/node': 20.14.2
optional: true
'@web/browser-logs@0.4.0':
@ -3808,6 +3930,9 @@ snapshots:
- supports-color
- utf-8-validate
'@zxing/text-encoding@0.9.0':
optional: true
accepts@1.3.8:
dependencies:
mime-types: 2.1.35
@ -3875,8 +4000,14 @@ snapshots:
astral-regex@2.0.0: {}
async@3.2.5: {}
asynckit@0.4.0: {}
available-typed-arrays@1.0.7:
dependencies:
possible-typed-array-names: 1.0.0
axe-core@4.9.1: {}
b4a@1.6.6: {}
@ -3898,6 +4029,10 @@ snapshots:
inherits: 2.0.4
readable-stream: 3.6.2
block-stream2@2.1.0:
dependencies:
readable-stream: 3.6.2
body-parser@1.20.2:
dependencies:
bytes: 3.1.2
@ -3928,8 +4063,12 @@ snapshots:
dependencies:
fill-range: 7.0.1
browser-or-node@2.1.1: {}
buffer-crc32@0.2.13: {}
buffer-crc32@1.0.0: {}
buffer-json@2.0.0: {}
buffer@5.7.1:
@ -4116,6 +4255,8 @@ snapshots:
dependencies:
ms: 2.1.2
decode-uri-component@0.2.2: {}
decompress-response@6.0.0:
dependencies:
mimic-response: 3.1.0
@ -4198,7 +4339,7 @@ snapshots:
dependencies:
'@types/cookie': 0.4.1
'@types/cors': 2.8.17
'@types/node': 20.14.1
'@types/node': 20.14.2
accepts: 1.3.8
base64id: 2.0.0
cookie: 0.4.2
@ -4263,6 +4404,8 @@ snapshots:
etag@1.8.1: {}
eventemitter3@5.0.1: {}
express-force-ssl@0.3.2:
dependencies:
lodash.assign: 3.2.0
@ -4361,6 +4504,8 @@ snapshots:
dependencies:
to-regex-range: 5.0.1
filter-obj@1.1.0: {}
finalhandler@1.2.0:
dependencies:
debug: 2.6.9
@ -4378,6 +4523,10 @@ snapshots:
locate-path: 5.0.0
path-exists: 4.0.0
for-each@0.3.3:
dependencies:
is-callable: 1.2.7
foreground-child@2.0.0:
dependencies:
cross-spawn: 7.0.3
@ -4449,7 +4598,7 @@ snapshots:
glob@10.4.1:
dependencies:
foreground-child: 3.1.1
jackspeak: 3.2.3
jackspeak: 3.4.0
minimatch: 9.0.4
minipass: 7.1.2
path-scurry: 1.11.1
@ -4610,10 +4759,19 @@ snapshots:
ipaddr.js@1.9.1: {}
ipaddr.js@2.2.0: {}
is-arguments@1.1.1:
dependencies:
call-bind: 1.0.7
has-tostringtag: 1.0.2
is-binary-path@2.1.0:
dependencies:
binary-extensions: 2.3.0
is-callable@1.2.7: {}
is-docker@2.2.1: {}
is-extglob@2.1.1: {}
@ -4645,6 +4803,10 @@ snapshots:
is-stream@2.0.1: {}
is-typed-array@1.1.13:
dependencies:
which-typed-array: 1.1.15
is-unicode-supported@2.0.0: {}
is-windows@1.0.2: {}
@ -4682,7 +4844,7 @@ snapshots:
optionalDependencies:
'@pkgjs/parseargs': 0.11.0
jackspeak@3.2.3:
jackspeak@3.4.0:
dependencies:
'@isaacs/cliui': 8.0.2
optionalDependencies:
@ -4832,6 +4994,8 @@ snapshots:
lodash.restparam@3.6.1: {}
lodash@4.17.21: {}
log-update@4.0.0:
dependencies:
ansi-escapes: 4.3.2
@ -4915,6 +5079,23 @@ snapshots:
dependencies:
brace-expansion: 2.0.1
minio@8.0.0:
dependencies:
async: 3.2.5
block-stream2: 2.1.0
browser-or-node: 2.1.1
buffer-crc32: 1.0.0
eventemitter3: 5.0.1
fast-xml-parser: 4.3.6
ipaddr.js: 2.2.0
lodash: 4.17.21
mime-types: 2.1.35
query-string: 7.1.3
stream-json: 1.8.0
through2: 4.0.2
web-encoding: 1.1.5
xml2js: 0.5.0
minipass@7.1.0: {}
minipass@7.1.2: {}
@ -5056,6 +5237,8 @@ snapshots:
dependencies:
find-up: 4.1.0
possible-typed-array-names@1.0.0: {}
pretty-ms@7.0.1:
dependencies:
parse-ms: 2.1.0
@ -5119,6 +5302,13 @@ snapshots:
dependencies:
side-channel: 1.0.6
query-string@7.1.3:
dependencies:
decode-uri-component: 0.2.2
filter-obj: 1.1.0
split-on-first: 1.1.0
strict-uri-encode: 2.0.0
queue-microtask@1.2.3: {}
queue-tick@1.0.1: {}
@ -5334,12 +5524,20 @@ snapshots:
signal-exit: 3.0.7
which: 2.0.2
split-on-first@1.1.0: {}
sprintf-js@1.0.3: {}
statuses@1.5.0: {}
statuses@2.0.1: {}
stream-chain@2.2.5: {}
stream-json@1.8.0:
dependencies:
stream-chain: 2.2.5
streamx@2.18.0:
dependencies:
fast-fifo: 1.3.2
@ -5348,6 +5546,8 @@ snapshots:
optionalDependencies:
bare-events: 2.3.1
strict-uri-encode@2.0.0: {}
string-width@4.2.3:
dependencies:
emoji-regex: 8.0.0
@ -5462,14 +5662,14 @@ snapshots:
tree-kill@1.2.2: {}
ts-node@10.9.2(@types/node@20.14.1)(typescript@5.1.6):
ts-node@10.9.2(@types/node@20.14.2)(typescript@5.1.6):
dependencies:
'@cspotcode/source-map-support': 0.8.1
'@tsconfig/node10': 1.0.11
'@tsconfig/node12': 1.0.11
'@tsconfig/node14': 1.0.3
'@tsconfig/node16': 1.0.4
'@types/node': 20.14.1
'@types/node': 20.14.2
acorn: 8.11.3
acorn-walk: 8.3.2
arg: 4.1.3
@ -5527,6 +5727,14 @@ snapshots:
util-deprecate@1.0.2: {}
util@0.12.5:
dependencies:
inherits: 2.0.4
is-arguments: 1.1.1
is-generator-function: 1.0.10
is-typed-array: 1.1.13
which-typed-array: 1.1.15
utils-merge@1.0.1: {}
uuid@9.0.1: {}
@ -5535,6 +5743,12 @@ snapshots:
vary@1.1.2: {}
web-encoding@1.1.5:
dependencies:
util: 0.12.5
optionalDependencies:
'@zxing/text-encoding': 0.9.0
webidl-conversions@3.0.1: {}
whatwg-url@5.0.0:
@ -5542,6 +5756,14 @@ snapshots:
tr46: 0.0.3
webidl-conversions: 3.0.1
which-typed-array@1.1.15:
dependencies:
available-typed-arrays: 1.0.7
call-bind: 1.0.7
for-each: 0.3.3
gopd: 1.0.1
has-tostringtag: 1.0.2
which@1.3.1:
dependencies:
isexe: 2.0.0

View File

@ -9,6 +9,7 @@ let testDockerHost: docker.DockerHost;
tap.test('should create a new Dockersock instance', async () => {
testDockerHost = new docker.DockerHost({});
await testDockerHost.start();
return expect(testDockerHost).toBeInstanceOf(docker.DockerHost);
});
@ -118,7 +119,7 @@ tap.test('should create a service', async () => {
await testSecret.remove();
});
tap.test('should export images', async (toolsArg) => {
tap.skip.test('should export images', async (toolsArg) => {
const done = toolsArg.defer();
const testImage = await docker.DockerImage.createFromRegistry(testDockerHost, {
creationObject: {
@ -135,7 +136,7 @@ tap.test('should export images', async (toolsArg) => {
await done.promise;
});
tap.test('should import images', async (toolsArg) => {
tap.skip.test('should import images', async (toolsArg) => {
const done = toolsArg.defer();
const fsReadStream = plugins.smartfile.fsStream.createReadStream(
plugins.path.join(paths.nogitDir, 'testimage.tar')
@ -146,6 +147,10 @@ tap.test('should import images', async (toolsArg) => {
imageUrl: 'code.foss.global/host.today/ht-docker-node:latest',
}
})
});
tap.test('should expose a working DockerImageStore', async () => {
await testDockerHost.imageStore.storeImage('hello', plugins.smartfile.fsStream.createReadStream(plugins.path.join(paths.nogitDir, 'testimage.tar')));
})
export default tap.start();

View File

@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@apiclient.xyz/docker',
version: '1.1.1',
version: '1.2.0',
description: 'Provides easy communication with Docker remote API from Node.js, with TypeScript support.'
}

View File

@ -2,7 +2,7 @@ import * as plugins from './plugins.js';
import * as interfaces from './interfaces/index.js';
import { DockerHost } from './classes.host.js';
import { logger } from './logging.js';
import { logger } from './logger.js';
export class DockerContainer {
// STATIC

View File

@ -1,10 +1,12 @@
import * as plugins from './plugins.js';
import * as paths from './paths.js';
import { DockerContainer } from './classes.container.js';
import { DockerNetwork } from './classes.network.js';
import { DockerService } from './classes.service.js';
import { logger } from './logging.js';
import { logger } from './logger.js';
import path from 'path';
import type { DockerImageStore } from './classes.imagestore.js';
import { DockerImageStore } from './classes.imagestore.js';
import { DockerImage } from './classes.image.js';
export interface IAuthData {
serveraddress: string;
@ -18,6 +20,8 @@ export interface IDockerHostConstructorOptions {
}
export class DockerHost {
public options: IDockerHostConstructorOptions;
/**
* the path where the docker sock can be found
*/
@ -30,6 +34,12 @@ export class DockerHost {
* @param pathArg
*/
constructor(optionsArg: IDockerHostConstructorOptions) {
this.options = {
...{
imageStoreDir: plugins.path.join(paths.nogitDir, 'temp-docker-image-store'),
},
...optionsArg,
}
let pathToUse: string;
if (optionsArg.dockerSockPath) {
pathToUse = optionsArg.dockerSockPath;
@ -48,6 +58,17 @@ export class DockerHost {
}
console.log(`using docker sock at ${pathToUse}`);
this.socketPath = pathToUse;
this.imageStore = new DockerImageStore(this, {
bucketDir: null,
localDirPath: this.options.imageStoreDir,
})
}
public async start() {
await this.imageStore.start();
}
public async stop() {
await this.imageStore.stop();
}
/**
@ -81,6 +102,9 @@ export class DockerHost {
});
}
// ==============
// NETWORKS
// ==============
/**
* gets all networks
*/
@ -89,9 +113,23 @@ export class DockerHost {
}
/**
*
* create a network
*/
public async createNetwork(optionsArg: Parameters<typeof DockerNetwork.createNetwork>[1]) {
return await DockerNetwork.createNetwork(this, optionsArg);
}
/**
* get a network by name
*/
public async getNetworkByName(networkNameArg: string) {
return await DockerNetwork.getNetworkByName(this, networkNameArg);
}
// ==============
// CONTAINERS
// ==============
/**
* gets all containers
*/
@ -100,6 +138,10 @@ export class DockerHost {
return containerArray;
}
// ==============
// SERVICES
// ==============
/**
* gets all services
*/
@ -108,6 +150,24 @@ export class DockerHost {
return serviceArray;
}
// ==============
// IMAGES
// ==============
/**
* get all images
*/
public async getImages() {
return await DockerImage.getImages(this);
}
/**
* get an image by name
*/
public async getImageByName(imageNameArg: string) {
return await DockerImage.getImageByName(this, imageNameArg);
}
/**
*
*/

View File

@ -1,8 +1,11 @@
import * as plugins from './plugins.js';
import * as interfaces from './interfaces/index.js';
import { DockerHost } from './classes.host.js';
import { logger } from './logging.js';
import { logger } from './logger.js';
/**
* represents a docker image on the remote docker host
*/
export class DockerImage {
// STATIC
public static async getImages(dockerHost: DockerHost) {
@ -14,7 +17,7 @@ export class DockerImage {
return images;
}
public static async findImageByName(dockerHost: DockerHost, imageNameArg: string) {
public static async getImageByName(dockerHost: DockerHost, imageNameArg: string) {
const images = await this.getImages(dockerHost);
const result = images.find((image) => {
if (image.RepoTags) {
@ -67,7 +70,7 @@ export class DockerImage {
);
if (response.statusCode < 300) {
logger.log('info', `Successfully pulled image ${imageUrlObject.imageUrl} from the registry`);
const image = await DockerImage.findImageByName(dockerHostArg, imageUrlObject.imageOriginTag);
const image = await DockerImage.getImageByName(dockerHostArg, imageUrlObject.imageOriginTag);
return image;
} else {
logger.log('error', `Failed at the attempt of creating a new image`);

View File

@ -1,9 +1,17 @@
import * as plugins from './plugins.js';
import * as paths from './paths.js';
import { logger } from './logger.js';
import type { DockerHost } from './classes.host.js';
export interface IDockerImageStoreConstructorOptions {
dirPath: string;
/**
* used for preparing images for longer term storage
*/
localDirPath: string;
/**
* a smartbucket dir for longer term storage.
*/
bucketDir: plugins.smartbucket.Directory;
}
export class DockerImageStore {
@ -14,23 +22,82 @@ export class DockerImageStore {
}
// Method to store tar stream
public async storeImage(imageName: string, tarStream: NodeJS.ReadableStream): Promise<void> {
const imagePath = plugins.path.join(this.options.dirPath, `${imageName}.tar`);
public async storeImage(imageName: string, tarStream: plugins.smartstream.stream.Readable): Promise<void> {
logger.log('info', `Storing image ${imageName}...`);
const uniqueProcessingId = plugins.smartunique.shortId();
const initialTarDownloadPath = plugins.path.join(this.options.localDirPath, `${uniqueProcessingId}.tar`);
const extractionDir = plugins.path.join(this.options.localDirPath, uniqueProcessingId);
// Create a write stream to store the tar file
const writeStream = plugins.smartfile.fsStream.createWriteStream(imagePath);
const writeStream = plugins.smartfile.fsStream.createWriteStream(initialTarDownloadPath);
return new Promise((resolve, reject) => {
// lets wait for the write stream to finish
await new Promise((resolve, reject) => {
tarStream.pipe(writeStream);
writeStream.on('finish', resolve);
writeStream.on('error', reject);
});
logger.log('info', `Image ${imageName} stored locally for processing. Extracting...`);
// lets process the image
const tarArchive = await plugins.smartarchive.SmartArchive.fromArchiveFile(initialTarDownloadPath);
await tarArchive.exportToFs(extractionDir);
logger.log('info', `Image ${imageName} extracted.`);
await plugins.smartfile.fs.remove(initialTarDownloadPath);
logger.log('info', `deleted original tar to save space.`);
logger.log('info', `now repackaging for s3...`);
const smartfileIndexJson = await plugins.smartfile.SmartFile.fromFilePath(plugins.path.join(extractionDir, 'index.json'));
const smartfileManifestJson = await plugins.smartfile.SmartFile.fromFilePath(plugins.path.join(extractionDir, 'manifest.json'));
const smartfileOciLayoutJson = await plugins.smartfile.SmartFile.fromFilePath(plugins.path.join(extractionDir, 'oci-layout'));
const smartfileRepositoriesJson = await plugins.smartfile.SmartFile.fromFilePath(plugins.path.join(extractionDir, 'repositories'));
const indexJson = JSON.parse(smartfileIndexJson.contents.toString());
const manifestJson = JSON.parse(smartfileManifestJson.contents.toString());
const ociLayoutJson = JSON.parse(smartfileOciLayoutJson.contents.toString());
const repositoriesJson = JSON.parse(smartfileRepositoriesJson.contents.toString());
indexJson.manifests[0].annotations['io.containerd.image.name'] = imageName;
manifestJson[0].RepoTags[0] = imageName;
const repoFirstKey = Object.keys(repositoriesJson)[0];
const repoFirstValue = repositoriesJson[repoFirstKey];
repositoriesJson[imageName] = repoFirstValue;
delete repositoriesJson[repoFirstKey];
smartfileIndexJson.contents = Buffer.from(JSON.stringify(indexJson, null, 2));
smartfileManifestJson.contents = Buffer.from(JSON.stringify(manifestJson, null, 2));
smartfileOciLayoutJson.contents = Buffer.from(JSON.stringify(ociLayoutJson, null, 2));
smartfileRepositoriesJson.contents = Buffer.from(JSON.stringify(repositoriesJson, null, 2));
await Promise.all([
smartfileIndexJson.write(),
smartfileManifestJson.write(),
smartfileOciLayoutJson.write(),
smartfileRepositoriesJson.write(),
]);
logger.log('info', 'repackaging archive for s3...');
const tartools = new plugins.smartarchive.TarTools();
const newTarPack = await tartools.packDirectory(extractionDir);
const finalTarName = `${uniqueProcessingId}.processed.tar`;
const finalTarPath = plugins.path.join(this.options.localDirPath, finalTarName);
const finalWriteStream = plugins.smartfile.fsStream.createWriteStream(finalTarPath);
await new Promise((resolve, reject) => {
newTarPack.finalize();
newTarPack.pipe(finalWriteStream);
finalWriteStream.on('finish', resolve);
finalWriteStream.on('error', reject);
});
logger.log('ok', `Repackaged image ${imageName} for s3.`);
await plugins.smartfile.fs.remove(extractionDir);
}
public async start() {
await plugins.smartfile.fs.ensureEmptyDir(this.options.localDirPath);
}
public async stop() {}
// Method to retrieve tar stream
public async getImage(imageName: string): Promise<plugins.smartstream.stream.Readable> {
const imagePath = plugins.path.join(this.options.dirPath, `${imageName}.tar`);
const imagePath = plugins.path.join(this.options.localDirPath, `${imageName}.tar`);
if (!(await plugins.smartfile.fs.fileExists(imagePath))) {
throw new Error(`Image ${imageName} does not exist.`);

View File

@ -3,7 +3,7 @@ import * as interfaces from './interfaces/index.js';
import { DockerHost } from './classes.host.js';
import { DockerService } from './classes.service.js';
import { logger } from './logging.js';
import { logger } from './logger.js';
export class DockerNetwork {
public static async getNetworks(dockerHost: DockerHost): Promise<DockerNetwork[]> {

View File

@ -4,7 +4,7 @@ import * as interfaces from './interfaces/index.js';
import { DockerHost } from './classes.host.js';
import { DockerImage } from './classes.image.js';
import { DockerSecret } from './classes.secret.js';
import { logger } from './logging.js';
import { logger } from './logger.js';
export class DockerService {
// STATIC

View File

@ -1,6 +1,7 @@
export * from './classes.host.js';
export * from './classes.container.js';
export * from './classes.image.js';
export * from './classes.imagestore.js';
export * from './classes.network.js';
export * from './classes.secret.js';
export * from './classes.service.js';

5
ts/logger.ts Normal file
View File

@ -0,0 +1,5 @@
import * as plugins from './plugins.js';
import { commitinfo } from './00_commitinfo_data.js';
export const logger = plugins.smartlog.Smartlog.createForCommitinfo(commitinfo);
logger.enableConsole();

View File

@ -1,3 +0,0 @@
import * as plugins from './plugins.js';
export const logger = new plugins.smartlog.ConsoleLog();

View File

@ -5,6 +5,8 @@ export { path };
// @pushrocks scope
import * as lik from '@push.rocks/lik';
import * as smartarchive from '@push.rocks/smartarchive';
import * as smartbucket from '@push.rocks/smartbucket';
import * as smartfile from '@push.rocks/smartfile';
import * as smartjson from '@push.rocks/smartjson';
import * as smartlog from '@push.rocks/smartlog';
@ -14,10 +16,13 @@ import * as smartpromise from '@push.rocks/smartpromise';
import * as smartrequest from '@push.rocks/smartrequest';
import * as smartstring from '@push.rocks/smartstring';
import * as smartstream from '@push.rocks/smartstream';
import * as smartunique from '@push.rocks/smartunique';
import * as smartversion from '@push.rocks/smartversion';
export {
lik,
smartarchive,
smartbucket,
smartfile,
smartjson,
smartlog,
@ -27,6 +32,7 @@ export {
smartrequest,
smartstring,
smartstream,
smartunique,
smartversion,
};