{"id":127238,"date":"2020-06-04T16:55:32","date_gmt":"2020-06-04T08:55:32","guid":{"rendered":"http:\/\/4563.org\/?p=127238"},"modified":"2020-06-04T16:55:32","modified_gmt":"2020-06-04T08:55:32","slug":"%e5%85%b3%e4%ba%8e-github-actions-%e7%9a%84%e6%95%8f%e6%84%9f%e4%bf%a1%e6%81%af%e9%9a%90%e8%97%8f","status":"publish","type":"post","link":"http:\/\/4563.org\/?p=127238","title":{"rendered":"\u5173\u4e8e github actions \u7684\u654f\u611f\u4fe1\u606f\u9690\u85cf"},"content":{"rendered":"<div>\n<div>\n<div>\n<h1>                  \u5173\u4e8e github actions \u7684\u654f\u611f\u4fe1\u606f\u9690\u85cf               <\/h1>\n<p> <\/p>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : AlisaDestiny <\/span>  <span><i><\/i> 11<\/span> <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<\/p><\/div>\n<div isfirst=\"1\"> <\/p>\n<p>\u5728\u4f7f\u7528 github actions \u7684\u65f6\u5019\u6211\u53d1\u73b0\u5b83\u9690\u85cf logs \u4e2d\u7684\u654f\u611f\u4fe1\u606f\u5e76\u4e0d\u662f\u7b80\u5355\u5730\u66ff\u6362\u3002<\/p>\n<p>\u6bd4\u5982\u4f60\u5728 secrets \u4e2d\u968f\u610f\u6dfb\u52a0\u4e00\u4e2a\u503c\uff1a<\/p>\n<pre><code>TOKEN=balabalabala <\/code><\/pre>\n<p>\u5728 run \u4e2d\u6267\u884c\u4e0b\u9762\u7684\u547d\u4ee4\uff1a<\/p>\n<pre><code>echo \"abcdef${{ TOKEN }}ghijklmn\" | base64 <\/code><\/pre>\n<p>logs \u4e2d\u7684\u654f\u611f\u4fe1\u606f\u8fd8\u662f\u4f1a\u88ab\u9690\u85cf\u6389\uff0c\u8f93\u51fa\u5c31\u7c7b\u4f3c\u4e0b\u9762\u8fd9\u6837\u3002<\/p>\n<pre><code>aCDdafaEFadfa************acDefaf= <\/code><\/pre>\n<p>\u60f3\u95ee\u4e0b\u8fd9\u662f\u600e\u4e48\u5b9e\u73b0\u7684\uff0c\u6211\u539f\u4ee5\u4e3a\u53ea\u662f\u7b80\u5355\u7684 replace \u3002<\/p>\n<\/p><\/div>\n<div> <b>\u5927\u4f6c\u6709\u8a71\u8aaa<\/b> (<span>4<\/span>)        <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<ul>\n<li data-pid=\"2071682\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : Anthony117 <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u8bd5\u8fc7\u66f4\u590d\u6742\u7684\u5904\u7406\u5417\uff1f\u53ef\u80fd\u53ea\u662f\u521a\u597d\u987a\u4fbf\u4e5f replace \u4e86 base64                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"2071683\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : xiqingongzi <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             https:\/\/github.com\/actions\/runner\/blob\/master\/src\/Sdk\/Common\/Common\/Utility\/SecretUtility.cs#L85-L224                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"2071684\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u4e3b<\/span> <span>\u8cc7\u6df1\u5927\u4f6c : AlisaDestiny <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @Anthony117 \u4f60\u5012\u662f\u63d0\u9192\u4e86\u6211\uff0c\u6309\u7167\u4f60\u8bf4\u7684\u6211\u628a base64 \u6539\u6210\u4e86 xxd -ps \u5c31\u4e0d\u884c\u4e86\uff0c\u4f60\u731c\u5bf9\u4e86\uff0cbase64 \u786e\u5b9e\u662f\u7279\u6b8a\u5b9a\u5236\u8fc7\u7684\u3002                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"2071685\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : xdays <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u7ec6\u8282                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li>\n","protected":false},"excerpt":{"rendered":"<p>\u5173\u4e8e github actions&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[],"tags":[],"_links":{"self":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/127238"}],"collection":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=127238"}],"version-history":[{"count":0,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/127238\/revisions"}],"wp:attachment":[{"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=127238"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=127238"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=127238"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}