{"id":307772,"date":"2020-07-31T03:00:20","date_gmt":"2020-07-31T03:00:20","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=307772"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=307772","title":{"rendered":"Docker \u0438 \u0432\u0441\u0435, \u0432\u0441\u0435, \u0432\u0441\u0435"},"content":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/company\/southbridge\/blog\/512246\/\">\n<p>TL;DR: \u043e\u0431\u0437\u043e\u0440\u043d\u0430\u044f \u0441\u0442\u0430\u0442\u044c\u044f-\u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u043e \u043f\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044e \u0441\u0440\u0435\u0434 \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439 \u0432 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430\u0445. \u0411\u0443\u0434\u0443\u0442 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u044b \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 Docker \u0438 \u0434\u0440\u0443\u0433\u0438\u0445 \u0441\u0445\u043e\u0436\u0438\u0445 \u0441\u0438\u0441\u0442\u0435\u043c.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/gs\/kz\/iy\/gskziy9bonuhk4yq0cobemffymw.png\"><\/p>\n<p><a name=\"habracut\"><\/a>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">\u041d\u0435\u043c\u043d\u043e\u0436\u043a\u043e \u0438\u0441\u0442\u043e\u0440\u0438\u0438, \u043e\u0442\u043a\u0443\u0434\u0430 \u0432\u0441\u0435 \u0432\u0437\u044f\u043b\u043e\u0441\u044c<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<h2 id=\"istoriya\">\u0418\u0441\u0442\u043e\u0440\u0438\u044f<\/h2>\n<p>  <\/p>\n<p>\u041f\u0435\u0440\u0432\u044b\u043c \u043e\u0431\u0449\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u043c \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u043c \u0438\u0437\u043e\u043b\u044f\u0446\u0438\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f chroot. \u041e\u0434\u043d\u043e\u0438\u043c\u0435\u043d\u043d\u044b\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u043d\u044b\u0439 \u0432\u044b\u0437\u043e\u0432 \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u0435\u0442 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0435 \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u0433\u043e \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430 \u2014 \u0442\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u044f \u0434\u043e\u0441\u0442\u0443\u043f \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0435, \u0435\u0433\u043e \u0432\u044b\u0437\u0432\u0430\u0432\u0448\u0435\u0439, \u0434\u043e\u0441\u0442\u0443\u043f \u0442\u043e\u043b\u044c\u043a\u043e \u043a \u0444\u0430\u0439\u043b\u0430\u043c \u0432\u043d\u0443\u0442\u0440\u0438 \u044d\u0442\u043e\u0433\u043e \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430. \u041d\u043e \u0435\u0441\u043b\u0438 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0435 \u0432\u043d\u0443\u0442\u0440\u0438 \u0434\u0430\u0442\u044c \u043f\u0440\u0430\u0432\u0430 \u0441\u0443\u043f\u0435\u0440\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f, \u043f\u043e\u0442\u0435\u043d\u0446\u0438\u0430\u043b\u044c\u043d\u043e \u043e\u043d\u0430 \u043c\u043e\u0436\u0435\u0442 \u00ab\u0443\u0431\u0435\u0436\u0430\u0442\u044c\u00bb \u0438\u0437 chroot \u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u0435. \u0422\u0430\u043a\u0436\u0435 \u043a\u0440\u043e\u043c\u0435 \u0441\u043c\u0435\u043d\u044b \u043a\u043e\u0440\u043d\u0435\u0432\u043e\u0433\u043e \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0430 \u043d\u0435 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0434\u0440\u0443\u0433\u0438\u0435 \u0440\u0435\u0441\u0443\u0440\u0441\u044b (\u043e\u043f\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u0430\u044f \u043f\u0430\u043c\u044f\u0442\u044c, \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0440), \u0430 \u0442\u0430\u043a\u0436\u0435 \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0441\u0435\u0442\u0438.<\/p>\n<p>  <\/p>\n<p>\u0421\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u2014 \u0437\u0430\u043f\u0443\u0441\u043a \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u043e\u0439 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0432\u043d\u0443\u0442\u0440\u0438 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430, \u0437\u0430 \u0441\u0447\u0435\u0442 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c\u043e\u0432 \u044f\u0434\u0440\u0430 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u044b. \u0412 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u0445 \u044d\u0442\u043e\u0442 \u0441\u043f\u043e\u0441\u043e\u0431 \u043d\u0430\u0437\u044b\u0432\u0430\u044e\u0442 \u043f\u043e-\u0440\u0430\u0437\u043d\u043e\u043c\u0443, \u043d\u043e \u0441\u0443\u0442\u044c \u043e\u0434\u043d\u0430 \u0438 \u0442\u0430 \u0436\u0435 \u2014 \u0437\u0430\u043f\u0443\u0441\u043a \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u043d\u0435\u0437\u0430\u0432\u0438\u0441\u0438\u043c\u044b\u0445 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c, \u043a\u0430\u0436\u0434\u0430\u044f \u0438\u0437 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0441 \u0442\u0435\u043c \u0436\u0435 \u044f\u0434\u0440\u043e\u043c, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0438 \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u0430\u044f \u0441\u0438\u0441\u0442\u0435\u043c\u0430. \u0421\u044e\u0434\u0430 \u043e\u0442\u043d\u043e\u0441\u044f\u0442\u0441\u044f FreeBSD Jails, Solaris Zones, OpenVZ \u0438 LXC \u0434\u043b\u044f Linux. \u041e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0438\u0437\u043e\u043b\u044f\u0446\u0438\u044f \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u043e \u0434\u0438\u0441\u043a\u043e\u0432\u043e\u043c\u0443 \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0443, \u043d\u043e \u0438 \u0434\u0440\u0443\u0433\u0438\u043c \u0440\u0435\u0441\u0443\u0440\u0441\u0430\u043c, \u0432 \u0447\u0430\u0441\u0442\u043d\u043e\u0441\u0442\u0438 \u043a\u0430\u0436\u0434\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440 \u043c\u043e\u0436\u0435\u0442 \u0438\u043c\u0435\u0442\u044c \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u044f \u043f\u043e \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0440\u043d\u043e\u043c\u0443 \u0432\u0440\u0435\u043c\u0435\u043d\u0438, \u043e\u043f\u0435\u0440\u0430\u0442\u0438\u0432\u043d\u043e\u0439 \u043f\u0430\u043c\u044f\u0442\u0438, \u043f\u043e\u043b\u043e\u0441\u0435 \u043f\u0440\u043e\u043f\u0443\u0441\u043a\u0430\u043d\u0438\u044f \u0441\u0435\u0442\u0438. \u041f\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044e \u0441 chroot \u0432\u044b\u0439\u0442\u0438 \u0438\u0437 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430 \u0441\u043b\u043e\u0436\u043d\u0435\u0435, \u043f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u0441\u0443\u043f\u0435\u0440\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c \u0432 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0435 \u043e\u0431\u043b\u0430\u0434\u0430\u0435\u0442 \u0434\u043e\u0441\u0442\u0443\u043f\u043e\u043c \u0442\u043e\u043b\u044c\u043a\u043e \u043a \u043d\u0430\u0447\u0438\u043d\u043a\u0435 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430, \u043e\u0434\u043d\u0430\u043a\u043e \u0438\u0437-\u0437\u0430 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u0438\u0432\u0430\u0442\u044c \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u0443\u044e \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u0432\u043d\u0443\u0442\u0440\u0438 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430 \u0432 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u043c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0438 \u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0441\u0442\u0430\u0440\u044b\u0445 \u0432\u0435\u0440\u0441\u0438\u0439 \u044f\u0434\u0435\u0440 (\u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e \u0434\u043b\u044f Linux, \u0432 \u043c\u0435\u043d\u044c\u0448\u0435\u0439 \u043c\u0435\u0440\u0435 FreeBSD) \u0435\u0441\u0442\u044c \u043d\u0435\u043d\u0443\u043b\u0435\u0432\u0430\u044f \u0432\u0435\u0440\u043e\u044f\u0442\u043d\u043e\u0441\u0442\u044c \u00ab\u043f\u0440\u043e\u0431\u0438\u0442\u0438\u044f\u00bb \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0438\u0437\u043e\u043b\u044f\u0446\u0438\u0438 \u044f\u0434\u0440\u0430 \u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u0435.<\/p>\n<p>  <\/p>\n<p>\u0412\u043c\u0435\u0441\u0442\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043f\u043e\u043b\u043d\u043e\u0446\u0435\u043d\u043d\u043e\u0439 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u043e\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0432 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0435 (\u0441 \u0441\u0438\u0441\u0442\u0435\u043c\u043e\u0439 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438, \u043f\u0430\u043a\u0435\u0442\u043d\u044b\u043c \u043c\u0435\u043d\u0435\u0434\u0436\u0435\u0440\u043e\u043c \u0438 \u0442.\u043f.) \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0441\u0440\u0430\u0437\u0443 \u0436\u0435 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f, \u0433\u043b\u0430\u0432\u043d\u043e\u0435 \u2014 \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0442\u044c \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f\u043c \u0442\u0430\u043a\u0443\u044e \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c (\u043d\u0430\u043b\u0438\u0447\u0438\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0445 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a \u0438 \u043f\u0440\u043e\u0447\u0438\u0445 \u0444\u0430\u0439\u043b\u043e\u0432). \u042d\u0442\u0430 \u0438\u0434\u0435\u044f \u0438 \u043f\u043e\u0441\u043b\u0443\u0436\u0438\u043b\u0430 \u043e\u0441\u043d\u043e\u0432\u043e\u0439 \u0434\u043b\u044f \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043d\u043e\u0439 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439, \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u044f\u0440\u043a\u0438\u043c \u0438 \u043e\u0431\u0449\u0435\u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u043c \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u0438\u0442\u0435\u043b\u0435\u043c \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f Docker. \u041f\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044e \u0441 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0438\u043c\u0438 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u043c\u0438 \u0431\u043e\u043b\u0435\u0435 \u0433\u0438\u0431\u043a\u0438\u0435 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c\u044b \u0438\u0437\u043e\u043b\u044f\u0446\u0438\u0438 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e \u0441 \u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0439 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u043e\u0439 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0445 \u0441\u0435\u0442\u0435\u0439 \u043c\u0435\u0436\u0434\u0443 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430\u043c\u0438 \u0438 \u0441 \u043e\u0442\u0441\u043b\u0435\u0436\u0438\u0432\u0430\u043d\u0438\u0435\u043c \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u044f \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0432\u043d\u0443\u0442\u0440\u0438 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430 \u0434\u0430\u043b\u0438 \u0432 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u0438\u044f \u0435\u0434\u0438\u043d\u043e\u0439 \u0446\u0435\u043b\u043e\u0441\u0442\u043d\u043e\u0439 \u0441\u0440\u0435\u0434\u044b \u0438\u0437 \u0431\u043e\u043b\u044c\u0448\u043e\u0433\u043e \u0447\u0438\u0441\u043b\u0430 \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u0438\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432 \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 \u2014 \u0431\u0435\u0437 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0441\u0442\u0438 \u0440\u0443\u0447\u043d\u043e\u0433\u043e \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0440\u0435\u0441\u0443\u0440\u0441\u0430\u043c\u0438.<\/p>\n<\/div><\/div>\n<p>  <\/p>\n<h2 id=\"docker\">Docker<\/h2>\n<p>  <\/p>\n<p>Docker \u044d\u0442\u043e \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e\u0435 \u041f\u041e \u0434\u043b\u044f \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0438\u0437\u0430\u0446\u0438\u0438 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439. \u041d\u0430\u043f\u0438\u0441\u0430\u043d \u043d\u0430 \u044f\u0437\u044b\u043a\u0435 Go, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442 \u0448\u0442\u0430\u0442\u043d\u044b\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u044f\u0434\u0440\u0430 Linux \u2014 cgroups, namespaces, capabilities \u0438 \u0442.\u043f., \u0430 \u0442\u0430\u043a\u0436\u0435 \u0444\u0430\u0439\u043b\u043e\u0432\u044b\u0435 \u0441\u0438\u0441\u0442\u0435\u043c\u044b Aufs \u0438 \u0434\u0440\u0443\u0433\u0438\u0435 \u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0435 \u0434\u043b\u044f \u044d\u043a\u043e\u043d\u043e\u043c\u0438\u0438 \u0434\u0438\u0441\u043a\u043e\u0432\u043e\u0433\u043e \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/je\/p-\/tu\/jep-tu3xeqbbhpqup7olbsewoqi.png\"><br \/>  <em>\u0418\u0441\u0442\u043e\u0447\u043d\u0438\u043a: wikimedia<\/em><\/p>\n<p>  <\/p>\n<h3 id=\"arhitektura\">\u0410\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u0430<\/h3>\n<p>  <\/p>\n<p>\u0414\u043e \u0432\u0435\u0440\u0441\u0438\u0438 1.11 Docker \u0440\u0430\u0431\u043e\u0442\u0430\u043b \u0432 \u0432\u0438\u0434\u0435 \u0435\u0434\u0438\u043d\u043e\u0433\u043e \u0441\u0435\u0440\u0432\u0438\u0441\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u043b \u0432\u0441\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438 \u0441 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430\u043c\u0438: \u0441\u043a\u0430\u0447\u0438\u0432\u0430\u043d\u0438\u0435 \u043e\u0431\u0440\u0430\u0437\u043e\u0432 \u0434\u043b\u044f \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432, \u0437\u0430\u043f\u0443\u0441\u043a \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432, \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0443 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043f\u043e API. \u041d\u0430\u0447\u0438\u043d\u0430\u044f \u0441 \u0432\u0435\u0440\u0441\u0438\u0438 1.11 Docker \u0440\u0430\u0437\u0431\u0438\u043b\u0438 \u043d\u0430 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u0447\u0430\u0441\u0442\u0435\u0439, \u0432\u0437\u0430\u0438\u043c\u043e\u0434\u0435\u0439\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0445 \u043c\u0435\u0436\u0434\u0443 \u0441\u043e\u0431\u043e\u0439: containerd, \u0434\u043b\u044f \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u0432\u0441\u0435\u0433\u043e \u0436\u0438\u0437\u043d\u0435\u043d\u043d\u043e\u0433\u043e \u0446\u0438\u043a\u043b\u0430 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 (\u0432\u044b\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u0434\u0438\u0441\u043a\u043e\u0432\u043e\u0433\u043e \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430, \u0441\u043a\u0430\u0447\u0438\u0432\u0430\u043d\u0438\u0435 \u043e\u0431\u0440\u0430\u0437\u043e\u0432, \u0440\u0430\u0431\u043e\u0442\u0430 \u0441 \u0441\u0435\u0442\u044c\u044e, \u0437\u0430\u043f\u0443\u0441\u043a, \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0438 \u043d\u0430\u0431\u043b\u044e\u0434\u0435\u043d\u0438\u0435 \u0437\u0430 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435\u043c \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432) \u0438 runC, \u0441\u0440\u0435\u0434\u044b \u0438\u0441\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432, \u043e\u0441\u043d\u043e\u0432\u0430\u043d\u043d\u043e\u0439 \u043d\u0430 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 cgroups \u0438 \u043f\u0440\u043e\u0447\u0438\u0445 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0435\u0439 \u044f\u0434\u0440\u0430 Linux. \u0421\u0430\u043c \u0441\u0435\u0440\u0432\u0438\u0441 docker \u043e\u0441\u0442\u0430\u043b\u0441\u044f, \u043d\u043e \u0442\u0435\u043f\u0435\u0440\u044c \u043e\u043d \u0441\u043b\u0443\u0436\u0438\u0442 \u0442\u043e\u043b\u044c\u043a\u043e \u0434\u043b\u044f \u043e\u0431\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043f\u043e API, \u0442\u0440\u0430\u043d\u0441\u043b\u0438\u0440\u0443\u0435\u043c\u044b\u0445 \u0432 containerd.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/mc\/pl\/c5\/mcplc5nesy_dr2dxitbquhe_wqe.png\"><\/p>\n<p>  <\/p>\n<h3 id=\"ustanovka-i-nastroyka\">\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430<\/h3>\n<p>  <\/p>\n<p>\u041c\u043e\u0438\u043c \u043b\u044e\u0431\u0438\u043c\u044b\u043c \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u043c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 docker \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f docker-machine, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043a\u0440\u043e\u043c\u0435 \u043d\u0435\u043f\u043e\u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 docker \u043d\u0430 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0435 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 (\u0432\u043a\u043b\u044e\u0447\u0430\u044f \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0435 \u043e\u0431\u043b\u0430\u043a\u0430) \u0434\u0430\u0435\u0442 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u0444\u0430\u0439\u043b\u043e\u0432\u044b\u043c\u0438 \u0441\u0438\u0441\u0442\u0435\u043c\u0430\u043c\u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u0435\u0442 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u044c \u0437\u0430\u043f\u0443\u0441\u043a \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u043a\u043e\u043c\u0430\u043d\u0434.<\/p>\n<p>  <\/p>\n<p>\u041e\u0434\u043d\u0430\u043a\u043e \u0441 2018 \u0433\u043e\u0434\u0430 \u043f\u0440\u043e\u0435\u043a\u0442 \u043f\u043e\u0447\u0442\u0438 \u043d\u0435 \u0440\u0430\u0437\u0432\u0438\u0432\u0430\u0435\u0442\u0441\u044f, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0443 \u0431\u0443\u0434\u0435\u043c \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u044c \u0448\u0442\u0430\u0442\u043d\u044b\u043c \u0434\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0438\u043d\u0441\u0442\u0432\u0430 \u0434\u0438\u0441\u0442\u0440\u0438\u0431\u0443\u0442\u0438\u0432\u043e\u0432 Linux \u0441\u043f\u043e\u0441\u043e\u0431\u043e\u043c \u2014 \u0434\u043e\u0431\u0430\u0432\u043b\u0435\u043d\u0438\u0435\u043c \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u044f \u0438 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u043e\u0439 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0445 \u043f\u0430\u043a\u0435\u0442\u043e\u0432.<\/p>\n<p>  <\/p>\n<p>\u0422\u0430\u043a\u0436\u0435 \u044d\u0442\u043e\u0442 \u0441\u043f\u043e\u0441\u043e\u0431 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u0438 \u043f\u0440\u0438 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u043e\u0439 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0435, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e Ansible \u0438\u043b\u0438 \u0434\u0440\u0443\u0433\u0438\u0445 \u043f\u043e\u0434\u043e\u0431\u043d\u044b\u0445 \u0441\u0438\u0441\u0442\u0435\u043c, \u043d\u043e \u0432 \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0435 \u044f \u0435\u0433\u043e \u0440\u0430\u0441\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0442\u044c \u043d\u0435 \u0431\u0443\u0434\u0443.<\/p>\n<p>  <\/p>\n<p>\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0431\u0443\u0434\u0435\u0442 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u044c\u0441\u044f \u043d\u0430 Centos 7, \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u044f \u0431\u0443\u0434\u0443 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u0443\u044e \u043c\u0430\u0448\u0438\u043d\u0443, \u0434\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043d\u0438\u0436\u0435:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># yum install -y yum-utils # yum-config-manager --add-repo https:\/\/download.docker.com\/linux\/centos\/docker-ce.repo # yum install docker-ce docker-ce-cli containerd.io<\/code><\/pre>\n<p>  <\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u043d\u0430\u0434\u043e \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c \u0441\u0435\u0440\u0432\u0438\u0441, \u043f\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0435\u0433\u043e \u0432 \u0430\u0432\u0442\u043e\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0443:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># systemctl enable docker # systemctl start docker # firewall-cmd --zone=public --add-port=2377\/tcp --permanent<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u043c\u043e\u0436\u043d\u043e \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u0433\u0440\u0443\u043f\u043f\u0443 docker, \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0438 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0441\u043c\u043e\u0433\u0443\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 docker \u0431\u0435\u0437 sudo, \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0436\u0443\u0440\u043d\u0430\u043b\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435, \u0432\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a API \u0438\u0437\u0432\u043d\u0435, \u043d\u043e \u0442\u0443\u0442 \u044f \u0431\u043e\u043b\u0435\u0435 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e \u043d\u0435 \u0431\u0443\u0434\u0443 \u043e\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c\u0441\u044f.<\/p>\n<p>  <\/p>\n<h3 id=\"drugie-vozmozhnosti\">\u0414\u0440\u0443\u0433\u0438\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438<\/h3>\n<p>  <\/p>\n<p>\u041a\u0440\u043e\u043c\u0435 \u0432\u044b\u0448\u0435\u043d\u0430\u0437\u0432\u0430\u043d\u043d\u043e\u0439 docker machine \u0435\u0449\u0435 \u0435\u0441\u0442\u044c docker registry, \u0441\u0440\u0435\u0434\u0441\u0442\u0432\u043e \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u043e\u0431\u0440\u0430\u0437\u043e\u0432 \u0434\u043b\u044f \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432, \u0430 \u0442\u0430\u043a\u0436\u0435 docker compose \u2014 \u0441\u0440\u0435\u0434\u0441\u0442\u0432\u043e \u0434\u043b\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0440\u0430\u0437\u0432\u0435\u0440\u0442\u044b\u0432\u0430\u043d\u0438\u044f \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439 \u0432 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430\u0445, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044e\u0442\u0441\u044f \u0444\u0430\u0439\u043b\u044b YAML \u0434\u043b\u044f \u0441\u0431\u043e\u0440\u043a\u0438 \u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 \u0438 \u043f\u0440\u043e\u0447\u0438\u0445 \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0445 \u0432\u0435\u0449\u0435\u0439 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0441\u0435\u0442\u0438, \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u044b\u0435 \u0444\u0430\u0439\u043b\u043e\u0432\u044b\u0435 \u0441\u0438\u0441\u0442\u0435\u043c\u044b \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445). <\/p>\n<p>  <\/p>\n<p>\u0422\u0430\u043a\u0436\u0435 \u0441 \u0435\u0433\u043e \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043c\u043e\u0436\u043d\u043e \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u043e\u0432\u0430\u0442\u044c \u043a\u043e\u043d\u0432\u0435\u0439\u0435\u0440\u044b \u0434\u043b\u044f CI\\CD. \u0414\u0440\u0443\u0433\u0430\u044f \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u0430\u044f \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u2014 \u0440\u0430\u0431\u043e\u0442\u0430 \u0432 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u043d\u043e\u043c \u0440\u0435\u0436\u0438\u043c\u0435, \u0442\u0430\u043a \u043d\u0430\u0437\u044b\u0432\u0430\u0435\u043c\u044b\u0439 swarm mode (\u0434\u043e \u0432\u0435\u0440\u0441\u0438\u0438 1.12 \u0431\u044b\u043b \u0438\u0437\u0432\u0435\u0441\u0442\u0435\u043d \u043a\u0430\u043a docker swarm), \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u044e\u0449\u0430\u044f \u0441\u043e\u0431\u0440\u0430\u0442\u044c \u0438\u0437 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432 \u0435\u0434\u0438\u043d\u0443\u044e \u0438\u043d\u0444\u0440\u0430\u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0443 \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432. \u0418\u043c\u0435\u0435\u0442\u0441\u044f \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u043e\u0439 \u0441\u0435\u0442\u0438 \u043f\u043e\u0432\u0435\u0440\u0445 \u0432\u0441\u0435\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432, \u0435\u0441\u0442\u044c \u043d\u0430\u043b\u0438\u0447\u0438\u0435 \u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0433\u043e \u0431\u0430\u043b\u0430\u043d\u0441\u0438\u0440\u043e\u0432\u0449\u0438\u043a\u0430 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0438, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 \u0441\u0435\u043a\u0440\u0435\u0442\u043e\u0432 \u0434\u043b\u044f \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432. <\/p>\n<p>  <\/p>\n<p>\u0424\u0430\u0439\u043b\u044b YAML \u043e\u0442 docker compose \u0441 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0438\u043c\u0438 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f\u043c\u0438 \u043c\u043e\u0433\u0443\u0442 \u0431\u044b\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u044b \u0434\u043b\u044f \u0442\u0430\u043a\u0438\u0445 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u043e\u0432, \u043f\u043e\u043b\u043d\u043e\u0441\u0442\u044c\u044e \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0438\u0440\u0443\u044f \u043e\u0431\u0441\u043b\u0443\u0436\u0438\u0432\u0430\u043d\u0438\u0435 \u043c\u0430\u043b\u044b\u0445 \u0438 \u0441\u0440\u0435\u0434\u043d\u0438\u0445 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u043e\u0432 \u0434\u043b\u044f \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0445 \u0446\u0435\u043b\u0435\u0439. \u0414\u043b\u044f \u0431\u043e\u043b\u044c\u0448\u0438\u0445 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u043e\u0432 \u043f\u0440\u0435\u0434\u043f\u043e\u0447\u0442\u0438\u0442\u0435\u043b\u044c\u043d\u0435\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Kubernetes, \u043f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u0437\u0430\u0442\u0440\u0430\u0442\u044b \u043d\u0430 \u043e\u0431\u0441\u043b\u0443\u0436\u0438\u0432\u0430\u043d\u0438\u0435 swarm mode \u043c\u043e\u0433\u0443\u0442 \u043f\u0440\u0435\u0432\u0437\u043e\u0439\u0442\u0438 \u0442\u0430\u043a\u043e\u0432\u044b\u0435 \u0441 Kubernetes. \u041a\u0440\u043e\u043c\u0435 runC \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0441\u0440\u0435\u0434\u044b \u0438\u0441\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 \u043c\u043e\u0436\u043d\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 <a href=\"https:\/\/habr.com\/ru\/company\/southbridge\/blog\/489940\/\">Kata containers<\/a><\/p>\n<p>  <\/p>\n<h3 id=\"rabota-s-docker\">\u0420\u0430\u0431\u043e\u0442\u0430 \u0441 Docker<\/h3>\n<p>  <\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043f\u043e\u043f\u0440\u043e\u0431\u0443\u0435\u043c \u0441\u043e\u0431\u0440\u0430\u0442\u044c \u043a\u043b\u0430\u0441\u0442\u0435\u0440, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0440\u0430\u0437\u0432\u0435\u0440\u043d\u0435\u043c GitLab \u0438 Docker Registry \u0434\u043b\u044f \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u043e\u0432. \u0412 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432 \u044f \u0431\u0443\u0434\u0443 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0442\u0440\u0438 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0435 \u043c\u0430\u0448\u0438\u043d\u044b, \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0440\u0430\u0437\u0432\u0435\u0440\u043d\u0443 \u0440\u0430\u0441\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u0443\u044e \u0424\u0421 GlusterFS, \u0435\u0435 \u044f \u0431\u0443\u0434\u0443 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430 docker volumes, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043e\u0442\u043a\u0430\u0437\u043e\u0443\u0441\u0442\u0440\u043e\u0439\u0447\u0438\u0432\u043e\u0439 \u0432\u0435\u0440\u0441\u0438\u0438 docker registry. \u041a\u043b\u044e\u0447\u0435\u0432\u044b\u0435 \u043a\u043e\u043c\u043f\u043e\u043d\u0435\u043d\u0442\u044b \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430: Docker Registry, Postgresql, Redis, GitLab \u0441 \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u043e\u0439 GitLab Runner \u043f\u043e\u0432\u0435\u0440\u0445 Swarm. Postgresql \u0431\u0443\u0434\u0435\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0441 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0438\u0437\u0430\u0446\u0438\u0435\u0439 <a href=\"https:\/\/github.com\/sorintlab\/stolon\">Stolon<\/a>, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 Postgresql \u043d\u0435 \u043d\u0430\u0434\u043e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c GlusterFS. \u041e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u043a\u0440\u0438\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0431\u0443\u0434\u0443\u0442 \u0445\u0440\u0430\u043d\u0438\u0442\u044c\u0441\u044f \u043d\u0430 GlusterFS.<\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0440\u0430\u0437\u0432\u043e\u0440\u0430\u0447\u0438\u0432\u0430\u043d\u0438\u044f GlusterFS \u043d\u0430 \u0432\u0441\u0435\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u0430\u0445 (\u043e\u043d\u0438 \u0438\u043c\u0435\u043d\u0443\u044e\u0442\u0441\u044f node1, node2, node3) \u043d\u0443\u0436\u043d\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043f\u0430\u043a\u0435\u0442\u044b, \u0440\u0430\u0437\u0440\u0435\u0448\u0438\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0443 firewall, \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043d\u0443\u0436\u043d\u044b\u0435 \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0438:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># yum -y install centos-release-gluster7 # yum -y install glusterfs-server # systemctl enable glusterd # systemctl start glusterd # firewall-cmd --add-service=glusterfs --permanent # firewall-cmd --reload # mkdir -p \/srv\/gluster # mkdir -p \/srv\/docker # echo &quot;$(hostname):\/docker \/srv\/docker glusterfs defaults,_netdev 0 0&quot; &gt;&gt; \/etc\/fstab<\/code><\/pre>\n<p>  <\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0440\u0430\u0431\u043e\u0442\u0443 \u043f\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 GlusterFS \u043d\u0430\u0434\u043e \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0430\u0442\u044c \u0441 \u043e\u0434\u043d\u043e\u0433\u043e \u0443\u0437\u043b\u0430, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 node1:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># gluster peer probe node2 # gluster peer probe node3 # gluster volume create docker replica 3 node1:\/srv\/gluster node2:\/srv\/gluster node3:\/srv\/gluster force # gluster volume start docker<\/code><\/pre>\n<p>  <\/p>\n<p>\u0417\u0430\u0442\u0435\u043c \u043d\u0430\u0434\u043e \u0441\u043c\u043e\u043d\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u043d\u044b\u0439 volume (\u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u043d\u0443\u0436\u043d\u043e \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043d\u0430 \u0432\u0441\u0435\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u0430\u0445):<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># mount \/srv\/docker<\/code><\/pre>\n<p>  <\/p>\n<p>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 swarm mode \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u043d\u0430 \u043e\u0434\u043d\u043e\u043c \u0438\u0437 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0431\u0443\u0434\u0435\u0442 Leader, \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u0431\u0443\u0434\u0443\u0442 \u043f\u0440\u0438\u0441\u043e\u0435\u0434\u0438\u043d\u044f\u0442\u044c\u0441\u044f \u043a \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0443, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u043d\u0430 \u043f\u0435\u0440\u0432\u043e\u043c \u0441\u0435\u0440\u0432\u0435\u0440\u0435 \u043d\u0430\u0434\u043e \u0431\u0443\u0434\u0435\u0442 \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0438 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u043d\u0430 \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u0445.<\/p>\n<p>  <\/p>\n<p>\u041f\u0435\u0440\u0432\u0438\u0447\u043d\u0430\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430, \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u044e \u043d\u0430 node1:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker swarm init Swarm initialized: current node (a5jpfrh5uvo7svzz1ajduokyq) is now a manager.  To add a worker to this swarm, run the following command:      docker swarm join --token SWMTKN-1-0c5mf7mvzc7o7vjk0wngno2dy70xs95tovfxbv4tqt9280toku-863hyosdlzvd76trfptd4xnzd xx.xx.xx.xx:2377  To add a manager to this swarm, run 'docker swarm join-token manager' and follow the instructions. # docker swarm join-token manager<\/code><\/pre>\n<p>  <\/p>\n<p>\u041a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0432\u0442\u043e\u0440\u043e\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u044b, \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u043c \u043d\u0430 node2 \u0438 node3:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker swarm join --token SWMTKN-x-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx-xxxxxxxxx xx.xx.xx.xx:2377 This node joined a swarm as a manager.<\/code><\/pre>\n<p>  <\/p>\n<p>\u041d\u0430 \u044d\u0442\u043e\u043c \u043f\u0440\u0435\u0434\u0432\u0430\u0440\u0438\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432 \u043e\u043a\u043e\u043d\u0447\u0435\u043d\u0430, \u043f\u0440\u0438\u0441\u0442\u0443\u043f\u0430\u0435\u043c \u043a \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432, \u043a\u043e\u043c\u0430\u043d\u0434\u044b \u0434\u043b\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0431\u0443\u0434\u0443\u0442 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c\u0441\u044f \u0441 node1, \u0435\u0441\u043b\u0438 \u043d\u0435 \u0443\u043a\u0430\u0437\u0430\u043d\u043e \u0438\u043d\u0430\u0447\u0435.<\/p>\n<p>  <\/p>\n<p>\u041f\u0435\u0440\u0432\u044b\u043c \u0434\u0435\u043b\u043e\u043c \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0441\u0435\u0442\u0438 \u0434\u043b\u044f \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker network create --driver=overlay etcd # docker network create --driver=overlay pgsql # docker network create --driver=overlay redis # docker network create --driver=overlay traefik # docker network create --driver=overlay gitlab<\/code><\/pre>\n<p>  <\/p>\n<p>\u0417\u0430\u0442\u0435\u043c \u043f\u043e\u043c\u0435\u0447\u0430\u0435\u043c \u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u044d\u0442\u043e \u043d\u0443\u0436\u043d\u043e \u0434\u043b\u044f \u043f\u0440\u0438\u0432\u044f\u0437\u043a\u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0445 \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432 \u043a \u0441\u0435\u0440\u0432\u0435\u0440\u0430\u043c:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker node update --label-add nodename=node1 node1 # docker node update --label-add nodename=node2 node2 # docker node update --label-add nodename=node3 node3<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0438 \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f \u0434\u0430\u043d\u043d\u044b\u0445 etcd, KV-\u0445\u0440\u0430\u043d\u0438\u043b\u0438\u0449\u0430, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u043d\u0443\u0436\u043d\u043e \u0434\u043b\u044f Traefik \u0438 Stolon. \u0410\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u043e Postgresql \u044d\u0442\u043e \u0431\u0443\u0434\u0443\u0442 \u043f\u0440\u0438\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0435 \u043a \u0441\u0435\u0440\u0432\u0435\u0440\u0430\u043c \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u044b, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u044d\u0442\u0443 \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u043c \u043d\u0430 \u0432\u0441\u0435\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u0430\u0445:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># mkdir -p \/srv\/etcd<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u0444\u0430\u0439\u043b \u0434\u043b\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 etcd \u0438 \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u043c \u0435\u0433\u043e:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">00etcd.yml<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"plaintext\">version: '3.7'  services:   etcd1:     image: quay.io\/coreos\/etcd:latest     hostname: etcd1     command:       - etcd       - --name=etcd1       - --data-dir=\/data.etcd       - --advertise-client-urls=http:\/\/etcd1:2379       - --listen-client-urls=http:\/\/0.0.0.0:2379       - --initial-advertise-peer-urls=http:\/\/etcd1:2380       - --listen-peer-urls=http:\/\/0.0.0.0:2380       - --initial-cluster=etcd1=http:\/\/etcd1:2380,etcd2=http:\/\/etcd2:2380,etcd3=http:\/\/etcd3:2380       - --initial-cluster-state=new       - --initial-cluster-token=etcd-cluster     networks:       - etcd     volumes:       - etcd1vol:\/data.etcd     deploy:       replicas: 1       placement:         constraints: [node.labels.nodename == node1]   etcd2:     image: quay.io\/coreos\/etcd:latest     hostname: etcd2     command:       - etcd       - --name=etcd2       - --data-dir=\/data.etcd       - --advertise-client-urls=http:\/\/etcd2:2379       - --listen-client-urls=http:\/\/0.0.0.0:2379       - --initial-advertise-peer-urls=http:\/\/etcd2:2380       - --listen-peer-urls=http:\/\/0.0.0.0:2380       - --initial-cluster=etcd1=http:\/\/etcd1:2380,etcd2=http:\/\/etcd2:2380,etcd3=http:\/\/etcd3:2380       - --initial-cluster-state=new       - --initial-cluster-token=etcd-cluster     networks:       - etcd     volumes:       - etcd2vol:\/data.etcd     deploy:       replicas: 1       placement:         constraints: [node.labels.nodename == node2]   etcd3:     image: quay.io\/coreos\/etcd:latest     hostname: etcd3     command:       - etcd       - --name=etcd3       - --data-dir=\/data.etcd       - --advertise-client-urls=http:\/\/etcd3:2379       - --listen-client-urls=http:\/\/0.0.0.0:2379       - --initial-advertise-peer-urls=http:\/\/etcd3:2380       - --listen-peer-urls=http:\/\/0.0.0.0:2380       - --initial-cluster=etcd1=http:\/\/etcd1:2380,etcd2=http:\/\/etcd2:2380,etcd3=http:\/\/etcd3:2380       - --initial-cluster-state=new       - --initial-cluster-token=etcd-cluster     networks:       - etcd     volumes:       - etcd3vol:\/data.etcd     deploy:       replicas: 1       placement:         constraints: [node.labels.nodename == node3]  volumes:   etcd1vol:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/etcd&quot;   etcd2vol:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/etcd&quot;   etcd3vol:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/etcd&quot;  networks:   etcd:     external: true<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker stack deploy --compose-file 00etcd.yml etcd<\/code><\/pre>\n<p>  <\/p>\n<p>\u0427\u0435\u0440\u0435\u0437 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0432\u0440\u0435\u043c\u044f \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c, \u0447\u0442\u043e \u043f\u043e\u0434\u043d\u044f\u043b\u0441\u044f etcd \u043a\u043b\u0430\u0441\u0442\u0435\u0440:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker exec $(docker ps | awk '\/etcd\/ {print $1}')  etcdctl member list ade526d28b1f92f7: name=etcd1 peerURLs=http:\/\/etcd1:2380 clientURLs=http:\/\/etcd1:2379 isLeader=false bd388e7810915853: name=etcd3 peerURLs=http:\/\/etcd3:2380 clientURLs=http:\/\/etcd3:2379 isLeader=false d282ac2ce600c1ce: name=etcd2 peerURLs=http:\/\/etcd2:2380 clientURLs=http:\/\/etcd2:2379 isLeader=true # docker exec $(docker ps | awk '\/etcd\/ {print $1}')  etcdctl cluster-health member ade526d28b1f92f7 is healthy: got healthy result from http:\/\/etcd1:2379 member bd388e7810915853 is healthy: got healthy result from http:\/\/etcd3:2379 member d282ac2ce600c1ce is healthy: got healthy result from http:\/\/etcd2:2379 cluster is healthy<\/code><\/pre>\n<p>  <\/p>\n<p>\u0421\u043e\u0437\u0434\u0430\u0435\u043c \u043a\u0430\u0442\u0430\u043b\u043e\u0433\u0438 \u0434\u043b\u044f Postgresql, \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u0435\u043c \u043d\u0430 \u0432\u0441\u0435\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u0430\u0445:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># mkdir -p \/srv\/pgsql<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u0444\u0430\u0439\u043b \u0434\u043b\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 Postgresql:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">01pgsql.yml<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"plaintext\">version: '3.7'  services:   pgsentinel:     image: sorintlab\/stolon:master-pg10     command:       - gosu       - stolon       - stolon-sentinel       - --cluster-name=stolon-cluster       - --store-backend=etcdv3       - --store-endpoints=http:\/\/etcd1:2379,http:\/\/etcd2:2379,http:\/\/etcd3:2379       - --log-level=debug     networks:       - etcd       - pgsql     deploy:       replicas: 3       update_config:         parallelism: 1         delay: 30s         order: stop-first         failure_action: pause   pgkeeper1:     image: sorintlab\/stolon:master-pg10     hostname: pgkeeper1     command:       - gosu       - stolon       - stolon-keeper       - --pg-listen-address=pgkeeper1       - --pg-repl-username=replica       - --uid=pgkeeper1       - --pg-su-username=postgres       - --pg-su-passwordfile=\/run\/secrets\/pgsql       - --pg-repl-passwordfile=\/run\/secrets\/pgsql_repl       - --data-dir=\/var\/lib\/postgresql\/data       - --cluster-name=stolon-cluster       - --store-backend=etcdv3       - --store-endpoints=http:\/\/etcd1:2379,http:\/\/etcd2:2379,http:\/\/etcd3:2379     networks:       - etcd       - pgsql     environment:       - PGDATA=\/var\/lib\/postgresql\/data     volumes:       - pgkeeper1:\/var\/lib\/postgresql\/data     secrets:       - pgsql       - pgsql_repl     deploy:       replicas: 1       placement:         constraints: [node.labels.nodename == node1]   pgkeeper2:     image: sorintlab\/stolon:master-pg10     hostname: pgkeeper2     command:       - gosu       - stolon        - stolon-keeper       - --pg-listen-address=pgkeeper2       - --pg-repl-username=replica       - --uid=pgkeeper2       - --pg-su-username=postgres       - --pg-su-passwordfile=\/run\/secrets\/pgsql       - --pg-repl-passwordfile=\/run\/secrets\/pgsql_repl       - --data-dir=\/var\/lib\/postgresql\/data       - --cluster-name=stolon-cluster       - --store-backend=etcdv3       - --store-endpoints=http:\/\/etcd1:2379,http:\/\/etcd2:2379,http:\/\/etcd3:2379     networks:       - etcd       - pgsql     environment:       - PGDATA=\/var\/lib\/postgresql\/data     volumes:       - pgkeeper2:\/var\/lib\/postgresql\/data     secrets:       - pgsql       - pgsql_repl     deploy:       replicas: 1       placement:         constraints: [node.labels.nodename == node2]   pgkeeper3:     image: sorintlab\/stolon:master-pg10     hostname: pgkeeper3     command:       - gosu       - stolon        - stolon-keeper       - --pg-listen-address=pgkeeper3       - --pg-repl-username=replica       - --uid=pgkeeper3       - --pg-su-username=postgres       - --pg-su-passwordfile=\/run\/secrets\/pgsql       - --pg-repl-passwordfile=\/run\/secrets\/pgsql_repl       - --data-dir=\/var\/lib\/postgresql\/data       - --cluster-name=stolon-cluster       - --store-backend=etcdv3       - --store-endpoints=http:\/\/etcd1:2379,http:\/\/etcd2:2379,http:\/\/etcd3:2379     networks:       - etcd       - pgsql     environment:       - PGDATA=\/var\/lib\/postgresql\/data     volumes:       - pgkeeper3:\/var\/lib\/postgresql\/data     secrets:       - pgsql       - pgsql_repl     deploy:       replicas: 1       placement:         constraints: [node.labels.nodename == node3]   postgresql:     image: sorintlab\/stolon:master-pg10     command: gosu stolon stolon-proxy --listen-address 0.0.0.0 --cluster-name stolon-cluster --store-backend=etcdv3 --store-endpoints http:\/\/etcd1:2379,http:\/\/etcd2:2379,http:\/\/etcd3:2379     networks:       - etcd       - pgsql     deploy:       replicas: 3       update_config:         parallelism: 1         delay: 30s         order: stop-first         failure_action: rollback  volumes:   pgkeeper1:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/pgsql&quot;   pgkeeper2:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/pgsql&quot;   pgkeeper3:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/pgsql&quot;  secrets:   pgsql:     file: &quot;\/srv\/docker\/postgres&quot;   pgsql_repl:     file: &quot;\/srv\/docker\/replica&quot;  networks:   etcd:     external: true   pgsql:     external: true<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<p>\u0413\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u043c \u0441\u0435\u043a\u0440\u0435\u0442\u044b, \u043f\u0440\u0438\u043c\u0435\u043d\u044f\u0435\u043c \u0444\u0430\u0439\u043b:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># &lt;\/dev\/urandom tr -dc 234567890qwertyuopasdfghjkzxcvbnmQWERTYUPASDFGHKLZXCVBNM | head -c $(((RANDOM%3)+15)) &gt; \/srv\/docker\/replica # &lt;\/dev\/urandom tr -dc 234567890qwertyuopasdfghjkzxcvbnmQWERTYUPASDFGHKLZXCVBNM | head -c $(((RANDOM%3)+15)) &gt; \/srv\/docker\/postgres # docker stack deploy --compose-file 01pgsql.yml pgsql<\/code><\/pre>\n<p>  <\/p>\n<p>\u0421\u043f\u0443\u0441\u0442\u044f \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0432\u0440\u0435\u043c\u044f (\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0432\u044b\u0432\u043e\u0434 \u043a\u043e\u043c\u0430\u043d\u0434\u044b <em>docker service ls<\/em>, \u0447\u0442\u043e \u043f\u043e\u0434\u043d\u044f\u043b\u0438\u0441\u044c \u0432\u0441\u0435 \u0441\u0435\u0440\u0432\u0438\u0441\u044b) \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u0443\u0435\u043c \u043a\u043b\u0430\u0441\u0442\u0435\u0440 Postgresql:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker exec $(docker ps | awk '\/pgkeeper\/ {print $1}') stolonctl --cluster-name=stolon-cluster --store-backend=etcdv3 --store-endpoints=http:\/\/etcd1:2379,http:\/\/etcd2:2379,http:\/\/etcd3:2379 init<\/code><\/pre>\n<p>  <\/p>\n<p>\u041f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u0433\u043e\u0442\u043e\u0432\u043d\u043e\u0441\u0442\u044c \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430 Postgresql:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker exec $(docker ps | awk '\/pgkeeper\/ {print $1}') stolonctl --cluster-name=stolon-cluster --store-backend=etcdv3 --store-endpoints=http:\/\/etcd1:2379,http:\/\/etcd2:2379,http:\/\/etcd3:2379 status === Active sentinels ===  ID      LEADER 26baa11d    false 74e98768    false a8cb002b    true  === Active proxies ===  ID 4d233826 9f562f3b b0c79ff1  === Keepers ===  UID     HEALTHY PG LISTENADDRESS    PG HEALTHY  PG WANTEDGENERATION PG CURRENTGENERATION pgkeeper1   true    pgkeeper1:5432         true     2           2 pgkeeper2   true    pgkeeper2:5432          true            2                   2 pgkeeper3   true    pgkeeper3:5432          true            3                   3  === Cluster Info ===  Master Keeper: pgkeeper3  ===== Keepers\/DB tree =====  pgkeeper3 (master) \u251c\u2500pgkeeper2 \u2514\u2500pgkeeper1 <\/code><\/pre>\n<p>  <\/p>\n<p>\u041d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0435\u043c traefik \u0434\u043b\u044f \u043e\u0442\u043a\u0440\u044b\u0442\u0438\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430\u043c \u0438\u0437\u0432\u043d\u0435:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">03traefik.yml<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"plaintext\">version: '3.7'  services:   traefik:     image: traefik:latest     command: &gt;       --log.level=INFO       --providers.docker=true       --entryPoints.web.address=:80       --providers.providersThrottleDuration=2       --providers.docker.watch=true       --providers.docker.swarmMode=true       --providers.docker.swarmModeRefreshSeconds=15s       --providers.docker.exposedbydefault=false       --accessLog.bufferingSize=0       --api=true       --api.dashboard=true       --api.insecure=true     networks:       - traefik     ports:       - 80:80     volumes:       - \/var\/run\/docker.sock:\/var\/run\/docker.sock     deploy:       replicas: 3       placement:         constraints:           - node.role == manager         preferences:           - spread: node.id       labels:         - traefik.enable=true         - traefik.http.routers.traefik.rule=Host(`traefik.example.com`)         - traefik.http.services.traefik.loadbalancer.server.port=8080         - traefik.docker.network=traefik  networks:   traefik:     external: true<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker stack deploy --compose-file 03traefik.yml traefik<\/code><\/pre>\n<p>  <\/p>\n<p>\u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c Redis Cluster, \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u043d\u0430 \u0432\u0441\u0435\u0445 \u0443\u0437\u043b\u0430\u0445 \u043a\u0430\u0442\u0430\u043b\u043e\u0433 \u0434\u043b\u044f \u0445\u0440\u0430\u043d\u0435\u043d\u0438\u044f:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># mkdir -p \/srv\/redis<\/code><\/pre>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">05redis.yml<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"plaintext\">version: '3.7'  services:   redis-master:     image: 'bitnami\/redis:latest'     networks:       - redis     ports:       - '6379:6379'     environment:       - REDIS_REPLICATION_MODE=master       - REDIS_PASSWORD=xxxxxxxxxxx     deploy:       mode: global       restart_policy:         condition: any     volumes:       - 'redis:\/opt\/bitnami\/redis\/etc\/'    redis-replica:     image: 'bitnami\/redis:latest'     networks:       - redis     ports:       - '6379'     depends_on:       - redis-master     environment:       - REDIS_REPLICATION_MODE=slave       - REDIS_MASTER_HOST=redis-master       - REDIS_MASTER_PORT_NUMBER=6379       - REDIS_MASTER_PASSWORD=xxxxxxxxxxx       - REDIS_PASSWORD=xxxxxxxxxxx     deploy:       mode: replicated       replicas: 3       update_config:         parallelism: 1         delay: 10s       restart_policy:         condition: any    redis-sentinel:     image: 'bitnami\/redis:latest'     networks:       - redis     ports:       - '16379'     depends_on:       - redis-master       - redis-replica     entrypoint: |       bash -c 'bash -s &lt;&lt;EOF       &quot;\/bin\/bash&quot; -c &quot;cat &lt;&lt;EOF &gt; \/opt\/bitnami\/redis\/etc\/sentinel.conf       port 16379       dir \/tmp       sentinel monitor master-node redis-master 6379 2       sentinel down-after-milliseconds master-node 5000       sentinel parallel-syncs master-node 1       sentinel failover-timeout master-node 5000       sentinel auth-pass master-node xxxxxxxxxxx       sentinel announce-ip redis-sentinel       sentinel announce-port 16379       EOF&quot;       &quot;\/bin\/bash&quot; -c &quot;redis-sentinel \/opt\/bitnami\/redis\/etc\/sentinel.conf&quot;       EOF'     deploy:       mode: global       restart_policy:         condition: any  volumes:   redis:     driver: local     driver_opts:       type: 'none'       o: 'bind'       device: &quot;\/srv\/redis&quot;  networks:   redis:     external: true<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker stack deploy --compose-file 05redis.yml redis<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c Docker Registry:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">06registry.yml<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"plaintext\">version: '3.7'  services:   registry:     image: registry:2.6     networks:       - traefik     volumes:       - registry_data:\/var\/lib\/registry     deploy:       replicas: 1       placement:         constraints: [node.role == manager]       restart_policy:         condition: on-failure       labels:         - traefik.enable=true         - traefik.http.routers.registry.rule=Host(`registry.example.com`)         - traefik.http.services.registry.loadbalancer.server.port=5000         - traefik.docker.network=traefik  volumes:   registry_data:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/docker\/registry&quot;  networks:   traefik:     external: true<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># mkdir \/srv\/docker\/registry # docker stack deploy --compose-file 06registry.yml registry<\/code><\/pre>\n<p>  <\/p>\n<p>\u041d\u0443 \u0438 \u043d\u0430\u043a\u043e\u043d\u0435\u0446 \u2014 GitLab:<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">08gitlab-runner.yml<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"plaintext\">version: '3.7'  services:   gitlab:     image: gitlab\/gitlab-ce:latest     networks:       - pgsql       - redis       - traefik       - gitlab     ports:       - 22222:22     environment:       GITLAB_OMNIBUS_CONFIG: |         postgresql['enable'] = false         redis['enable'] = false         gitlab_rails['registry_enabled'] = false         gitlab_rails['db_username'] = &quot;gitlab&quot;         gitlab_rails['db_password'] = &quot;XXXXXXXXXXX&quot;         gitlab_rails['db_host'] = &quot;postgresql&quot;         gitlab_rails['db_port'] = &quot;5432&quot;         gitlab_rails['db_database'] = &quot;gitlab&quot;         gitlab_rails['db_adapter'] = 'postgresql'         gitlab_rails['db_encoding'] = 'utf8'         gitlab_rails['redis_host'] = 'redis'         gitlab_rails['redis_port'] = '6379'         gitlab_rails['redis_password'] = 'xxxxxxxxxxx'         gitlab_rails['smtp_enable'] = true         gitlab_rails['smtp_address'] = &quot;smtp.yandex.ru&quot;         gitlab_rails['smtp_port'] = 465         gitlab_rails['smtp_user_name'] = &quot;noreply@example.com&quot;         gitlab_rails['smtp_password'] = &quot;xxxxxxxxx&quot;         gitlab_rails['smtp_domain'] = &quot;example.com&quot;         gitlab_rails['gitlab_email_from'] = 'noreply@example.com'         gitlab_rails['smtp_authentication'] = &quot;login&quot;         gitlab_rails['smtp_tls'] = true         gitlab_rails['smtp_enable_starttls_auto'] = true         gitlab_rails['smtp_openssl_verify_mode'] = 'peer'         external_url 'http:\/\/gitlab.example.com\/'         gitlab_rails['gitlab_shell_ssh_port'] = 22222     volumes:       - gitlab_conf:\/etc\/gitlab       - gitlab_logs:\/var\/log\/gitlab       - gitlab_data:\/var\/opt\/gitlab     deploy:       mode: replicated       replicas: 1       placement:         constraints:         - node.role == manager       labels:         - traefik.enable=true         - traefik.http.routers.gitlab.rule=Host(`gitlab.example.com`)         - traefik.http.services.gitlab.loadbalancer.server.port=80         - traefik.docker.network=traefik   gitlab-runner:     image: gitlab\/gitlab-runner:latest     networks:       - gitlab     volumes:       - gitlab_runner_conf:\/etc\/gitlab       - \/var\/run\/docker.sock:\/var\/run\/docker.sock     deploy:       mode: replicated       replicas: 1       placement:         constraints:         - node.role == manager  volumes:   gitlab_conf:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/docker\/gitlab\/conf&quot;   gitlab_logs:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/docker\/gitlab\/logs&quot;   gitlab_data:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/docker\/gitlab\/data&quot;   gitlab_runner_conf:     driver: local     driver_opts:       type: none       o: bind       device: &quot;\/srv\/docker\/gitlab\/runner&quot;  networks:   pgsql:     external: true   redis:     external: true   traefik:     external: true   gitlab:     external: true<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># mkdir -p \/srv\/docker\/gitlab\/conf # mkdir -p \/srv\/docker\/gitlab\/logs # mkdir -p \/srv\/docker\/gitlab\/data # mkdir -p \/srv\/docker\/gitlab\/runner # docker stack deploy --compose-file 08gitlab-runner.yml gitlab<\/code><\/pre>\n<p>  <\/p>\n<p>\u0418\u0442\u043e\u0433\u043e\u0432\u043e\u0435 \u0441\u043e\u0441\u0442\u043e\u044f\u043d\u0438\u0435 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0430 \u0438 \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># docker service ls ID                  NAME                   MODE                REPLICAS            IMAGE                          PORTS lef9n3m92buq        etcd_etcd1             replicated          1\/1                 quay.io\/coreos\/etcd:latest ij6uyyo792x5        etcd_etcd2             replicated          1\/1                 quay.io\/coreos\/etcd:latest fqttqpjgp6pp        etcd_etcd3             replicated          1\/1                 quay.io\/coreos\/etcd:latest hq5iyga28w33        gitlab_gitlab          replicated          1\/1                 gitlab\/gitlab-ce:latest        *:22222-&gt;22\/tcp dt7s6vs0q4qc        gitlab_gitlab-runner   replicated          1\/1                 gitlab\/gitlab-runner:latest k7uoezno0h9n        pgsql_pgkeeper1        replicated          1\/1                 sorintlab\/stolon:master-pg10 cnrwul4r4nse        pgsql_pgkeeper2        replicated          1\/1                 sorintlab\/stolon:master-pg10 frflfnpty7tr        pgsql_pgkeeper3        replicated          1\/1                 sorintlab\/stolon:master-pg10 x7pqqchi52kq        pgsql_pgsentinel       replicated          3\/3                 sorintlab\/stolon:master-pg10 mwu2wl8fti4r        pgsql_postgresql       replicated          3\/3                 sorintlab\/stolon:master-pg10 9hkbe2vksbzb        redis_redis-master     global              3\/3                 bitnami\/redis:latest           *:6379-&gt;6379\/tcp l88zn8cla7dc        redis_redis-replica    replicated          3\/3                 bitnami\/redis:latest           *:30003-&gt;6379\/tcp 1utp309xfmsy        redis_redis-sentinel   global              3\/3                 bitnami\/redis:latest           *:30002-&gt;16379\/tcp oteb824ylhyp        registry_registry      replicated          1\/1                 registry:2.6 qovrah8nzzu8        traefik_traefik        replicated          3\/3                 traefik:latest                 *:80-&gt;80\/tcp, *:443-&gt;443\/tcp<\/code><\/pre>\n<p>  <\/p>\n<p>\u0427\u0442\u043e \u0435\u0449\u0435 \u043c\u043e\u0436\u043d\u043e \u0443\u043b\u0443\u0447\u0448\u0438\u0442\u044c? \u041e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0432 Traefik \u0440\u0430\u0431\u043e\u0442\u0443 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 \u043f\u043e https, \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u0448\u0438\u0444\u0440\u043e\u0432\u0430\u043d\u0438\u0435 tls \u0434\u043b\u044f Postgresql \u0438 Redis. \u041d\u043e \u0432 \u0446\u0435\u043b\u043e\u043c \u0443\u0436\u0435 \u043c\u043e\u0436\u043d\u043e \u043e\u0442\u0434\u0430\u0432\u0430\u0442\u044c \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0430\u043c \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 PoC. \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c \u0442\u0435\u043f\u0435\u0440\u044c \u0430\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u044b Docker.<\/p>\n<p>  <\/p>\n<h2 id=\"podman\">Podman<\/h2>\n<p>  <\/p>\n<p>\u0415\u0449\u0435 \u043e\u0434\u0438\u043d \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u044b\u0439 engine \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432, \u0441\u0433\u0440\u0443\u043f\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u043f\u043e \u043f\u043e\u0434\u0430\u043c (pods, \u0433\u0440\u0443\u043f\u043f\u044b \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432, \u0440\u0430\u0437\u0432\u0435\u0440\u043d\u0443\u0442\u044b\u0445 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u043e). \u0412 \u043e\u0442\u043b\u0438\u0447\u0438\u0435 \u043e\u0442 Docker \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u0435\u0442 \u043a\u0430\u043a\u043e\u0433\u043e-\u043b\u0438\u0431\u043e \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432, \u0432\u0441\u044f \u0440\u0430\u0431\u043e\u0442\u0430 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u0447\u0435\u0440\u0435\u0437 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 libpod. \u0422\u0430\u043a\u0436\u0435 \u043d\u0430\u043f\u0438\u0441\u0430\u043d \u043d\u0430 Go, \u043d\u0443\u0436\u0434\u0430\u0435\u0442\u0441\u044f \u0432 OCI-\u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u043c runtime \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 runC.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/tc\/an\/_2\/tcan_24atrvz8ac1fx9vzby_lzc.png\"><\/p>\n<p>  <\/p>\n<p>\u0420\u0430\u0431\u043e\u0442\u0430 \u0441 Podman \u0432 \u0446\u0435\u043b\u043e\u043c \u043d\u0430\u043f\u043e\u043c\u0438\u043d\u0430\u0435\u0442 \u0442\u0430\u043a\u043e\u0432\u0443\u044e \u0434\u043b\u044f Docker, \u0432\u043f\u043b\u043e\u0442\u044c \u0434\u043e \u0442\u043e\u0433\u043e, \u0447\u0442\u043e \u043c\u043e\u0436\u043d\u043e \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0442\u0430\u043a (\u0437\u0430\u044f\u0432\u043b\u0435\u043d\u043e \u0443 \u043c\u043d\u043e\u0433\u0438\u0445 \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0432\u0448\u0438\u0445, \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0438 \u0438 \u0430\u0432\u0442\u043e\u0440\u043e\u043c \u044d\u0442\u043e\u0439 \u0441\u0442\u0430\u0442\u044c\u0438):<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\">$ alias docker=podman<\/code><\/pre>\n<p>  <\/p>\n<p>\u0438 \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u0434\u043e\u043b\u0436\u0430\u0442\u044c \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c. \u0412 \u0446\u0435\u043b\u043e\u043c \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u044f \u0441 Podman \u0432\u0435\u0441\u044c\u043c\u0430 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u0430\u044f, \u0432\u0435\u0434\u044c \u0435\u0441\u043b\u0438 \u0440\u0430\u043d\u043d\u0438\u0435 \u0432\u0435\u0440\u0441\u0438\u0438 Kubernetes \u0440\u0430\u0431\u043e\u0442\u0430\u043b\u0438 \u0441 Docker, \u0442\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u0441 2015 \u0433\u043e\u0434\u0430, \u043f\u043e\u0441\u043b\u0435 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u043c\u0438\u0440\u0430 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 (OCI \u2014 Open Container Initiative) \u0438 \u0432\u044b\u0434\u0435\u043b\u0435\u043d\u0438\u044f \u0438\u0437 Docker \u043d\u0430 containerd \u0438 runC, \u0440\u0430\u0437\u0432\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0430\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u0430 Docker \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0432 Kubernetes: CRI-O. Podman \u0432 \u044d\u0442\u043e\u043c \u043f\u043b\u0430\u043d\u0435 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0430\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u043e\u0439 Docker, \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u043e\u0439 \u043f\u043e \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0430\u043c Kubernetes, \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435 \u0438 \u043f\u043e \u0433\u0440\u0443\u043f\u043f\u0438\u0440\u043e\u0432\u043a\u0435 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432, \u043d\u043e \u043e\u0441\u043d\u043e\u0432\u043d\u0430\u044f \u0446\u0435\u043b\u044c \u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043e\u0432\u0430\u043d\u0438\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u2014 \u0437\u0430\u043f\u0443\u0441\u043a \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 \u0432 \u0441\u0442\u0438\u043b\u0435 Docker \u0431\u0435\u0437 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u0441\u0435\u0440\u0432\u0438\u0441\u043e\u0432. \u041f\u043e \u043f\u043e\u043d\u044f\u0442\u043d\u044b\u043c \u043f\u0440\u0438\u0447\u0438\u043d\u0430\u043c \u043d\u0435\u0442 \u043d\u0430\u043b\u0438\u0447\u0438\u044f swarm mode, \u0442\u0430\u043a \u043a\u0430\u043a \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u0447\u0438\u043a\u0438 \u044f\u0432\u043d\u043e \u0433\u043e\u0432\u043e\u0440\u044f\u0442 \u043e \u0442\u043e\u043c, \u0447\u0442\u043e \u0435\u0441\u043b\u0438 \u043d\u0430\u0434\u043e \u043a\u043b\u0430\u0441\u0442\u0435\u0440 \u2014 \u0431\u0435\u0440\u0438\u0442\u0435 Kubernetes.<\/p>\n<p>  <\/p>\n<h3 id=\"ustanovka\">\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430<\/h3>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0438 \u0432 Centos 7 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0430\u043a\u0442\u0438\u0432\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0439 Extras, \u043f\u043e\u0441\u043b\u0435 \u0447\u0435\u0433\u043e \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0432\u0441\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># yum -y install podman<\/code><\/pre>\n<p>  <\/p>\n<h3 id=\"drugie-vozmozhnosti-1\">\u0414\u0440\u0443\u0433\u0438\u0435 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438<\/h3>\n<p>  <\/p>\n<p>Podman \u043c\u043e\u0436\u0435\u0442 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u044e\u043d\u0438\u0442\u044b \u0434\u043b\u044f systemd, \u0442\u0430\u043a\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c \u0440\u0435\u0448\u0430\u044f \u0437\u0430\u0434\u0430\u0447\u0443 \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 \u043f\u043e\u0441\u043b\u0435 \u043f\u0435\u0440\u0435\u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0441\u0435\u0440\u0432\u0435\u0440\u0430. \u0414\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0437\u0430\u044f\u0432\u043b\u0435\u043d\u0430 \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u0430\u044f \u0440\u0430\u0431\u043e\u0442\u0430 systemd \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 pid 1 \u0432 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0435. \u0414\u043b\u044f \u0441\u0431\u043e\u0440\u043a\u0438 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 \u0438\u0434\u0435\u0442 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u0439 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442 buildah, \u0435\u0441\u0442\u044c \u0442\u0430\u043a\u0436\u0435 \u0441\u0442\u043e\u0440\u043e\u043d\u043d\u0438\u0435 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b \u2014 \u0430\u043d\u0430\u043b\u043e\u0433\u0438 docker-compose, \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0435 \u0444\u0430\u0439\u043b\u044b, \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u044b\u0435 \u0441 Kubernetes, \u0442\u0430\u043a \u0447\u0442\u043e \u043f\u0435\u0440\u0435\u0445\u043e\u0434 \u0441 Podman \u043d\u0430 Kubernetes \u0443\u043f\u0440\u043e\u0449\u0435\u043d \u043d\u0430\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u044d\u0442\u043e \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e.<\/p>\n<p>  <\/p>\n<h3 id=\"rabota-s-podman\">\u0420\u0430\u0431\u043e\u0442\u0430 \u0441 Podman<\/h3>\n<p>  <\/p>\n<p>\u041f\u043e\u0441\u043a\u043e\u043b\u044c\u043a\u0443 \u043d\u0435\u0442 swarm mode (\u043f\u0440\u0435\u0434\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u0442\u0441\u044f \u043f\u0435\u0440\u0435\u0445\u043e\u0434 \u043d\u0430 Kubernetes, \u0435\u0441\u043b\u0438 \u043d\u0430\u0434\u043e \u043a\u043b\u0430\u0441\u0442\u0435\u0440) \u2014 \u0441\u043e\u0431\u0438\u0440\u0430\u0442\u044c \u0431\u0443\u0434\u0435\u043c \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u044b\u043c\u0438 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430\u043c\u0438.<\/p>\n<p>  <\/p>\n<p>\u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c podman-compose:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># yum -y install python3-pip # pip3 install podman-compose<\/code><\/pre>\n<p>  <\/p>\n<p>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0438\u0440\u0443\u044e\u0449\u0438\u0439 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u044b\u0439 \u0444\u0430\u0439\u043b \u0434\u043b\u044f podman \u043d\u0435\u043c\u043d\u043e\u0433\u043e \u043e\u0442\u043b\u0438\u0447\u0430\u0435\u0442\u0441\u044f, \u0442\u0430\u043a \u043a \u043f\u0440\u0438\u043c\u0435\u0440\u0443 \u043f\u0440\u0438\u0448\u043b\u043e\u0441\u044c \u043f\u0435\u0440\u0435\u043d\u0435\u0441\u0442\u0438 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u0443\u044e \u0441\u0435\u043a\u0446\u0438\u044e volumes \u043d\u0430\u043f\u0440\u044f\u043c\u0443\u044e \u0432 \u0441\u0435\u043a\u0446\u0438\u044e \u0441 \u0441\u0435\u0440\u0432\u0438\u0441\u0430\u043c\u0438.<\/p>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">gitlab-podman.yml<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"plaintext\">version: '3.7'  services:   gitlab:     image: gitlab\/gitlab-ce:latest     hostname: gitlab.example.com     restart: unless-stopped     environment:       GITLAB_OMNIBUS_CONFIG: |         gitlab_rails['gitlab_shell_ssh_port'] = 22222     ports:       - &quot;80:80&quot;       - &quot;22222:22&quot;     volumes:       - \/srv\/podman\/gitlab\/conf:\/etc\/gitlab       - \/srv\/podman\/gitlab\/data:\/var\/opt\/gitlab       - \/srv\/podman\/gitlab\/logs:\/var\/log\/gitlab     networks:       - gitlab    gitlab-runner:     image: gitlab\/gitlab-runner:alpine     restart: unless-stopped     depends_on:       - gitlab     volumes:       - \/srv\/podman\/gitlab\/runner:\/etc\/gitlab-runner       - \/var\/run\/docker.sock:\/var\/run\/docker.sock     networks:       - gitlab  networks:   gitlab:<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># podman-compose -f gitlab-runner.yml -d up<\/code><\/pre>\n<p>  <\/p>\n<p>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0440\u0430\u0431\u043e\u0442\u044b:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># podman ps CONTAINER ID  IMAGE                                  COMMAND               CREATED             STATUS                 PORTS                                      NAMES da53da946c01  docker.io\/gitlab\/gitlab-runner:alpine  run --user=gitlab...  About a minute ago  Up About a minute ago  0.0.0.0:22222-&gt;22\/tcp, 0.0.0.0:80-&gt;80\/tcp  root_gitlab-runner_1 781c0103c94a  docker.io\/gitlab\/gitlab-ce:latest      \/assets\/wrapper       About a minute ago  Up About a minute ago  0.0.0.0:22222-&gt;22\/tcp, 0.0.0.0:80-&gt;80\/tcp  root_gitlab_1<\/code><\/pre>\n<p>  <\/p>\n<p>\u0414\u0430\u0432\u0430\u0439\u0442\u0435 \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0438\u043c, \u0447\u0442\u043e \u043e\u043d \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u0442 \u0434\u043b\u044f systemd \u0438 kubernetes, \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u043d\u0430\u0434\u043e \u0443\u0437\u043d\u0430\u0442\u044c \u0438\u043c\u044f \u0438\u043b\u0438 id \u043f\u043e\u0434\u0430:<\/p>\n<p>  <\/p>\n<pre><code class=\"plaintext\"># podman pod ls POD ID         NAME   STATUS    CREATED          # OF CONTAINERS   INFRA ID 71fc2b2a5c63   root   Running   11 minutes ago   3                 db40ab8bf84b<\/code><\/pre>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">Kubernetes:<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"plaintext\"># podman generate kube 71fc2b2a5c63 # Generation of Kubernetes YAML is still under development! # # Save the output of this file and use kubectl create -f to import # it into Kubernetes. # # Created with podman-1.6.4 apiVersion: v1 kind: Pod metadata:   creationTimestamp: &quot;2020-07-29T19:22:40Z&quot;   labels:     app: root   name: root spec:   containers:   - command:     - \/assets\/wrapper     env:     - name: PATH       value: \/opt\/gitlab\/embedded\/bin:\/opt\/gitlab\/bin:\/assets:\/usr\/local\/sbin:\/usr\/local\/bin:\/usr\/sbin:\/usr\/bin:\/sbin:\/bin     - name: TERM       value: xterm     - name: HOSTNAME       value: gitlab.example.com     - name: container       value: podman     - name: GITLAB_OMNIBUS_CONFIG       value: |         gitlab_rails['gitlab_shell_ssh_port'] = 22222     - name: LANG       value: C.UTF-8     image: docker.io\/gitlab\/gitlab-ce:latest     name: rootgitlab1     ports:     - containerPort: 22       hostPort: 22222       protocol: TCP     - containerPort: 80       hostPort: 80       protocol: TCP     resources: {}     securityContext:       allowPrivilegeEscalation: true       capabilities: {}       privileged: false       readOnlyRootFilesystem: false     volumeMounts:     - mountPath: \/var\/opt\/gitlab       name: srv-podman-gitlab-data     - mountPath: \/var\/log\/gitlab       name: srv-podman-gitlab-logs     - mountPath: \/etc\/gitlab       name: srv-podman-gitlab-conf     workingDir: \/   - command:     - run     - --user=gitlab-runner     - --working-directory=\/home\/gitlab-runner     env:     - name: PATH       value: \/usr\/local\/sbin:\/usr\/local\/bin:\/usr\/sbin:\/usr\/bin:\/sbin:\/bin     - name: TERM       value: xterm     - name: HOSTNAME     - name: container       value: podman     image: docker.io\/gitlab\/gitlab-runner:alpine     name: rootgitlab-runner1     resources: {}     securityContext:       allowPrivilegeEscalation: true       capabilities: {}       privileged: false       readOnlyRootFilesystem: false     volumeMounts:     - mountPath: \/etc\/gitlab-runner       name: srv-podman-gitlab-runner     - mountPath: \/var\/run\/docker.sock       name: var-run-docker.sock     workingDir: \/   volumes:   - hostPath:       path: \/srv\/podman\/gitlab\/runner       type: Directory     name: srv-podman-gitlab-runner   - hostPath:       path: \/var\/run\/docker.sock       type: File     name: var-run-docker.sock   - hostPath:       path: \/srv\/podman\/gitlab\/data       type: Directory     name: srv-podman-gitlab-data   - hostPath:       path: \/srv\/podman\/gitlab\/logs       type: Directory     name: srv-podman-gitlab-logs   - hostPath:       path: \/srv\/podman\/gitlab\/conf       type: Directory     name: srv-podman-gitlab-conf status: {}<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<div class=\"spoiler\" role=\"button\" tabindex=\"0\">                         <b class=\"spoiler_title\">Systemd:<\/b>                         <\/p>\n<div class=\"spoiler_text\">\n<pre><code class=\"plaintext\"># podman generate systemd 71fc2b2a5c63 # pod-71fc2b2a5c6346f0c1c86a2dc45dbe78fa192ea02aac001eb8347ccb8c043c26.service # autogenerated by Podman 1.6.4 # Thu Jul 29 15:23:28 EDT 2020  [Unit] Description=Podman pod-71fc2b2a5c6346f0c1c86a2dc45dbe78fa192ea02aac001eb8347ccb8c043c26.service Documentation=man:podman-generate-systemd(1) Requires=container-781c0103c94aaa113c17c58d05ddabf8df4bf39707b664abcf17ed2ceff467d3.service container-da53da946c01449f500aa5296d9ea6376f751948b17ca164df438b7df6607864.service Before=container-781c0103c94aaa113c17c58d05ddabf8df4bf39707b664abcf17ed2ceff467d3.service container-da53da946c01449f500aa5296d9ea6376f751948b17ca164df438b7df6607864.service  [Service] Restart=on-failure ExecStart=\/usr\/bin\/podman start db40ab8bf84bf35141159c26cb6e256b889c7a98c0418eee3c4aa683c14fccaa ExecStop=\/usr\/bin\/podman stop -t 10 db40ab8bf84bf35141159c26cb6e256b889c7a98c0418eee3c4aa683c14fccaa KillMode=none Type=forking PIDFile=\/var\/run\/containers\/storage\/overlay-containers\/db40ab8bf84bf35141159c26cb6e256b889c7a98c0418eee3c4aa683c14fccaa\/userdata\/conmon.pid  [Install] WantedBy=multi-user.target # container-da53da946c01449f500aa5296d9ea6376f751948b17ca164df438b7df6607864.service # autogenerated by Podman 1.6.4 # Thu Jul 29 15:23:28 EDT 2020  [Unit] Description=Podman container-da53da946c01449f500aa5296d9ea6376f751948b17ca164df438b7df6607864.service Documentation=man:podman-generate-systemd(1) RefuseManualStart=yes RefuseManualStop=yes BindsTo=pod-71fc2b2a5c6346f0c1c86a2dc45dbe78fa192ea02aac001eb8347ccb8c043c26.service After=pod-71fc2b2a5c6346f0c1c86a2dc45dbe78fa192ea02aac001eb8347ccb8c043c26.service  [Service] Restart=on-failure ExecStart=\/usr\/bin\/podman start da53da946c01449f500aa5296d9ea6376f751948b17ca164df438b7df6607864 ExecStop=\/usr\/bin\/podman stop -t 10 da53da946c01449f500aa5296d9ea6376f751948b17ca164df438b7df6607864 KillMode=none Type=forking PIDFile=\/var\/run\/containers\/storage\/overlay-containers\/da53da946c01449f500aa5296d9ea6376f751948b17ca164df438b7df6607864\/userdata\/conmon.pid  [Install] WantedBy=multi-user.target # container-781c0103c94aaa113c17c58d05ddabf8df4bf39707b664abcf17ed2ceff467d3.service # autogenerated by Podman 1.6.4 # Thu Jul 29 15:23:28 EDT 2020  [Unit] Description=Podman container-781c0103c94aaa113c17c58d05ddabf8df4bf39707b664abcf17ed2ceff467d3.service Documentation=man:podman-generate-systemd(1) RefuseManualStart=yes RefuseManualStop=yes BindsTo=pod-71fc2b2a5c6346f0c1c86a2dc45dbe78fa192ea02aac001eb8347ccb8c043c26.service After=pod-71fc2b2a5c6346f0c1c86a2dc45dbe78fa192ea02aac001eb8347ccb8c043c26.service  [Service] Restart=on-failure ExecStart=\/usr\/bin\/podman start 781c0103c94aaa113c17c58d05ddabf8df4bf39707b664abcf17ed2ceff467d3 ExecStop=\/usr\/bin\/podman stop -t 10 781c0103c94aaa113c17c58d05ddabf8df4bf39707b664abcf17ed2ceff467d3 KillMode=none Type=forking PIDFile=\/var\/run\/containers\/storage\/overlay-containers\/781c0103c94aaa113c17c58d05ddabf8df4bf39707b664abcf17ed2ceff467d3\/userdata\/conmon.pid  [Install] WantedBy=multi-user.target<\/code><\/pre>\n<\/div><\/div>\n<p>  <\/p>\n<p>\u041a \u0441\u043e\u0436\u0430\u043b\u0435\u043d\u0438\u044e \u043a\u0440\u043e\u043c\u0435 \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 \u0441\u0433\u0435\u043d\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u044e\u043d\u0438\u0442 \u0434\u043b\u044f systemd \u0431\u043e\u043b\u044c\u0448\u0435 \u043d\u0438\u0447\u0435\u0433\u043e \u043d\u0435 \u0434\u0435\u043b\u0430\u0435\u0442 (\u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0437\u0430\u0447\u0438\u0441\u0442\u043a\u0443 \u0441\u0442\u0430\u0440\u044b\u0445 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u043e\u0432 \u043f\u0440\u0438 \u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u043a\u0435 \u0442\u0430\u043a\u043e\u0433\u043e \u0441\u0435\u0440\u0432\u0438\u0441\u0430), \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u0442\u0430\u043a\u0438\u0435 \u0432\u0435\u0449\u0438 \u043f\u0440\u0438\u0434\u0435\u0442\u0441\u044f \u0434\u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c \u0441\u0430\u043c\u043e\u0441\u0442\u043e\u044f\u0442\u0435\u043b\u044c\u043d\u043e.<\/p>\n<p>  <\/p>\n<p>\u0412 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0435 Podman \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c, \u0447\u0442\u043e \u0442\u0430\u043a\u043e\u0435 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u044b, \u043f\u0435\u0440\u0435\u043d\u0435\u0441\u0442\u0438 \u0441\u0442\u0430\u0440\u044b\u0435 \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 \u0434\u043b\u044f docker-compose, \u043f\u043e\u0441\u043b\u0435 \u0447\u0435\u0433\u043e \u0443\u0439\u0442\u0438 \u0432 \u0441\u0442\u043e\u0440\u043e\u043d\u0443 Kubernetes, \u0435\u0441\u043b\u0438 \u043d\u0430\u0434\u043e \u043d\u0430 \u043a\u043b\u0430\u0441\u0442\u0435\u0440, \u043b\u0438\u0431\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0431\u043e\u043b\u0435\u0435 \u043f\u0440\u043e\u0441\u0442\u0443\u044e \u0432 \u0440\u0430\u0431\u043e\u0442\u0435 \u0430\u043b\u044c\u0442\u0435\u0440\u043d\u0430\u0442\u0438\u0432\u0443 Docker.<\/p>\n<p>  <\/p>\n<h2 id=\"rkt\">rkt<\/h2>\n<p>  <\/p>\n<p>\u041f\u0440\u043e\u0435\u043a\u0442 <a href=\"https:\/\/github.com\/rkt\/rkt\/issues\/4024\">\u0443\u0448\u0435\u043b \u0432 \u0430\u0440\u0445\u0438\u0432<\/a> \u043f\u0440\u0438\u043c\u0435\u0440\u043d\u043e \u043f\u043e\u043b\u0433\u043e\u0434\u0430 \u043d\u0430\u0437\u0430\u0434 \u0438\u0437-\u0437\u0430 \u0442\u043e\u0433\u043e, \u0447\u0442\u043e \u0435\u0433\u043e \u043a\u0443\u043f\u0438\u043b RedHat, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043d\u0435 \u0431\u0443\u0434\u0443 \u043e\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c\u0441\u044f \u043d\u0430 \u043d\u0435\u043c \u0434\u0435\u0442\u0430\u043b\u044c\u043d\u0435\u0435. \u0412 \u0446\u0435\u043b\u043e\u043c \u043e\u043d \u043e\u0441\u0442\u0430\u0432\u043b\u044f\u043b \u0432\u0435\u0441\u044c\u043c\u0430 \u043d\u0435\u043f\u043b\u043e\u0445\u043e\u0435 \u0432\u043f\u0435\u0447\u0430\u0442\u043b\u0435\u043d\u0438\u0435, \u043e\u0434\u043d\u0430\u043a\u043e \u043f\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044e \u0441 Docker \u0438 \u0442\u0435\u043c \u0431\u043e\u043b\u0435\u0435 \u0441 Podman \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u043a\u043e\u043c\u0431\u0430\u0439\u043d\u043e\u043c. \u0421\u0443\u0449\u0435\u0441\u0442\u0432\u043e\u0432\u0430\u043b \u0442\u0430\u043a\u0436\u0435 \u0434\u0438\u0441\u0442\u0440\u0438\u0431\u0443\u0442\u0438\u0432 CoreOS, \u043f\u043e\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0439 \u043d\u0430 \u043e\u0441\u043d\u043e\u0432\u0435 rkt (\u0445\u043e\u0442\u044f \u0443 \u043d\u0438\u0445 \u0438\u0437\u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e \u0431\u044b\u043b Docker), \u043e\u0434\u043d\u0430\u043a\u043e \u0435\u0433\u043e \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 \u0442\u0430\u043a\u0436\u0435 \u043e\u043a\u043e\u043d\u0447\u0438\u043b\u0430\u0441\u044c \u043f\u043e\u0441\u043b\u0435 \u043f\u043e\u043a\u0443\u043f\u043a\u0438 RedHat.<\/p>\n<p>  <\/p>\n<h2 id=\"plash\">Plash<\/h2>\n<p>  <\/p>\n<p>\u0415\u0449\u0435 <a href=\"http:\/\/plash.io\/\">\u043e\u0434\u0438\u043d \u043f\u0440\u043e\u0435\u043a\u0442<\/a>, \u0430\u0432\u0442\u043e\u0440 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0445\u043e\u0442\u0435\u043b \u043f\u0440\u043e\u0441\u0442\u043e \u0441\u043e\u0431\u0438\u0440\u0430\u0442\u044c \u0438 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u044b. \u0421\u0443\u0434\u044f \u043f\u043e \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 \u0438 \u043a\u043e\u0434\u0443 \u2014 \u0430\u0432\u0442\u043e\u0440 \u043d\u0435 \u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043b \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0430\u043c, \u0430 \u043f\u0440\u043e\u0441\u0442\u043e \u0440\u0435\u0448\u0438\u043b \u043d\u0430\u043f\u0438\u0441\u0430\u0442\u044c \u0441\u0432\u043e\u044e \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044e, \u0447\u0442\u043e \u0432 \u043f\u0440\u0438\u043d\u0446\u0438\u043f\u0435 \u0438 \u0441\u0434\u0435\u043b\u0430\u043b.<\/p>\n<p>  <\/p>\n<h2 id=\"vyvody\">\u0412\u044b\u0432\u043e\u0434\u044b<\/h2>\n<p>  <\/p>\n<p>\u0421\u0438\u0442\u0443\u0430\u0446\u0438\u044f \u043f\u0440\u0438 \u043d\u0430\u043b\u0438\u0447\u0438\u0438 Kubernetes \u0441\u043a\u043b\u0430\u0434\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0432\u0435\u0441\u044c\u043c\u0430 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u0430\u044f: \u0441 \u043e\u0434\u043d\u043e\u0439 \u0441\u0442\u043e\u0440\u043e\u043d\u044b \u0441 Docker \u043c\u043e\u0436\u043d\u043e \u0441\u043e\u0431\u0440\u0430\u0442\u044c \u043a\u043b\u0430\u0441\u0442\u0435\u0440 (\u0432 swarm mode), \u0441 \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u0434\u0430\u0436\u0435 \u043c\u043e\u0436\u043d\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u043f\u0440\u043e\u0434\u0443\u043a\u0442\u043e\u0432\u044b\u0435 \u0441\u0440\u0435\u0434\u044b \u0434\u043b\u044f \u043a\u043b\u0438\u0435\u043d\u0442\u043e\u0432, \u044d\u0442\u043e \u043e\u0441\u043e\u0431\u0435\u043d\u043d\u043e \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u043e \u0434\u043b\u044f \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0438\u0445 \u043a\u043e\u043c\u0430\u043d\u0434 (3-5 \u0447\u0435\u043b\u043e\u0432\u0435\u043a), \u043b\u0438\u0431\u043e \u043f\u0440\u0438 \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u043e\u0431\u0449\u0435\u0439 \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0435, \u0438\u043b\u0438 \u0436\u0435 \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0438\u044e \u0436\u0435\u043b\u0430\u043d\u0438\u044f \u0440\u0430\u0437\u0431\u0438\u0440\u0430\u0442\u044c\u0441\u044f \u0432 \u0442\u043e\u043d\u043a\u043e\u0441\u0442\u044f\u0445 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 Kubernetes \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435 \u0438 \u0434\u043b\u044f \u0432\u044b\u0441\u043e\u043a\u0438\u0445 \u043d\u0430\u0433\u0440\u0443\u0437\u043e\u043a. <\/p>\n<p>  <\/p>\n<p>Podman \u043d\u0435 \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0438\u0432\u0430\u0435\u0442 \u043f\u043e\u043b\u043d\u043e\u0439 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0441\u0442\u0438, \u043d\u043e \u0443 \u043d\u0435\u0433\u043e \u0435\u0441\u0442\u044c \u043e\u0434\u043d\u043e \u0432\u0430\u0436\u043d\u043e\u0435 \u043f\u0440\u0435\u0438\u043c\u0443\u0449\u0435\u0441\u0442\u0432\u043e \u2014 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u0438\u043c\u043e\u0441\u0442\u044c \u0441 Kubernetes, \u0432 \u0442\u043e\u043c \u0447\u0438\u0441\u043b\u0435 \u0438 \u043f\u043e \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u043c \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u0430\u043c (buildah \u0438 \u043f\u0440\u043e\u0447\u0438\u0435). \u041f\u043e\u044d\u0442\u043e\u043c\u0443 \u043a \u0432\u044b\u0431\u043e\u0440\u0443 \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u0430 \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u044f \u0431\u0443\u0434\u0443 \u043f\u043e\u0434\u0445\u043e\u0434\u0438\u0442\u044c \u0442\u0430\u043a: \u0434\u043b\u044f \u043c\u0430\u043b\u044b\u0445 \u043a\u043e\u043c\u0430\u043d\u0434, \u043b\u0438\u0431\u043e \u043f\u0440\u0438 \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u043d\u043e\u043c \u0431\u044e\u0434\u0436\u0435\u0442\u0435 \u2014 Docker (\u0441 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u044b\u043c swarm mode), \u0434\u043b\u044f \u0440\u0430\u0437\u0440\u0430\u0431\u043e\u0442\u043a\u0438 \u0434\u043b\u044f \u0441\u0435\u0431\u044f \u043d\u0430 \u043b\u0438\u0447\u043d\u043e\u043c localhost \u2014 Podman \u0441\u043e\u0442\u043e\u0432\u0430\u0440\u0438\u0449\u0438, \u0430 \u0432\u0441\u0435\u043c \u043e\u0441\u0442\u0430\u043b\u044c\u043d\u044b\u043c \u2014 Kubernetes. <\/p>\n<p>  <\/p>\n<p>\u042f \u043d\u0435 \u0443\u0432\u0435\u0440\u0435\u043d, \u0447\u0442\u043e \u0441\u0438\u0442\u0443\u0430\u0446\u0438\u044f \u0441 Docker \u043d\u0435 \u043f\u043e\u043c\u0435\u043d\u044f\u0435\u0442\u0441\u044f \u0432 \u0431\u0443\u0434\u0443\u0449\u0435\u043c, \u0432\u0441\u0435-\u0442\u0430\u043a\u0438 \u043e\u043d\u0438 \u044f\u0432\u043b\u044f\u044e\u0442\u0441\u044f \u043f\u0438\u043e\u043d\u0435\u0440\u0430\u043c\u0438, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0448\u0430\u0433 \u0437\u0430 \u0448\u0430\u0433\u043e\u043c \u043f\u043e\u0442\u0438\u0445\u043e\u043d\u044c\u043a\u0443 \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u0438\u0437\u0438\u0440\u0443\u044e\u0442\u0441\u044f, \u043d\u043e \u0443 Podman \u043f\u0440\u0438 \u0432\u0441\u0435\u0445 \u0435\u0433\u043e \u043d\u0435\u0434\u043e\u0441\u0442\u0430\u0442\u043a\u0430\u0445 (\u0440\u0430\u0431\u043e\u0442\u0430 \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 Linux, \u043d\u0435\u0442\u0443 \u043a\u043b\u0430\u0441\u0442\u0435\u0440\u0438\u0437\u0430\u0446\u0438\u0438, \u0441\u0431\u043e\u0440\u043a\u0430 \u0438 \u043f\u0440\u043e\u0447\u0438\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u2014 \u0441\u0442\u043e\u0440\u043e\u043d\u043d\u0438\u043c\u0438 \u0440\u0435\u0448\u0435\u043d\u0438\u044f\u043c\u0438) \u0431\u0443\u0434\u0443\u0449\u0435\u0435 \u0431\u043e\u043b\u0435\u0435 \u044f\u0441\u043d\u043e\u0435, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u044f \u043f\u0440\u0438\u0433\u043b\u0430\u0448\u0430\u044e \u0432\u0441\u0435\u0445 \u0436\u0435\u043b\u0430\u044e\u0449\u0438\u0445 \u043e\u0431\u0441\u0443\u0434\u0438\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435 \u0432\u044b\u0432\u043e\u0434\u044b \u0432 \u043a\u043e\u043c\u043c\u0435\u043d\u0442\u0430\u0440\u0438\u044f\u0445.<\/p>\n<p>  <\/p>\n<p><strong>P.S.<\/strong> 3 \u0430\u0432\u0433\u0443\u0441\u0442\u0430 \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u00ab<a href=\"http:\/\/to.slurm.io\/WDgG2Q\">\u0412\u0438\u0434\u0435\u043e\u043a\u0443\u0440\u0441 \u043f\u043e Docker<\/a>\u00bb, \u0433\u0434\u0435 \u043c\u043e\u0436\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u0435\u0435 \u0443\u0437\u043d\u0430\u0442\u044c \u043e \u0435\u0433\u043e \u0440\u0430\u0431\u043e\u0442\u0435. \u041c\u044b \u0440\u0430\u0437\u0431\u0435\u0440\u0435\u043c \u0432\u0441\u0435 \u0435\u0433\u043e \u0438\u043d\u0441\u0442\u0440\u0443\u043c\u0435\u043d\u0442\u044b: \u043e\u0442 \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u0445 \u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0446\u0438\u0439 \u0434\u043e \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0441\u0435\u0442\u0438, \u043d\u044e\u0430\u043d\u0441\u043e\u0432 \u0440\u0430\u0431\u043e\u0442\u044b \u0441 \u0440\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u043c\u0438 \u041e\u0421 \u0438 \u044f\u0437\u044b\u043a\u0430\u043c\u0438 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f. \u0412\u044b \u043f\u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u0442\u0435\u0441\u044c \u0441 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0435\u0439 \u0438 \u043f\u043e\u0439\u043c\u0435\u0442\u0435, \u0433\u0434\u0435 \u0438 \u043a\u0430\u043a \u043b\u0443\u0447\u0448\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c Docker. \u0422\u0430\u043a\u0436\u0435 \u043f\u043e\u0434\u0435\u043b\u0438\u043c\u0441\u044f best practice \u043a\u0435\u0439\u0441\u0430\u043c\u0438.<\/p>\n<p>  <\/p>\n<p>\u0421\u0442\u043e\u0438\u043c\u043e\u0441\u0442\u044c \u043f\u0440\u0435\u0434\u0437\u0430\u043a\u0430\u0437\u0430 \u0434\u043e \u0440\u0435\u043b\u0438\u0437\u0430: 5000 \u0440. \u0421 \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043e\u0439 \u00ab\u0412\u0438\u0434\u0435\u043e\u043a\u0443\u0440\u0441\u0430 \u043f\u043e Docker\u00bb \u043c\u043e\u0436\u043d\u043e \u043e\u0437\u043d\u0430\u043a\u043e\u043c\u0438\u0442\u044c\u0441\u044f <a href=\"http:\/\/to.slurm.io\/WDgG2Q\">\u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435 \u043a\u0443\u0440\u0441\u0430<\/a>.<\/p>\n<\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/company\/southbridge\/blog\/512246\/\"> https:\/\/habr.com\/ru\/company\/southbridge\/blog\/512246\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html post__text_v1\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/company\/southbridge\/blog\/512246\/\">\n<p>TL;DR: \u043e\u0431\u0437\u043e\u0440\u043d\u0430\u044f \u0441\u0442\u0430\u0442\u044c\u044f-\u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u043e \u043f\u043e \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044e \u0441\u0440\u0435\u0434 \u0434\u043b\u044f \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0439 \u0432 \u043a\u043e\u043d\u0442\u0435\u0439\u043d\u0435\u0440\u0430\u0445. \u0411\u0443\u0434\u0443\u0442 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u044b \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 Docker \u0438 \u0434\u0440\u0443\u0433\u0438\u0445 \u0441\u0445\u043e\u0436\u0438\u0445 \u0441\u0438\u0441\u0442\u0435\u043c.<\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/gs\/kz\/iy\/gskziy9bonuhk4yq0cobemffymw.png\"><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-307772","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/307772","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=307772"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/307772\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=307772"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=307772"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=307772"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}