{
    "componentChunkName": "component---src-templates-issues-tsx",
    "path": "/issues/587",
    "result": {"data":{"issuesJson":{"id":"d8d5886c-1878-5ef6-b180-256e1949fa4b","title":"hashicorp/vault: 一个用于密钥管理、加密服务和访问权限管理的工具","number":587,"bodyHTML":"<div align=\"center\" dir=\"auto\">\n<p dir=\"auto\"><a target=\"_blank\" rel=\"noopener noreferrer nofollow\" href=\"https://camo.githubusercontent.com/a15b413168923d02e21292705ceaf86b92675f98e250c5c896a02ba7504a6eae/68747470733a2f2f63646e2e6a7364656c6976722e6e65742f67682f657279616a662f7475406d61696e2f696d672f696d6167655f32303234303432305f3231343430382e676966\"><img src=\"https://camo.githubusercontent.com/a15b413168923d02e21292705ceaf86b92675f98e250c5c896a02ba7504a6eae/68747470733a2f2f63646e2e6a7364656c6976722e6e65742f67682f657279616a662f7475406d61696e2f696d672f696d6167655f32303234303432305f3231343430382e676966\" width=\"100%\" height=\"3\" data-animated-image=\"\" data-canonical-src=\"https://cdn.jsdelivr.net/gh/eryajf/tu@main/img/image_20240420_214408.gif\" style=\"max-width: 100%; height: auto; max-height: 3px;\"></a><br><br></p>\n<markdown-accessiblity-table><table role=\"table\">\n<thead>\n<tr>\n<th align=\"right\">Repos</th>\n<th align=\"left\"><a href=\"https://github.com/hashicorp/vault\">hashicorp/vault</a></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td align=\"right\"><strong>Views</strong></td>\n<td align=\"left\"><a href=\"https://github.com/opsre/awesome-ops\"><img src=\"https://camo.githubusercontent.com/c804b26f425f6a5950608f7868c24e6ab4328b837939e1a3fb0c435e43667d9d/68747470733a2f2f76696577732e77686174696c656172656e65642e746f6461792f76696577732f6769746875622f6861736869636f72702f7661756c742e737667\" alt=\"views\" data-canonical-src=\"https://views.whatilearened.today/views/github/hashicorp/vault.svg\" style=\"max-width: 100%;\"></a></td>\n</tr>\n<tr>\n<td align=\"right\"><strong>Stars</strong></td>\n<td align=\"left\"><a href=\"https://github.com/opsre/awesome-ops\"><img src=\"https://camo.githubusercontent.com/a801f4e9dc6b8d178f878d04ef5e009309ac653487a188b4092572e72c7de119/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f73746172732f6861736869636f72702f7661756c743f636f6c6f723d663266303864266c6f676f3d556e64657274616c65266c6f676f436f6c6f723d656234363330\" alt=\"stars\" data-canonical-src=\"https://img.shields.io/github/stars/hashicorp/vault?color=f2f08d&amp;logo=Undertale&amp;logoColor=eb4630\" style=\"max-width: 100%;\"></a></td>\n</tr>\n<tr>\n<td align=\"right\"><strong>Forks</strong></td>\n<td align=\"left\"><a href=\"https://github.com/opsre/awesome-ops\"><img src=\"https://camo.githubusercontent.com/2749cd5735d19ed006b30c624f7ba5f613cc08260b6e3fb37b76af1fb2d5f2b3/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f666f726b732f6861736869636f72702f7661756c743f636f6c6f723d626138366562266c6f676f3d48616e647368616b65266c6f676f436f6c6f723d656136616136\" alt=\"forks\" data-canonical-src=\"https://img.shields.io/github/forks/hashicorp/vault?color=ba86eb&amp;logo=Handshake&amp;logoColor=ea6aa6\" style=\"max-width: 100%;\"></a></td>\n</tr>\n<tr>\n<td align=\"right\"><strong>License</strong></td>\n<td align=\"left\"><a href=\"https://github.com/opsre/awesome-ops\"><img src=\"https://camo.githubusercontent.com/0c93ca71e73bb599dbfbd81eb5bbb82f63a427dc55ced5d8a7de2d4025f1f1c5/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c2d4e4f4e452d626c75653f6c6f676f3d756e6c6963656e7365\" alt=\"license\" data-canonical-src=\"https://img.shields.io/badge/L-NONE-blue?logo=unlicense\" style=\"max-width: 100%;\"></a></td>\n</tr>\n<tr>\n<td align=\"right\"><strong>UpdatedAt</strong></td>\n<td align=\"left\"><a href=\"https://github.com/opsre/awesome-ops\"><img src=\"https://camo.githubusercontent.com/4e4697c6c50cdf3ceb0a755c5861bfc21887a3f623e9da84d3365471eee15ca2/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6173742d636f6d6d69742f6861736869636f72702f7661756c743f646973706c61795f74696d657374616d703d636f6d6d6974746572266c6f676f3d64617461253341696d616765253246706e672533426261736536342532436956424f5277304b47676f414141414e5355684555674141414234414141416543415941414141374d4b3669414141414358424957584d41414173544141414c457745416d7077594141414648556c45515652346e4c5658375539615678776d3236646c582532466468627825324232253246516e626b7655627264554151674a4a496655444e574454546d4f76314651554661504a346b7573725630314a7431734e70637453327533626f745a746d786439744a5346536f714b71494635625944464c436f76436c656673747a4a387758524c445a4c7a6e6b634f343535376e3364332532466e655a3472454f515a74315771462532423858467234253242664f4c4565326a6f59307a776638546f795a50766a45676b4c592532426b306d6d72584f36644b696e787a476b30666a5430782532425279723055716e6359637a4d317263347451253242497270324c4758646f344e4334567657715453373277716c632532427231334f527269364b6458646e624f484c6c776c7a4a70524b6e3657342532424b36706f4f434e6e494166486a253246253242776168495a4234764b6e715a6630714a704e49716c2532467638545530634e6c3572627963337730516e54703379324c54614a374d314e617844723266526e315370504736476961323174664533345463614f617931694d55564f5146624659714957536f31573854694156616e43306576584f4542375770313448466232327a453566714c4f433545524c515769644e614e49347545636339693768634a6c644868324e57725135674464624f6c7061756d49754c62326174415144506e7a3062384e6257636d785656524a33486d7870536377777a4f4a6d4b44524765384c6c435a444c4739673754496e5631516c376462586256316533675430574b697243466f6d6b5079767758466c5a474a4f6a563625324253743634757564445a4f55354555636f782532464d455144567674364d62634e3237593341797a687633737061557242365a3971724a534f3139657a6a387032704c426b4a792532426343484a7857493567573574636652527a31645531394766476b6f7539505a4f34736d52396a4746777065783444793362766e6d4b79706f74625531335669646a71595a68726a343972764d457425324625324659714c7a396430304e6a57253246637a67796f394f35317a7336614e6c6f354644747530445a675146686c47584a30644241446f4e6864367576703657686f617967374e394c564748386d443462253246486e667455516f4e4734764c51306769784d716c5725324234714f6a744e48446733723166365969525347785279375576714c62395534716b716e78504f4e7661356c447048723125324279794b524e4b57425a793565644d554842326d3572792532422532424551772532427a6766347a6f39253246306f634e3357527a4c4277344a2532424a7950574372716d4967475974554f735744346f785a46516f50556a4770564871493425324661666b51504336665a5165654d31253242764c7549516e6a754257514444437363726d485039656f4e5041744271664f6e5875614b25324268364a45624772732532427076764d6d78654962683836336162565065597953456f39464a48704e4d464a59253242503563575a6b6667374f3174537759436553514c54593345385130392532464256504a556c78516a7368543142736343593032723955445542667643484236367063665041336c794165336e6772332532463437584467614a7a736c7937787741364e5a746c555550437541487161536a5549502532427375653842525741432532464e6651374a5a505a35397330476a3756747049537a34685125324243706658474d4b685a63764c70554b7866574d386f68766637702532464f446a4842666356463849736b383267314648796b63564645253242555a414158343761452532464d6c34504f3530506e75683025324678346e6d637957507364774468427836436d6b4c562532466746446a594b784f4a4f4674623077517949684c39527943774b33414f664947703159464542686e4d4a634c525745624b644b516f55366e63545a6b494544696341792532463831645675454d3552775066657934784f7830496b25324649324e6e466b692532425761664f6f464959466367595a43797864376543556a626334416d46363566742532466b4d686b336f25324235686337734d4a79716a4a45477659466151464972375930775077384246415925324236253242766d6b3377367a7a5275444d6d5a5652736668385274413075455453443775434254364459514e36697665553066706b594c6a453671725672744f78654e4b553954484c5a4a396b4255324a427342685635416976422532466f4b61514e4b675043427744596149665a4334616454684f71463457454e56694c4a77566f586f62664c424b56773637414f6154734c6336355461564b32317651344c613939654b6359673576627873624f627a5451394e37554b4467554f3177446a6944494942736868357a746733396e514d4c535a4248344f7a424f55444551586d323036643366634c67737762585141345068634b336e6873775531427a3877765130395248472532466f597933656a6677424e6d746f59714c4130586741414141424a52553545726b4a676767253344253344266c6162656c3d557064617465644174\" alt=\"last-commit\" data-canonical-src=\"https://img.shields.io/github/last-commit/hashicorp/vault?display_timestamp=committer&amp;logo=data%3Aimage%2Fpng%3Bbase64%2CiVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAACXBIWXMAAAsTAAALEwEAmpwYAAAFHUlEQVR4nLVX7U9aVxwm26dlX%2Fdhbx%2B2%2FQnbkvUbrdUAQgJJIfUDNWDTTmOv1FQUFaPJ4kusrV01Jt1sNpctS2u3botZtmxd9tJSFSoqKqIF5bYDFLCovClefstzJ8wXRLDZLznkcO4557n3d3%2FneZ4rEOQZt1WqF%2B8XFr4%2BfOLEe2joY0zwf8ToyZPvjEgkLY%2Bk0mmrXO6dKinxzGk0fjT0x%2BRyr0UqncYczM1rc4tQ%2BIrp2LGXdo4NC4VvWqTS72wqlc%2Br13ORri6KdXdnbOHLlwlzJpRKn6W4%2BK6poOCNnIAfHj%2F%2BwahIZB4vKnqZf0qJpNIql%2Fv8TU0cNl5rbyc3w0QnTp3y2LTaJ7M1NaxDr2fRn1SpPG6Gia21tfE34TcaOay1iMUVOQFbFYqIWSo1W8TiAVanC0evXOEB7Wp14HFb22zE5fqLOC5ERLQWidNaNI4uEcc9i7hcJldHh2NWrQ5gDdbOlpaumIuLb2atAQDPnz0b8NbWcmxVVRJ3HmxpScwwzOJmKDRGe8LlCZDLG9g7TInV1Ql7dbXbV1e3gT0WKirCFomkPyvwXFlZGJOjV6%2BSt64uudDZOU5EUcox%2FMEQDVvt6MbcN27Y3Ayzhv3spaUrB6Z9qrJSO19ezj8p2pLBkJy%2BcCHJxWI5gW5tcfRRz1dU19GfGkou9PZO4smR9jGFwpex4Dy3bvnmKypotbU13VidjqYZhrj49rvMEt%2F%2FYqLz9d00NjW%2Fczgyo9O51zs6aNlo5FDtu0DZgQFhlGXJ0dBADoNhd6uvp6Whoayg7N9LVGH8mD4b%2FHnftUQoNG4vLQ0gixMqlW%2B4qOjtNHDg3r1f6YiRSGxRy7UvqLb9U4qkqnxPONva5lDpHr1%2ByyKRNKWBZy5edMUHB2m5ry%2B%2BEQw%2Bzgf4zo9%2F0ocN3WRzLBw4J%2BJyPWCrqmIgGYtUOsWD4oxZFQoPUjGpVHqI4%2FafkQPC6fZQeeM1%2BvLuIQnjuBWQDDCscrmHP9eoNPAtBqfOnXuaK%2Bh6JEbGrs%2BpvvMmxeIbh863abVPeYySEo9FJHpNMFJY%2BP5cWZkfg7O1tSwYCeSQLTY3E8Q09%2FBVPJUlxQjshT1BscCY02r9UDUBfvCHB66pcfPA3lyAe3ngr3%2F47XDgaJzsly7xwA6NZtlUUPCuAHqaSjUIP%2Bsue8BRWAC%2FNfQ7JZPZ59s0Gj7VtpISz4hQ%2BCpfXGMKhZcvLpUKxfWM8ohvf7p%2FODjHBfcVF8Isk82g1FHykcVFE%2BUZAAX47aE%2FMl4PO50Pnuh0%2Fx4nmcyWPsdwDhBx6CmkLV%2FgFDjYKxOJOFtb0wQyIhL9RyCwK3AOfIGp1YFEBhnMJcLRWEbKdKQoU6ncTZkIEDicAy%2F81dVuEM5RwPfey4xOx0Ik%2FI2NnFki%2BWafOoFIYFcgYZCyxd7eCUjbc4AmF65ft%2FkMhk3o%2B5hc7sMJyqjJEGvYFaQFIr7Y0wPw8BFAY%2B6%2Bvmk3w6zzRuDMmZVRsfh8RtA0uETSD7uCBT6DYQN6iveU0fpkYLjE6qrVrtOxeNKU9THLZJ9kBU2JBsBhV5AivB%2FoKaQNKgPCBwDYaIfZC4adThOqF4WENViLJwVoXobfLBKVw67AOaTsLc65TaVK21vQ4La99eKcYg5vbxsbObzTQ9N7UKDgUO1wDjiDIIBshh5ztg39nQMLSZBH4OzBOUDEQXm206d3fcLgswbXQA4PhcK3nhswU1Bz8wvQ09RHG%2FoYy3ejfwBNmtoYqLA0XgAAAABJRU5ErkJggg%3D%3D&amp;label=UpdatedAt\" style=\"max-width: 100%;\"></a></td>\n</tr>\n<tr>\n<td align=\"right\"><strong>CreatedAt</strong></td>\n<td align=\"left\"><a href=\"https://github.com/opsre/awesome-ops\"><img src=\"https://camo.githubusercontent.com/e78f606b8023f3384919d962a8a7e0159da007bcd409ccfb35f488c71f3da98d/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f637265617465642d61742f6861736869636f72702f7661756c743f6c6f676f3d64617461253341696d616765253246706e672533426261736536342532436956424f5277304b47676f414141414e5355684555674141414234414141416543415941414141374d4b3669414141414358424957584d41414173544141414c457745416d7077594141414648556c45515652346e4c5658375539615678776d3236646c582532466468627825324232253246516e626b7655627264554151674a4a496655444e574454546d4f76314651554661504a346b7573725630314a7431734e70637453327533626f745a746d786439744a5346536f714b71494635625944464c436f76436c656673747a4a387758524c445a4c7a6e6b634f343535376e3364332532466e655a3472454f515a74315771462532423858467234253242664f4c4565326a6f59307a776638546f795a50766a45676b4c592532426b306d6d72584f36644b696e787a476b30666a5430782532425279723055716e6359637a4d317263347451253242497270324c4758646f344e4334567657715453373277716c632532427231334f527269364b6458646e624f484c6c776c7a4a70524b6e3657342532424b36706f4f434e6e494166486a253246253242776168495a4234764b6e715a6630714a704e49716c2532467638545530634e6c3572627963337730516e54703379324c54614a374d314e617844723266526e315370504736476961323174664533345463614f617931694d55564f5146624659714957536f31573854694156616e43306576584f4542375770313448466232327a453566714c4f433545524c515769644e614e49347545636339693768634a6c644868324e57725135674464624f6c7061756d49754c62326174415144506e7a3062384e6257636d785656524a33486d7870536377777a4f4a6d4b44524765384c6c435a444c4739673754496e5631516c376462586256316533675430574b697243466f6d6b5079767758466c5a474a4f6a563625324253743634757564445a4f55354555636f782532464d455144567674364d62634e3237593341797a687633737061557242365a3971724a534f3139657a6a387032704c426b4a792532426343484a7857493567573574636652527a31645531394766476b6f7539505a4f34736d52396a4746777065783444793362766e6d4b79706f74625531335669646a71595a68726a343972764d457425324625324659714c7a396430304e6a57253246637a67796f394f35317a7336614e6c6f354644747530445a675146686c47584a30644241446f4e6864367576703657686f617967374e394c564748386d443462253246486e667455516f4e4734764c51306769784d716c5725324234714f6a744e48446733723166365969525347785279375576714c62395534716b716e78504f4e7661356c447048723125324279794b524e4b57425a793565644d554842326d3572792532422532424551772532427a6766347a6f39253246306f634e3357527a4c4277344a2532424a7950574372716d4967475974554f735744346f785a46516f50556a4770564871493425324661666b51504336665a5165654d31253242764c7549516e6a754257514444437363726d485039656f4e5041744271664f6e5875614b25324268364a45624772732532427076764d6d78654962683836336162565065597953456f39464a48704e4d464a59253242503563575a6b6667374f3174537759436553514c54593345385130392532464256504a556c78516a7368543142736343593032723955445542667643484236367063665041336c794165336e6772332532463437584467614a7a736c7937787741364e5a746c555550437541487161536a5549502532427375653842525741432532464e6651374a5a505a35397330476a3756747049537a34685125324243706658474d4b685a63764c70554b7866574d386f68766637702532464f446a4842666356463849736b383267314648796b63564645253242555a414158343761452532464d6c34504f3530506e75683025324678346e6d637957507364774468427836436d6b4c562532466746446a594b784f4a4f4674623077517949684c39527943774b33414f664947703159464542686e4d4a634c525745624b644b516f55366e63545a6b494544696341792532463831645675454d3552775066657934784f7830496b25324649324e6e466b692532425761664f6f464959466367595a43797864376543556a626334416d46363566742532466b4d686b336f25324235686337734d4a79716a4a45477659466151464972375930775077384246415925324236253242766d6b3377367a7a5275444d6d5a5652736668385274413075455453443775434254364459514e36697665553066706b594c6a453671725672744f78654e4b553954484c5a4a396b4255324a427342685635416976422532466f4b61514e4b675043427744596149665a4334616454684f71463457454e56694c4a77566f586f62664c424b56773637414f6154734c6336355461564b32317651344c613939654b6359673576627873624f627a5451394e37554b4467554f3177446a6944494942736868357a746733396e514d4c535a4248344f7a424f55444551586d323036643366634c67737762585141345068634b336e6873775531427a3877765130395248472532466f597933656a6677424e6d746f59714c4130586741414141424a52553545726b4a676767253344253344266c6162656c3d437265617465644174\" alt=\"create-at\" data-canonical-src=\"https://img.shields.io/github/created-at/hashicorp/vault?logo=data%3Aimage%2Fpng%3Bbase64%2CiVBORw0KGgoAAAANSUhEUgAAAB4AAAAeCAYAAAA7MK6iAAAACXBIWXMAAAsTAAALEwEAmpwYAAAFHUlEQVR4nLVX7U9aVxwm26dlX%2Fdhbx%2B2%2FQnbkvUbrdUAQgJJIfUDNWDTTmOv1FQUFaPJ4kusrV01Jt1sNpctS2u3botZtmxd9tJSFSoqKqIF5bYDFLCovClefstzJ8wXRLDZLznkcO4557n3d3%2FneZ4rEOQZt1WqF%2B8XFr4%2BfOLEe2joY0zwf8ToyZPvjEgkLY%2Bk0mmrXO6dKinxzGk0fjT0x%2BRyr0UqncYczM1rc4tQ%2BIrp2LGXdo4NC4VvWqTS72wqlc%2Br13ORri6KdXdnbOHLlwlzJpRKn6W4%2BK6poOCNnIAfHj%2F%2BwahIZB4vKnqZf0qJpNIql%2Fv8TU0cNl5rbyc3w0QnTp3y2LTaJ7M1NaxDr2fRn1SpPG6Gia21tfE34TcaOay1iMUVOQFbFYqIWSo1W8TiAVanC0evXOEB7Wp14HFb22zE5fqLOC5ERLQWidNaNI4uEcc9i7hcJldHh2NWrQ5gDdbOlpaumIuLb2atAQDPnz0b8NbWcmxVVRJ3HmxpScwwzOJmKDRGe8LlCZDLG9g7TInV1Ql7dbXbV1e3gT0WKirCFomkPyvwXFlZGJOjV6%2BSt64uudDZOU5EUcox%2FMEQDVvt6MbcN27Y3Ayzhv3spaUrB6Z9qrJSO19ezj8p2pLBkJy%2BcCHJxWI5gW5tcfRRz1dU19GfGkou9PZO4smR9jGFwpex4Dy3bvnmKypotbU13VidjqYZhrj49rvMEt%2F%2FYqLz9d00NjW%2Fczgyo9O51zs6aNlo5FDtu0DZgQFhlGXJ0dBADoNhd6uvp6Whoayg7N9LVGH8mD4b%2FHnftUQoNG4vLQ0gixMqlW%2B4qOjtNHDg3r1f6YiRSGxRy7UvqLb9U4qkqnxPONva5lDpHr1%2ByyKRNKWBZy5edMUHB2m5ry%2B%2BEQw%2Bzgf4zo9%2F0ocN3WRzLBw4J%2BJyPWCrqmIgGYtUOsWD4oxZFQoPUjGpVHqI4%2FafkQPC6fZQeeM1%2BvLuIQnjuBWQDDCscrmHP9eoNPAtBqfOnXuaK%2Bh6JEbGrs%2BpvvMmxeIbh863abVPeYySEo9FJHpNMFJY%2BP5cWZkfg7O1tSwYCeSQLTY3E8Q09%2FBVPJUlxQjshT1BscCY02r9UDUBfvCHB66pcfPA3lyAe3ngr3%2F47XDgaJzsly7xwA6NZtlUUPCuAHqaSjUIP%2Bsue8BRWAC%2FNfQ7JZPZ59s0Gj7VtpISz4hQ%2BCpfXGMKhZcvLpUKxfWM8ohvf7p%2FODjHBfcVF8Isk82g1FHykcVFE%2BUZAAX47aE%2FMl4PO50Pnuh0%2Fx4nmcyWPsdwDhBx6CmkLV%2FgFDjYKxOJOFtb0wQyIhL9RyCwK3AOfIGp1YFEBhnMJcLRWEbKdKQoU6ncTZkIEDicAy%2F81dVuEM5RwPfey4xOx0Ik%2FI2NnFki%2BWafOoFIYFcgYZCyxd7eCUjbc4AmF65ft%2FkMhk3o%2B5hc7sMJyqjJEGvYFaQFIr7Y0wPw8BFAY%2B6%2Bvmk3w6zzRuDMmZVRsfh8RtA0uETSD7uCBT6DYQN6iveU0fpkYLjE6qrVrtOxeNKU9THLZJ9kBU2JBsBhV5AivB%2FoKaQNKgPCBwDYaIfZC4adThOqF4WENViLJwVoXobfLBKVw67AOaTsLc65TaVK21vQ4La99eKcYg5vbxsbObzTQ9N7UKDgUO1wDjiDIIBshh5ztg39nQMLSZBH4OzBOUDEQXm206d3fcLgswbXQA4PhcK3nhswU1Bz8wvQ09RHG%2FoYy3ejfwBNmtoYqLA0XgAAAABJRU5ErkJggg%3D%3D&amp;label=CreatedAt\" style=\"max-width: 100%;\"></a></td>\n</tr>\n</tbody>\n</table></markdown-accessiblity-table>\n<a href=\"https://github.com/opsre/awesome-ops\">\n</a><p dir=\"auto\"><a href=\"https://github.com/opsre/awesome-ops\"><img src=\"https://camo.githubusercontent.com/b964a36ea4078c39f603d46a29436371c7541a2f26e0228d7b21b9d9805b43d3/68747470733a2f2f736f6369616c6966792e6769742e63692f6f707372652f617765736f6d652d6f70732f696d6167653f6465736372697074696f6e3d3126666f6e743d42697474657226666f726b733d31266973737565733d31266c616e67756167653d31266c6f676f3d6874747073253341253246253246617661746172732e67697468756275736572636f6e74656e742e636f6d25324675253246313838353638303230266e616d653d31266f776e65723d31267061747465726e3d436972637569742b426f6172642670756c6c733d31267374617267617a6572733d31267468656d653d4c69676874\" alt=\"\" data-canonical-src=\"https://socialify.git.ci/opsre/awesome-ops/image?description=1&amp;font=Bitter&amp;forks=1&amp;issues=1&amp;language=1&amp;logo=https%3A%2F%2Favatars.githubusercontent.com%2Fu%2F188568020&amp;name=1&amp;owner=1&amp;pattern=Circuit+Board&amp;pulls=1&amp;stargazers=1&amp;theme=Light\" style=\"max-width: 100%;\"></a></p>\n<a target=\"_blank\" rel=\"noopener noreferrer nofollow\" href=\"https://camo.githubusercontent.com/a15b413168923d02e21292705ceaf86b92675f98e250c5c896a02ba7504a6eae/68747470733a2f2f63646e2e6a7364656c6976722e6e65742f67682f657279616a662f7475406d61696e2f696d672f696d6167655f32303234303432305f3231343430382e676966\"><img src=\"https://camo.githubusercontent.com/a15b413168923d02e21292705ceaf86b92675f98e250c5c896a02ba7504a6eae/68747470733a2f2f63646e2e6a7364656c6976722e6e65742f67682f657279616a662f7475406d61696e2f696d672f696d6167655f32303234303432305f3231343430382e676966\" width=\"100%\" height=\"3\" data-animated-image=\"\" data-canonical-src=\"https://cdn.jsdelivr.net/gh/eryajf/tu@main/img/image_20240420_214408.gif\" style=\"max-width: 100%; height: auto; max-height: 3px;\"></a>\n</div>\n<h1 dir=\"auto\">Vault <a href=\"https://github.com/hashicorp/vault/actions/workflows/build.yml\"><img src=\"https://github.com/hashicorp/vault/actions/workflows/build.yml/badge.svg\" alt=\"build\" style=\"max-width: 100%;\"></a> <a href=\"https://github.com/hashicorp/vault/actions/workflows/ci.yml\"><img src=\"https://github.com/hashicorp/vault/actions/workflows/ci.yml/badge.svg\" alt=\"ci\" style=\"max-width: 100%;\"></a>  <a href=\"https://www.hashicorp.com/products/vault/?utm_source=github&amp;utm_medium=banner&amp;utm_campaign=github-vault-enterprise\" rel=\"nofollow\"><img src=\"https://camo.githubusercontent.com/575818e1f20d834def22b3a11b6052404147f521346b1a37711645cfcbeac3b8/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7661756c742d656e74657270726973652d79656c6c6f772e7376673f636f6c6f72423d37633837393726636f6c6f72413d303030303030\" alt=\"vault enterprise\" data-canonical-src=\"https://img.shields.io/badge/vault-enterprise-yellow.svg?colorB=7c8797&amp;colorA=000000\" style=\"max-width: 100%;\"></a></h1>\n<hr>\n<p dir=\"auto\"><strong>Please note</strong>: We take Vault's security and our users' trust very seriously. If you believe you have found a security issue in Vault, <em>please responsibly disclose</em> by contacting us at <a href=\"mailto:security@hashicorp.com\">security@hashicorp.com</a>.</p>\n<hr>\n<ul dir=\"auto\">\n<li>Website: <a href=\"https://developer.hashicorp.com/vault\" rel=\"nofollow\">developer.hashicorp.com/vault</a></li>\n<li>Announcement list: <a href=\"https://groups.google.com/group/hashicorp-announce\" rel=\"nofollow\">Google Groups</a></li>\n<li>Discussion forum: <a href=\"https://discuss.hashicorp.com/c/vault\" rel=\"nofollow\">Discuss</a></li>\n<li>Documentation: <a href=\"https://developer.hashicorp.com/vault/docs\" rel=\"nofollow\">https://developer.hashicorp.com/vault/docs</a></li>\n<li>Tutorials: <a href=\"https://developer.hashicorp.com/vault/tutorials\" rel=\"nofollow\">https://developer.hashicorp.com/vault/tutorials</a></li>\n<li>Certification exam: <a href=\"https://developer.hashicorp.com/certifications/security-automation\" rel=\"nofollow\">https://developer.hashicorp.com/certifications/security-automation</a></li>\n</ul>\n<p dir=\"auto\"><a target=\"_blank\" rel=\"noopener noreferrer\" href=\"https://github.com/hashicorp/vault/blob/f22d202cde2018f9455dec755118a9b84586e082/Vault_PrimaryLogo_Black.png\"><img width=\"300\" alt=\"Vault Logo\" src=\"https://github.com/hashicorp/vault/blob/f22d202cde2018f9455dec755118a9b84586e082/Vault_PrimaryLogo_Black.png\" style=\"max-width: 100%;\"></a></p>\n<p dir=\"auto\">Vault is a tool for securely accessing secrets. A secret is anything that you want to tightly control access to, such as API keys, passwords, certificates, and more. Vault provides a unified interface to any secret, while providing tight access control and recording a detailed audit log.</p>\n<p dir=\"auto\">A modern system requires access to a multitude of secrets: database credentials, API keys for external services, credentials for service-oriented architecture communication, etc. Understanding who is accessing what secrets is already very difficult and platform-specific. Adding on key rolling, secure storage, and detailed audit logs is almost impossible without a custom solution. This is where Vault steps in.</p>\n<p dir=\"auto\">The key features of Vault are:</p>\n<ul dir=\"auto\">\n<li>\n<p dir=\"auto\"><strong>Secure Secret Storage</strong>: Vault can store arbitrary key/value pairs. Vault encrypts data before writing it to persistent<br>\nstorage, so gaining access to the raw storage isn't enough to access<br>\nyour secrets. Vault can write to disk, <a href=\"https://www.consul.io\" rel=\"nofollow\">Consul</a>,<br>\nand more.</p>\n</li>\n<li>\n<p dir=\"auto\"><strong>Dynamic Secrets</strong>: Vault can generate secrets on-demand for some<br>\nsystems, such as AWS or SQL databases. For example, when an application<br>\nneeds to access an S3 bucket, it asks Vault for credentials, and Vault<br>\nwill generate an AWS keypair with valid permissions on demand. After<br>\ncreating these dynamic secrets, Vault will also automatically revoke them<br>\nafter the lease is up.</p>\n</li>\n<li>\n<p dir=\"auto\"><strong>Data Encryption</strong>: Vault can encrypt and decrypt data without storing<br>\nit. This allows security teams to define encryption parameters and<br>\ndevelopers to store encrypted data in a location such as a SQL database without<br>\nhaving to design their own encryption methods.</p>\n</li>\n<li>\n<p dir=\"auto\"><strong>Leasing and Renewal</strong>: Vault associates a <strong>lease</strong> with each secret.<br>\nAt the end of the lease, Vault automatically revokes the<br>\nsecret. Clients are able to renew leases via built-in renew APIs.</p>\n</li>\n<li>\n<p dir=\"auto\"><strong>Revocation</strong>: Vault has built-in support for secret revocation. Vault<br>\ncan revoke not only single secrets, but a tree of secrets, for example,<br>\nall secrets read by a specific user, or all secrets of a particular type.<br>\nRevocation assists in key rolling as well as locking down systems in the<br>\ncase of an intrusion.</p>\n</li>\n</ul>\n<h2 dir=\"auto\">Documentation, Getting Started, and Certification Exams</h2>\n<p dir=\"auto\">Documentation is available on the <a href=\"https://developer.hashicorp.com/vault/docs\" rel=\"nofollow\">Vault website</a>.</p>\n<p dir=\"auto\">If you're new to Vault and want to get started with security automation, please<br>\ncheck out our <a href=\"https://learn.hashicorp.com/collections/vault/getting-started\" rel=\"nofollow\">Getting Started guides</a><br>\non HashiCorp's learning platform. There are also <a href=\"https://learn.hashicorp.com/vault\" rel=\"nofollow\">additional guides</a><br>\nto continue your learning.</p>\n<p dir=\"auto\">For examples of how to interact with Vault from inside your application in different programming languages, see the <a href=\"https://github.com/hashicorp/vault-examples\">vault-examples</a> repo. An out-of-the-box <a href=\"https://github.com/hashicorp/hello-vault-go\">sample application</a> is also available.</p>\n<p dir=\"auto\">Show off your Vault knowledge by passing a certification exam. Visit the<br>\n<a href=\"https://www.hashicorp.com/certification/#hashicorp-certified-vault-associate\" rel=\"nofollow\">certification page</a><br>\nfor information about exams and find <a href=\"https://learn.hashicorp.com/collections/vault/certification\" rel=\"nofollow\">study materials</a><br>\non HashiCorp's learning platform.</p>\n<h2 dir=\"auto\">Developing Vault</h2>\n<p dir=\"auto\">If you wish to work on Vault itself or any of its built-in systems, you'll<br>\nfirst need <a href=\"https://www.golang.org\" rel=\"nofollow\">Go</a> installed on your machine.</p>\n<p dir=\"auto\">For local dev first make sure Go is properly installed, including setting up a<br>\n<a href=\"https://golang.org/doc/code.html#GOPATH\" rel=\"nofollow\">GOPATH</a>, then setting the<br>\n<a href=\"https://pkg.go.dev/cmd/go#hdr-Environment_variables\" rel=\"nofollow\">GOBIN</a> variable to <code class=\"notranslate\">$GOPATH/bin</code>.<br>\nEnsure that <code class=\"notranslate\">$GOPATH/bin</code> is in your path as some distributions bundle the old version<br>\nof build tools.</p>\n<p dir=\"auto\">Next, clone this repository. Vault uses <a href=\"https://github.com/golang/go/wiki/Modules\">Go Modules</a>,<br>\nso it is recommended that you clone the repository <em><strong>outside</strong></em> of the GOPATH.<br>\nYou can then download any required build tools by bootstrapping your environment:</p>\n<div class=\"highlight highlight-source-shell notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"$ make bootstrap\n...\"><pre class=\"notranslate\">$ make bootstrap\n...</pre></div>\n<p dir=\"auto\">To compile a development version of Vault, run <code class=\"notranslate\">make</code> or <code class=\"notranslate\">make dev</code>. This will<br>\nput the Vault binary in the <code class=\"notranslate\">bin</code> and <code class=\"notranslate\">$GOPATH/bin</code> folders:</p>\n<div class=\"highlight highlight-source-shell notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"$ make dev\n...\n$ bin/vault\n...\"><pre class=\"notranslate\">$ make dev\n...\n$ bin/vault\n...</pre></div>\n<p dir=\"auto\">To compile a development version of Vault with the UI, run <code class=\"notranslate\">make static-dist dev-ui</code>. This will<br>\nput the Vault binary in the <code class=\"notranslate\">bin</code> and <code class=\"notranslate\">$GOPATH/bin</code> folders:</p>\n<div class=\"highlight highlight-source-shell notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"$ make static-dist dev-ui\n...\n$ bin/vault\n...\"><pre class=\"notranslate\">$ make static-dist dev-ui\n...\n$ bin/vault\n...</pre></div>\n<p dir=\"auto\">To run tests, type <code class=\"notranslate\">make test</code>. Note: this requires Docker to be installed. If<br>\nthis exits with exit status 0, then everything is working!</p>\n<div class=\"highlight highlight-source-shell notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"$ make test\n...\"><pre class=\"notranslate\">$ make <span class=\"pl-c1\">test</span>\n...</pre></div>\n<p dir=\"auto\">If you're developing a specific package, you can run tests for just that<br>\npackage by specifying the <code class=\"notranslate\">TEST</code> variable. For example below, only<br>\n<code class=\"notranslate\">vault</code> package tests will be run.</p>\n<div class=\"highlight highlight-source-shell notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"$ make test TEST=./vault\n...\"><pre class=\"notranslate\">$ make <span class=\"pl-c1\">test</span> TEST=./vault\n...</pre></div>\n<h3 dir=\"auto\">Troubleshooting</h3>\n<p dir=\"auto\">If you encounter an error like <code class=\"notranslate\">could not read Username for 'https://github.com'</code> you may need to adjust your git config like so:</p>\n<div class=\"highlight highlight-source-shell notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"$ git config --global --add url.&quot;git@github.com:&quot;.insteadOf &quot;https://github.com/&quot;\"><pre class=\"notranslate\">$ git config --global --add url.<span class=\"pl-s\"><span class=\"pl-pds\">\"</span>git@github.com:<span class=\"pl-pds\">\"</span></span>.insteadOf <span class=\"pl-s\"><span class=\"pl-pds\">\"</span>https://github.com/<span class=\"pl-pds\">\"</span></span></pre></div>\n<h3 dir=\"auto\">Importing Vault</h3>\n<p dir=\"auto\">This repository publishes two libraries that may be imported by other projects:<br>\n<code class=\"notranslate\">github.com/hashicorp/vault/api</code> and <code class=\"notranslate\">github.com/hashicorp/vault/sdk</code>.</p>\n<p dir=\"auto\">Note that this repository also contains Vault (the product), and as with most Go<br>\nprojects, Vault uses Go modules to manage its dependencies. The mechanism to do<br>\nthat is the <a href=\"./go.mod\">go.mod</a> file. As it happens, the presence of that file<br>\nalso makes it theoretically possible to import Vault as a dependency into other<br>\nprojects. Some other projects have made a practice of doing so in order to take<br>\nadvantage of testing tooling that was developed for testing Vault itself. This<br>\nis not, and has never been, a supported way to use the Vault project. We aren't<br>\nlikely to fix bugs relating to failure to import <code class=\"notranslate\">github.com/hashicorp/vault</code><br>\ninto your project.</p>\n<p dir=\"auto\">See also the section \"Docker-based tests\" below.</p>\n<h3 dir=\"auto\">Acceptance Tests</h3>\n<p dir=\"auto\">Vault has comprehensive <a href=\"https://en.wikipedia.org/wiki/Acceptance_testing\" rel=\"nofollow\">acceptance tests</a><br>\ncovering most of the features of the secret and auth methods.</p>\n<p dir=\"auto\">If you're working on a feature of a secret or auth method and want to<br>\nverify it is functioning (and also hasn't broken anything else), we recommend<br>\nrunning the acceptance tests.</p>\n<p dir=\"auto\"><strong>Warning:</strong> The acceptance tests create/destroy/modify <em>real resources</em>, which<br>\nmay incur real costs in some cases. In the presence of a bug, it is technically<br>\npossible that broken backends could leave dangling data behind. Therefore,<br>\nplease run the acceptance tests at your own risk. At the very least,<br>\nwe recommend running them in their own private account for whatever backend<br>\nyou're testing.</p>\n<p dir=\"auto\">To run the acceptance tests, invoke <code class=\"notranslate\">make testacc</code>:</p>\n<div class=\"highlight highlight-source-shell notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"$ make testacc TEST=./builtin/logical/consul\n...\"><pre class=\"notranslate\">$ make testacc TEST=./builtin/logical/consul\n...</pre></div>\n<p dir=\"auto\">The <code class=\"notranslate\">TEST</code> variable is required, and you should specify the folder where the<br>\nbackend is. The <code class=\"notranslate\">TESTARGS</code> variable is recommended to filter down to a specific<br>\nresource to test, since testing all of them at once can sometimes take a very<br>\nlong time.</p>\n<p dir=\"auto\">Acceptance tests typically require other environment variables to be set for<br>\nthings such as access keys. The test itself should error early and tell<br>\nyou what to set, so it is not documented here.</p>\n<p dir=\"auto\">For more information on Vault Enterprise features, visit the <a href=\"https://www.hashicorp.com/products/vault/?utm_source=github&amp;utm_medium=referral&amp;utm_campaign=github-vault-enterprise\" rel=\"nofollow\">Vault Enterprise site</a>.</p>\n<h3 dir=\"auto\">Docker-based Tests</h3>\n<p dir=\"auto\">We have created an experimental new testing mechanism inspired by NewTestCluster.<br>\nAn example of how to use it:</p>\n<div class=\"highlight highlight-source-go notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"import (\n  &quot;testing&quot;\n  &quot;github.com/hashicorp/vault/sdk/helper/testcluster/docker&quot;\n)\n\nfunc Test_Something_With_Docker(t *testing.T) {\n  opts := &amp;docker.DockerClusterOptions{\n    ImageRepo: &quot;hashicorp/vault&quot;, // or &quot;hashicorp/vault-enterprise&quot;\n    ImageTag:    &quot;latest&quot;,\n  }\n  cluster := docker.NewTestDockerCluster(t, opts)\n  defer cluster.Cleanup()\n  \n  client := cluster.Nodes()[0].APIClient()\n  _, err := client.Logical().Read(&quot;sys/storage/raft/configuration&quot;)\n  if err != nil {\n    t.Fatal(err)\n  }\n}\"><pre class=\"notranslate\"><span class=\"pl-k\">import</span> (\n  <span class=\"pl-s\">\"testing\"</span>\n  <span class=\"pl-s\">\"github.com/hashicorp/vault/sdk/helper/testcluster/docker\"</span>\n)\n\n<span class=\"pl-k\">func</span> <span class=\"pl-s1\">Test_Something_With_Docker</span>(<span class=\"pl-s1\">t</span> <span class=\"pl-c1\">*</span>testing.<span class=\"pl-smi\">T</span>) {\n  <span class=\"pl-s1\">opts</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-c1\">&amp;</span>docker.<span class=\"pl-smi\">DockerClusterOptions</span>{\n    <span class=\"pl-s1\">ImageRepo</span>: <span class=\"pl-s\">\"hashicorp/vault\"</span>, <span class=\"pl-c\">// or \"hashicorp/vault-enterprise\"</span>\n    <span class=\"pl-s1\">ImageTag</span>:    <span class=\"pl-s\">\"latest\"</span>,\n  }\n  <span class=\"pl-s1\">cluster</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">docker</span>.<span class=\"pl-c1\">NewTestDockerCluster</span>(<span class=\"pl-s1\">t</span>, <span class=\"pl-s1\">opts</span>)\n  <span class=\"pl-k\">defer</span> <span class=\"pl-s1\">cluster</span>.<span class=\"pl-c1\">Cleanup</span>()\n  \n  <span class=\"pl-s1\">client</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">cluster</span>.<span class=\"pl-c1\">Nodes</span>()[<span class=\"pl-c1\">0</span>].<span class=\"pl-c1\">APIClient</span>()\n  <span class=\"pl-s1\">_</span>, <span class=\"pl-s1\">err</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">client</span>.<span class=\"pl-c1\">Logical</span>().<span class=\"pl-c1\">Read</span>(<span class=\"pl-s\">\"sys/storage/raft/configuration\"</span>)\n  <span class=\"pl-k\">if</span> <span class=\"pl-s1\">err</span> <span class=\"pl-c1\">!=</span> <span class=\"pl-c1\">nil</span> {\n    <span class=\"pl-s1\">t</span>.<span class=\"pl-c1\">Fatal</span>(<span class=\"pl-s1\">err</span>)\n  }\n}</pre></div>\n<p dir=\"auto\">Or for Enterprise:</p>\n<div class=\"highlight highlight-source-go notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"import (\n  &quot;testing&quot;\n  &quot;github.com/hashicorp/vault/sdk/helper/testcluster/docker&quot;\n)\n\nfunc Test_Something_With_Docker(t *testing.T) {\n  opts := &amp;docker.DockerClusterOptions{\n    ImageRepo: &quot;hashicorp/vault-enterprise&quot;,\n    ImageTag:  &quot;latest&quot;,\n\tVaultLicense: licenseString, // not a path, the actual license bytes\n  }\n  cluster := docker.NewTestDockerCluster(t, opts)\n  defer cluster.Cleanup()\n}\"><pre class=\"notranslate\"><span class=\"pl-k\">import</span> (\n  <span class=\"pl-s\">\"testing\"</span>\n  <span class=\"pl-s\">\"github.com/hashicorp/vault/sdk/helper/testcluster/docker\"</span>\n)\n\n<span class=\"pl-k\">func</span> <span class=\"pl-s1\">Test_Something_With_Docker</span>(<span class=\"pl-s1\">t</span> <span class=\"pl-c1\">*</span>testing.<span class=\"pl-smi\">T</span>) {\n  <span class=\"pl-s1\">opts</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-c1\">&amp;</span>docker.<span class=\"pl-smi\">DockerClusterOptions</span>{\n    <span class=\"pl-s1\">ImageRepo</span>: <span class=\"pl-s\">\"hashicorp/vault-enterprise\"</span>,\n    <span class=\"pl-s1\">ImageTag</span>:  <span class=\"pl-s\">\"latest\"</span>,\n\t<span class=\"pl-s1\">VaultLicense</span>: <span class=\"pl-s1\">licenseString</span>, <span class=\"pl-c\">// not a path, the actual license bytes</span>\n  }\n  <span class=\"pl-s1\">cluster</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">docker</span>.<span class=\"pl-c1\">NewTestDockerCluster</span>(<span class=\"pl-s1\">t</span>, <span class=\"pl-s1\">opts</span>)\n  <span class=\"pl-k\">defer</span> <span class=\"pl-s1\">cluster</span>.<span class=\"pl-c1\">Cleanup</span>()\n}</pre></div>\n<p dir=\"auto\">Here is a more realistic example of how we use it in practice.  DefaultOptions uses<br>\n<code class=\"notranslate\">hashicorp/vault</code>:<code class=\"notranslate\">latest</code> as the repo and tag, but it also looks at the environment<br>\nvariable VAULT_BINARY. If populated, it will copy the local file referenced by<br>\nVAULT_BINARY into the container. This is useful when testing local changes.</p>\n<p dir=\"auto\">Instead of setting the VaultLicense option, you can set the VAULT_LICENSE_CI environment<br>\nvariable, which is better than committing a license to version control.</p>\n<p dir=\"auto\">Optionally you can set COMMIT_SHA, which will be appended to the image name we<br>\nbuild as a debugging convenience.</p>\n<div class=\"highlight highlight-source-go notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"func Test_Custom_Build_With_Docker(t *testing.T) {\n  opts := docker.DefaultOptions(t)\n  cluster := docker.NewTestDockerCluster(t, opts)\n  defer cluster.Cleanup()\n}\"><pre class=\"notranslate\"><span class=\"pl-k\">func</span> <span class=\"pl-s1\">Test_Custom_Build_With_Docker</span>(<span class=\"pl-s1\">t</span> <span class=\"pl-c1\">*</span>testing.<span class=\"pl-smi\">T</span>) {\n  <span class=\"pl-s1\">opts</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">docker</span>.<span class=\"pl-c1\">DefaultOptions</span>(<span class=\"pl-s1\">t</span>)\n  <span class=\"pl-s1\">cluster</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">docker</span>.<span class=\"pl-c1\">NewTestDockerCluster</span>(<span class=\"pl-s1\">t</span>, <span class=\"pl-s1\">opts</span>)\n  <span class=\"pl-k\">defer</span> <span class=\"pl-s1\">cluster</span>.<span class=\"pl-c1\">Cleanup</span>()\n}</pre></div>\n<p dir=\"auto\">There are a variety of helpers in the <code class=\"notranslate\">github.com/hashicorp/vault/sdk/helper/testcluster</code><br>\npackage, e.g. these tests below will create a pair of 3-node clusters and link them using<br>\nPR or DR replication respectively, and fail if the replication state doesn't become healthy<br>\nbefore the passed context expires.</p>\n<p dir=\"auto\">Again, as written, these depend on having a Vault Enterprise binary locally and the env<br>\nvar VAULT_BINARY set to point to it, as well as having VAULT_LICENSE_CI set.</p>\n<div class=\"highlight highlight-source-go notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"func TestStandardPerfReplication_Docker(t *testing.T) {\n  opts := docker.DefaultOptions(t)\n  r, err := docker.NewReplicationSetDocker(t, opts)\n  if err != nil {\n      t.Fatal(err)\n  }\n  defer r.Cleanup()\n\n  ctx, cancel := context.WithTimeout(context.Background(), time.Minute)\n  defer cancel()\n  err = r.StandardPerfReplication(ctx)\n  if err != nil {\n    t.Fatal(err)\n  }\n}\n\nfunc TestStandardDRReplication_Docker(t *testing.T) {\n  opts := docker.DefaultOptions(t)\n  r, err := docker.NewReplicationSetDocker(t, opts)\n  if err != nil {\n    t.Fatal(err)\n  }\n  defer r.Cleanup()\n\n  ctx, cancel := context.WithTimeout(context.Background(), time.Minute)\n  defer cancel()\n  err = r.StandardDRReplication(ctx)\n  if err != nil {\n    t.Fatal(err)\n  }\n}\"><pre class=\"notranslate\"><span class=\"pl-k\">func</span> <span class=\"pl-s1\">TestStandardPerfReplication_Docker</span>(<span class=\"pl-s1\">t</span> <span class=\"pl-c1\">*</span>testing.<span class=\"pl-smi\">T</span>) {\n  <span class=\"pl-s1\">opts</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">docker</span>.<span class=\"pl-c1\">DefaultOptions</span>(<span class=\"pl-s1\">t</span>)\n  <span class=\"pl-s1\">r</span>, <span class=\"pl-s1\">err</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">docker</span>.<span class=\"pl-c1\">NewReplicationSetDocker</span>(<span class=\"pl-s1\">t</span>, <span class=\"pl-s1\">opts</span>)\n  <span class=\"pl-k\">if</span> <span class=\"pl-s1\">err</span> <span class=\"pl-c1\">!=</span> <span class=\"pl-c1\">nil</span> {\n      <span class=\"pl-s1\">t</span>.<span class=\"pl-c1\">Fatal</span>(<span class=\"pl-s1\">err</span>)\n  }\n  <span class=\"pl-k\">defer</span> <span class=\"pl-s1\">r</span>.<span class=\"pl-c1\">Cleanup</span>()\n\n  <span class=\"pl-s1\">ctx</span>, <span class=\"pl-s1\">cancel</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">context</span>.<span class=\"pl-c1\">WithTimeout</span>(<span class=\"pl-s1\">context</span>.<span class=\"pl-c1\">Background</span>(), <span class=\"pl-s1\">time</span>.<span class=\"pl-c1\">Minute</span>)\n  <span class=\"pl-k\">defer</span> <span class=\"pl-s1\">cancel</span>()\n  <span class=\"pl-s1\">err</span> <span class=\"pl-c1\">=</span> <span class=\"pl-s1\">r</span>.<span class=\"pl-c1\">StandardPerfReplication</span>(<span class=\"pl-s1\">ctx</span>)\n  <span class=\"pl-k\">if</span> <span class=\"pl-s1\">err</span> <span class=\"pl-c1\">!=</span> <span class=\"pl-c1\">nil</span> {\n    <span class=\"pl-s1\">t</span>.<span class=\"pl-c1\">Fatal</span>(<span class=\"pl-s1\">err</span>)\n  }\n}\n\n<span class=\"pl-k\">func</span> <span class=\"pl-s1\">TestStandardDRReplication_Docker</span>(<span class=\"pl-s1\">t</span> <span class=\"pl-c1\">*</span>testing.<span class=\"pl-smi\">T</span>) {\n  <span class=\"pl-s1\">opts</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">docker</span>.<span class=\"pl-c1\">DefaultOptions</span>(<span class=\"pl-s1\">t</span>)\n  <span class=\"pl-s1\">r</span>, <span class=\"pl-s1\">err</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">docker</span>.<span class=\"pl-c1\">NewReplicationSetDocker</span>(<span class=\"pl-s1\">t</span>, <span class=\"pl-s1\">opts</span>)\n  <span class=\"pl-k\">if</span> <span class=\"pl-s1\">err</span> <span class=\"pl-c1\">!=</span> <span class=\"pl-c1\">nil</span> {\n    <span class=\"pl-s1\">t</span>.<span class=\"pl-c1\">Fatal</span>(<span class=\"pl-s1\">err</span>)\n  }\n  <span class=\"pl-k\">defer</span> <span class=\"pl-s1\">r</span>.<span class=\"pl-c1\">Cleanup</span>()\n\n  <span class=\"pl-s1\">ctx</span>, <span class=\"pl-s1\">cancel</span> <span class=\"pl-c1\">:=</span> <span class=\"pl-s1\">context</span>.<span class=\"pl-c1\">WithTimeout</span>(<span class=\"pl-s1\">context</span>.<span class=\"pl-c1\">Background</span>(), <span class=\"pl-s1\">time</span>.<span class=\"pl-c1\">Minute</span>)\n  <span class=\"pl-k\">defer</span> <span class=\"pl-s1\">cancel</span>()\n  <span class=\"pl-s1\">err</span> <span class=\"pl-c1\">=</span> <span class=\"pl-s1\">r</span>.<span class=\"pl-c1\">StandardDRReplication</span>(<span class=\"pl-s1\">ctx</span>)\n  <span class=\"pl-k\">if</span> <span class=\"pl-s1\">err</span> <span class=\"pl-c1\">!=</span> <span class=\"pl-c1\">nil</span> {\n    <span class=\"pl-s1\">t</span>.<span class=\"pl-c1\">Fatal</span>(<span class=\"pl-s1\">err</span>)\n  }\n}</pre></div>\n<p dir=\"auto\">Finally, here's an example of running an existing OSS docker test with a custom binary:</p>\n<div class=\"highlight highlight-source-shell notranslate position-relative overflow-auto\" dir=\"auto\" data-snippet-clipboard-copy-content=\"$ GOOS=linux make dev\n$ VAULT_BINARY=$(pwd)/bin/vault go test -run 'TestRaft_Configuration_Docker' ./vault/external_tests/raft/raft_binary\nok      github.com/hashicorp/vault/vault/external_tests/raft/raft_binary        20.960s\"><pre class=\"notranslate\">$ GOOS=linux make dev\n$ VAULT_BINARY=<span class=\"pl-s\"><span class=\"pl-pds\">$(</span>pwd<span class=\"pl-pds\">)</span></span>/bin/vault go <span class=\"pl-c1\">test</span> -run <span class=\"pl-s\"><span class=\"pl-pds\">'</span>TestRaft_Configuration_Docker<span class=\"pl-pds\">'</span></span> ./vault/external_tests/raft/raft_binary\nok      github.com/hashicorp/vault/vault/external_tests/raft/raft_binary        20.960s</pre></div>","updatedAt":"2025-05-22T01:52:09Z","upvoteCount":null,"author":{"login":"eryajf","avatarUrl":"https://avatars.githubusercontent.com/u/33259379?u=e4a4090a38ac2473aaed4ef9945233636776c6c3&v=4","url":"https://github.com/eryajf"},"category":null,"labels":{"edges":[{"node":{"name":"更多","color":"25B472"}},{"node":{"name":"hashicorp","color":"5ab310"}},{"node":{"name":"Secret","color":"25891f"}}]},"comments":{"edges":[]}}},"pageContext":{"number":587,"previous":{"title":"astral-sh/uv: 一个用 Rust 编写的极快的 Python 包和项目管理器。","number":586},"next":{"title":"vectordotdev/vector: 高性能、高可靠、可观察的数据管道, 性能比 Logstash 强很多","number":588}}},
    "staticQueryHashes": ["151096407","2861350382"]}