{"id":1060,"date":"2021-12-09T16:48:02","date_gmt":"2021-12-09T08:48:02","guid":{"rendered":"https:\/\/www.yinyubo.com\/?p=1060"},"modified":"2022-05-16T18:02:05","modified_gmt":"2022-05-16T10:02:05","slug":"electron","status":"publish","type":"post","link":"https:\/\/www.yinyubo.com\/?p=1060","title":{"rendered":"electron+droneCI+minio\u6d41\u6c34\u7ebf"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">\u80cc\u666f<\/h2>\n\n\n\n<p>\u56e0\u4e3a\u6211\u4eec\u7684electron\u7a0b\u5e8f\u5df2\u7ecf\u5f00\u53d1\u5b8c\u6210\uff0c\u671f\u671b\u8981\u80fd\u5f00\u53d1\u4eba\u5458\u6bcf\u6b21\u4e0a\u4f20\u4ee3\u7801\uff0c\u6253\u4e86tag\u5c31\u81ea\u52a8build\u4e00\u4efddeb\u6587\u4ef6\uff0c\u81ea\u52a8\u4e0a\u4f20\u5230minio\uff0c\u65b9\u4fbf\u8fd0\u7ef4\u4eba\u5458\u53bb\u62ffdeb\u6587\u4ef6\u90e8\u7f72\u5230ubuntu\u73af\u5883\u4e0a\u3002\u6211\u4eec\u5df2\u6709\u7684\u6280\u672f\u6808\u5305\u542bdroneCI,minio,python\uff0c\u4e8e\u662f\u8fb9\u6709\u4e86\u8be5\u65b9\u6848\u3002\u672c\u6587\u7701\u7565\u4e86vault,ldap,minio,harbor\u7684\u5b89\u88c5\u4e0e\u914d\u7f6e\uff0c\u8fd9\u4e9b\u7a0b\u5e8f\u7684\u5b89\u88c5\u914d\u7f6e\u5728\u672c\u7f51\u7ad9\u7684\u5176\u4ed6\u6587\u7ae0\u91cc\uff0c\u5c31\u4e0d\u4e00\u4e00\u8d34\u51fa\u6765\u4e86<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">\u67b6\u6784\u56fe<\/h2>\n\n\n\n<figure class=\"wp-block-image size-full is-resized is-style-default\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-9.png\" alt=\"\" class=\"wp-image-1061\" width=\"1096\" height=\"130\" srcset=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-9.png 1096w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-9-300x36.png 300w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-9-1024x121.png 1024w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-9-768x91.png 768w\" sizes=\"auto, (max-width: 1096px) 100vw, 1096px\" \/><\/figure>\n\n\n\n<p>\u89e3\u91ca\uff1a<\/p>\n\n\n\n<p>1.\u524d\u7aef\u5f00\u53d1\u4e0a\u4f20electron\u4ee3\u7801\u5230git\u670d\u52a1\u7aef<\/p>\n\n\n\n<p>2.git\u670d\u52a1\u7aef\u901a\u8fc7webhook\u65b9\u5f0f\u901a\u77e5drone-server\u4ea7\u751f\u4e86\u3002\u4f8b\u5982\u672c\u6587\u53ea\u6d4b\u8bd5\u7684\u662f\u53d1\u5e03tag\u89e6\u53d1webhook\uff0c\u8fd8\u6709\u5f88\u591a\u79cd\u89e6\u53d1\u65b9\u5f0f\u90fd\u53ef\u4ee5\u8bbe\u7f6e<\/p>\n\n\n\n<p>3.drone-server\u6536\u5230\u901a\u77e5\u540e\uff0c\u518d\u5728drone-runner\u6240\u5728\u7684k8s\u96c6\u7fa4\u91cc\u542f\u52a8\u4e00\u4e2a\u5305\u542bnodejs\u548cpython\u7684\u4efb\u52a1\u5bb9\u5668<\/p>\n\n\n\n<p>4.\u4efb\u52a1\u5bb9\u5668\u901a\u8fc7electron-forge make \u547d\u4ee4\u6253\u5305\u4e00\u4e2adeb\u6587\u4ef6<\/p>\n\n\n\n<p>5.\u4efb\u52a1\u5bb9\u5668\u901a\u8fc7minio\u63d0\u4f9b\u7684python sdk\u4e0a\u4f20deb\u6587\u4ef6\u5230minio<\/p>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">drone\u63d2\u4ef6\u7f16\u5199<\/h2>\n\n\n\n<p>\u8981\u5b8c\u6210\u4e0a\u8ff0\u76ee\u6807\uff0c\u7b2c\u4e00\u6b65\u5c31\u662f\u5f97\u7f16\u5199\u4e00\u4e2adrone\u7684\u63d2\u4ef6<\/p>\n\n\n\n<p>\u6211\u7f16\u5199\u8be5\u63d2\u4ef6\u4f7f\u7528\u7684\u662fnodejs16\u7248\u672c\u7684debian\u7cfb\u7edf\uff0c\u7136\u540e\u901a\u8fc7\u63d0\u524d\u5b89\u88c5\u597d\u9700\u8981\u7684\u5982\u4e0b\u8868\u683c\u91cc\u7684\u5de5\u5177\u3002\u6ce8\u610f\uff0c\u56e0\u4e3a\u6211\u7528\u7684\u662f\u534e\u4e3a\u6e90\uff0c2021\u5e7412\u67089\u65e5\u7684\u65f6\u5019\uff0c\u534e\u4e3a\u955c\u50cf\u4e0a\u6700\u65b0\u7684electron\u53ea\u523016.0.2\u7248\u672c\uff0c\u6240\u4ee5\u6ce8\u610f\u6307\u5b9a\u7248\u672c\u53f7<\/p>\n\n\n\n<p>\u4ecb\u7ecd\uff1a\u8be5\u63d2\u4ef6\u4f7f\u7528nodejs16\u7248\u672c\u7684debian\u7cfb\u7edf\uff0c\u7136\u540e\u901a\u8fc7\u63d0\u524d\u5b89\u88c5\u597d\u9700\u8981\u7684\u5982\u4e0b\u5de5\u5177\u3002\u6ce8\u610f\uff0c\u56e0\u4e3a\u6211\u7528\u7684\u662f\u534e\u4e3a\u6e90\uff0c2021\u5e7412\u67089\u65e5\u7684\u65f6\u5019\uff0c\u534e\u4e3a\u955c\u50cf\u4e0a\u6700\u65b0\u7684electron\u53ea\u523016.0.2\u7248\u672c\uff0c\u6240\u4ee5\u6ce8\u610f\u6307\u5b9a\u7248\u672c\u53f7<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table><thead><tr><th scope=\"col\">\u5de5\u5177\u540d<\/th><\/tr><\/thead><tbody><tr><td>rpm<\/td><\/tr><tr><td>python3-pip<\/td><\/tr><tr><td>python3<\/td><\/tr><tr><td>fakeroot<\/td><\/tr><tr><td>electron@v16.0.2&nbsp;<\/td><\/tr><tr><td>electron-prebuilt-compile<\/td><\/tr><tr><td>electron-forge&nbsp;<\/td><\/tr><tr><td>dpkg<\/td><\/tr><tr><td>minio\u7684python sdk<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>\u4ee3\u7801\u67093\u4e2a\u6587\u4ef6main.py Dockerfile ,requirements.txt\uff0c\u4e0b\u9762\u662f\u8be6\u7ec6\u4ecb\u7ecd<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">main.py<\/h3>\n\n\n\n<p>\u4ee3\u7801\u529f\u80fd\u662f\u5148\u83b7\u53d6\u73af\u5883\u53d8\u91cf\uff0c\u7136\u540e\u4f7f\u7528git\u7684tag\u53f7\u66ff\u6362\u6389package.json\u91cc\u7684version\u5b57\u6bb5\u3002\u6267\u884cyarn install\uff0cyanr make\uff0c\u901a\u8fc7\u73af\u5883\u53d8\u91cf\u627e\u5230\u9700\u8981\u4e0a\u4f20\u7684\u6587\u4ef6\uff0c\u901a\u8fc7pythonde\u7684sdk\u4e0a\u4f20\u5230minio\u91cc\u3002\u8be6\u7ec6\u4ee3\u7801\u5982\u4e0b<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>#main.py\nimport json\r\nimport os\r\nimport subprocess\r\n\r\nfrom minio import Minio\r\nfrom minio.error import S3Error\r\n\r\nendpoint = \"minio.sfere.local\"\r\naccess_key = \"bababa\"\r\nsecret_key = \"bababa\"\r\nbucket = \"electronjs\"\r\nfolder_path = \"\/drone\/src\/out\/make\/deb\/x64\"\r\nsuffix = \"deb\"\r\ntag = \"0.0.0\"\r\n\r\n\r\ndef find_file_by_suffix(target_dir, target_suffix=\"deb\"):\r\n    find_res = &#91;]\r\n    target_suffix_dot = \".\" + target_suffix\r\n    walk_generator = os.walk(target_dir)\r\n    for root_path, dirs, files in walk_generator:\r\n        if len(files) &lt; 1:\r\n            continue\r\n        for file in files:\r\n            file_name, suffix_name = os.path.splitext(file)\r\n            if suffix_name == target_suffix_dot:\r\n                find_res.append(os.path.join(root_path, file))\r\n    return find_res\r\n\r\n\r\ndef get_environment():\r\n    global endpoint, access_key, secret_key, bucket, suffix, tag\r\n\r\n    if \"PLUGIN_ENDPOINT\" in os.environ:\r\n        endpoint = os.environ&#91;\"PLUGIN_ENDPOINT\"]\r\n    if \"PLUGIN_ACCESS_KEY\" in os.environ:\r\n        access_key = os.environ&#91;\"PLUGIN_ACCESS_KEY\"]\r\n    if \"PLUGIN_SECRET_KEY\" in os.environ:\r\n        secret_key = os.environ&#91;\"PLUGIN_SECRET_KEY\"]\r\n    if \"PLUGIN_BUCKET\" in os.environ:\r\n        bucket = os.environ&#91;\"PLUGIN_BUCKET\"]\r\n    if \"PLUGIN_SUFFIX\" in os.environ:\r\n        suffix = os.environ&#91;\"PLUGIN_SUFFIX\"]\r\n    if \"PLUGIN_TAG\" in os.environ:\r\n        tag = os.environ&#91;\"PLUGIN_TAG\"]\r\n\r\n\r\ndef yarn_make():\r\n    with open('.\/package.json', 'r', encoding='utf8')as fp:\r\n        json_data = json.load(fp)\r\n    json_data&#91;'version'] = tag\r\n    with open('.\/package.json', 'w', encoding='utf8')as fp:\r\n        json.dump(json_data, fp, ensure_ascii=False, indent=2)\r\n    print('package version replace to ' + tag)\r\n    print(subprocess.run(\"yarn install\", shell=True))\r\n    print(subprocess.run(\"yarn make\", shell=True))\r\n\r\n\r\ndef upload_file():\r\n    file_list = find_file_by_suffix(folder_path, suffix)\r\n    # \u521b\u5efaminio\u8fde\u63a5\uff0c\u8fd9\u91cc\u56e0\u4e3a\u6211\u4eec\u662fhttp\u7684\uff0c\u6240\u4ee5secure=False\r\n    client = Minio(\r\n        endpoint=endpoint,\r\n        access_key=access_key,\r\n        secure=False,\r\n        secret_key=secret_key,\r\n    )\r\n\r\n    # \u68c0\u67e5bucket\u662f\u5426\u5b58\u5728\uff0c\u4e0d\u5b58\u5728\u5c31\u521b\u5efabucket\r\n    found = client.bucket_exists(bucket)\r\n    if not found:\r\n        client.make_bucket(bucket)\r\n    else:\r\n        print(\"Bucket 'electronjs' already exists\")\r\n\r\n    # \u4e0a\u4f20\u6587\u4ef6\u5230bucket\u91cc\r\n    for file in file_list:\r\n        name = os.path.basename(file)\r\n        client.fput_object(\r\n            bucket, name, file,\r\n        )\r\n        print(\r\n            \"'\" + file + \"' is successfully uploaded as \"\r\n                         \"object '\" + name + \"' to bucket '\" + bucket + \"'.\"\r\n        )\r\n\r\n\r\nif __name__ == \"__main__\":\r\n    get_environment()\r\n    yarn_make()\r\n    try:\r\n        upload_file()\r\n    except S3Error as exc:\r\n        print(\"error occurred.\", exc)\r<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">Dockerfile<\/h4>\n\n\n\n<p>\u53d6\u4e00\u4e2anode16\u7248\u672c\u7684debian\u7cfb\u7edf\uff0c\u4f7f\u7528\u56fd\u5185\u6e90\u5b89\u88c5\u6211\u4eec\u5728\u4e4b\u524d\u5217\u51fa\u6765\u8981\u7528\u7684\u5de5\u5177\uff0c\u7136\u540e\u6307\u5b9a\u7a0b\u5e8f\u5165\u53e3\u662f\u6211\u4eec\u7684python\u7a0b\u5e8f\u3002\u7f16\u5199\u5b8c\u540e\uff0c\u4f7f\u7528docker build -t drone-electron-minio-plugin:0.1.0 . \u505a\u4e00\u4e2a\u955c\u50cf\u4e0a\u4f20\u5230\u79c1\u4ed3\u91cc<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>FROM node:16-buster\nRUN npm config set registry https:\/\/mirrors.huaweicloud.com\/repository\/npm\/ \\\n    &amp;&amp; npm config set disturl https:\/\/mirrors.huaweicloud.com\/nodejs \\\n    &amp;&amp; npm config set sass_binary_site https:\/\/mirrors.huaweicloud.com\/node-sass \\\n    &amp;&amp; npm config set phantomjs_cdnurl https:\/\/mirrors.huaweicloud.com\/phantomjs \\\n    &amp;&amp; npm config set chromedriver_cdnurl https:\/\/mirrors.huaweicloud.com\/chromedriver \\\n    &amp;&amp; npm config set operadriver_cdnurl https:\/\/mirrors.huaweicloud.com\/operadriver \\\n    &amp;&amp; npm config set electron_mirror https:\/\/mirrors.huaweicloud.com\/electron\/ \\\n    &amp;&amp; npm config set python_mirror https:\/\/mirrors.huaweicloud.com\/python \\\n    &amp;&amp; npm config set canvas_binary_host_mirror https:\/\/npm.taobao.org\/mirrors\/node-canvas-prebuilt\/ \\\n    &amp;&amp; npm install -g npm@8.2.0 \\\n    &amp;&amp; yarn config set registry https:\/\/mirrors.huaweicloud.com\/repository\/npm\/ \\\n    &amp;&amp; yarn config set disturl https:\/\/mirrors.huaweicloud.com\/nodejs \\\n    &amp;&amp; yarn config set sass_binary_site https:\/\/mirrors.huaweicloud.com\/node-sass \\\n    &amp;&amp; yarn config set phantomjs_cdnurl https:\/\/mirrors.huaweicloud.com\/phantomjs \\\n    &amp;&amp; yarn config set chromedriver_cdnurl https:\/\/mirrors.huaweicloud.com\/chromedriver \\\n    &amp;&amp; yarn config set operadriver_cdnurl https:\/\/mirrors.huaweicloud.com\/operadriver \\\n    &amp;&amp; yarn config set electron_mirror https:\/\/mirrors.huaweicloud.com\/electron\/ \\\n    &amp;&amp; yarn config set python_mirror https:\/\/mirrors.huaweicloud.com\/python \\\n    &amp;&amp; yarn config set canvas_binary_host_mirror https:\/\/npm.taobao.org\/mirrors\/node-canvas-prebuilt\/ \\\n    &amp;&amp; yarn global add electron@v16.0.2 electron-forge electron-prebuilt-compile\\\n    &amp;&amp; sed -i \"s@http:\/\/ftp.debian.org@https:\/\/repo.huaweicloud.com@g\" \/etc\/apt\/sources.list \\\n    &amp;&amp; sed -i \"s@http:\/\/security.debian.org@https:\/\/repo.huaweicloud.com@g\" \/etc\/apt\/sources.list \\\n    &amp;&amp; sed -i \"s@http:\/\/deb.debian.org@https:\/\/repo.huaweicloud.com@g\" \/etc\/apt\/sources.list \\\n    &amp;&amp; apt update \\\n    &amp;&amp; apt install -y fakeroot dpkg rpm python3 python3-pip\nADD . .   \nWORKDIR . \nRUN pip3 install -r .\/requirements.txt -i https:\/\/pypi.tuna.tsinghua.edu.cn\/simple\n#CMD &#91;\"python3\",\"\/main.py\"]\nWORKDIR \/drone\/src\nENTRYPOINT &#91;\"python3\", \"\/main.py\"]<\/code><\/pre>\n\n\n\n<h4 class=\"wp-block-heading\">requirements.txt<\/h4>\n\n\n\n<pre class=\"wp-block-code\"><code>minio==7.1.2\r<\/code><\/pre>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">electron\u4ed3\u5e93\u4ee3\u7801<\/h2>\n\n\n\n<p>\u6211\u4eec\u7684electron\u4ed3\u5e93\u91cc\u8981\u6dfb\u52a0\u4e00\u4e2a.drone.yml\u6587\u4ef6\u548c\u5bf9package.json\u7a0d\u5fae\u8fdb\u884c\u4e00\u4e9b\u4fee\u6539<\/p>\n\n\n\n<h4 class=\"wp-block-heading\">package.json<\/h4>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"647\" height=\"714\" src=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-10.png\" alt=\"\" class=\"wp-image-1062\" srcset=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-10.png 647w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-10-272x300.png 272w\" sizes=\"auto, (max-width: 647px) 100vw, 647px\" \/><\/figure>\n\n\n\n<h4 class=\"wp-block-heading\">.drone.yml<\/h4>\n\n\n\n<p>droneCI\u7684\u6d41\u6c34\u7ebf\u6587\u4ef6\uff0c\u4f7f\u7528\u4e86\u6211\u4eec\u5728\u4e0a\u4e00\u8282\u91ccbuild\u51fa\u6765\u7684drone\u63d2\u4ef6\u955c\u50cf<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"708\" height=\"795\" src=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-12.png\" alt=\"\" class=\"wp-image-1064\" srcset=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-12.png 708w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-12-267x300.png 267w\" sizes=\"auto, (max-width: 708px) 100vw, 708px\" \/><\/figure>\n\n\n\n<hr class=\"wp-block-separator\"\/>\n\n\n\n<h2 class=\"wp-block-heading\">\u6d41\u6c34\u7ebf\u6f14\u793a<\/h2>\n\n\n\n<h4 class=\"wp-block-heading\">\u9700\u8981\u4eba\u624b\u52a8\u64cd\u4f5c\u7684<\/h4>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"566\" height=\"272\" src=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-13.png\" alt=\"\" class=\"wp-image-1065\" srcset=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-13.png 566w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-13-300x144.png 300w\" sizes=\"auto, (max-width: 566px) 100vw, 566px\" \/><\/figure>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-14.png\" alt=\"\" class=\"wp-image-1066\" width=\"779\" height=\"399\" srcset=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-14.png 779w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-14-300x154.png 300w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-14-768x393.png 768w\" sizes=\"auto, (max-width: 779px) 100vw, 779px\" \/><\/figure>\n\n\n\n<h4 class=\"wp-block-heading\">\u6d41\u6c34\u7ebf\u81ea\u52a8\u64cd\u4f5c\u7684<\/h4>\n\n\n\n<figure class=\"wp-block-image size-large is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-15-1024x526.png\" alt=\"\" class=\"wp-image-1067\" width=\"1024\" height=\"526\" srcset=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-15-1024x526.png 1024w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-15-300x154.png 300w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-15-768x394.png 768w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-15-1536x789.png 1536w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-15.png 1646w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"669\" height=\"434\" src=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-16.png\" alt=\"\" class=\"wp-image-1068\" srcset=\"https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-16.png 669w, https:\/\/www.yinyubo.com\/wp-content\/uploads\/2021\/12\/image-16-300x195.png 300w\" sizes=\"auto, (max-width: 669px) 100vw, 669px\" \/><\/figure>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u80cc\u666f \u56e0\u4e3a\u6211\u4eec\u7684electron\u7a0b\u5e8f\u5df2\u7ecf\u5f00\u53d1\u5b8c\u6210\uff0c\u671f\u671b\u8981\u80fd\u5f00\u53d1\u4eba\u5458\u6bcf\u6b21\u4e0a\u4f20\u4ee3\u7801\uff0c\u6253\u4e86tag\u5c31\u81ea\u52a8build\u4e00\u4efd [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,5,7],"tags":[],"class_list":["post-1060","post","type-post","status-publish","format-standard","hentry","category-k8s","category-python","category-7"],"_links":{"self":[{"href":"https:\/\/www.yinyubo.com\/index.php?rest_route=\/wp\/v2\/posts\/1060","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.yinyubo.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.yinyubo.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.yinyubo.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.yinyubo.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1060"}],"version-history":[{"count":2,"href":"https:\/\/www.yinyubo.com\/index.php?rest_route=\/wp\/v2\/posts\/1060\/revisions"}],"predecessor-version":[{"id":1071,"href":"https:\/\/www.yinyubo.com\/index.php?rest_route=\/wp\/v2\/posts\/1060\/revisions\/1071"}],"wp:attachment":[{"href":"https:\/\/www.yinyubo.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1060"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.yinyubo.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1060"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.yinyubo.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1060"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}