{"id":415826,"date":"2024-06-30T00:35:54","date_gmt":"2024-06-30T00:35:54","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=415826"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=415826","title":{"rendered":"<span>\u041f\u0440\u043e\u0441\u0442\u043e\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u0440\u0430\u0437\u0432\u0435\u0440\u043d\u0443\u0442\u044c \u0442\u0435\u043b\u0435\u0433\u0440\u0430\u043c\u043c \u0431\u043e\u0442\u0430 \u0441 Aiogram + Webhook \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433<\/span>"},"content":{"rendered":"<div><!--[--><!--]--><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p> \u0420\u0430\u0441\u0441\u043a\u0430\u0436\u0443 \u0441\u0430\u043c\u044b\u0439 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0438 \u0431\u0435\u0441\u043f\u043b\u0430\u0442\u043d\u044b\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u0440\u0430\u0437\u0432\u0435\u0440\u043d\u0443\u0442\u044c \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435 \u0442\u0435\u043b\u0435\u0433\u0440\u0430\u043c\u043c \u0431\u043e\u0442\u0430, \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u043e\u0433\u043e \u043d\u0430 aiogram \u0438 \u043f\u0435\u0440\u0435\u0432\u0435\u0441\u0442\u0438 \u043d\u0430 webhook.  \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0432\u0438\u0434\u0435\u043e \u0432\u0435\u0440\u0441\u0438\u044e, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u044f \u0432\u044b\u043b\u043e\u0436\u0438\u043b, <a href=\"https:\/\/youtu.be\/Gw-cVvsaOGE\" rel=\"noopener noreferrer nofollow\">\u043c\u043e\u0436\u043d\u043e \u043d\u0430 YouTube<\/a>.<\/p>\n<p> \u0411\u043e\u0442 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c 24\/7 \u043f\u043e\u0436\u0438\u0437\u043d\u0435\u043d\u043d\u043e.    <\/p>\n<p> \u0411\u0435\u0437 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f VPS, \u0432\u0435\u0431-\u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0430 django, flask, fastapi,.., pythonanywhere \u0438 heroku.  <\/p>\n<p>  <strong>\u041a\u0440\u0430\u0442\u043a\u043e\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0439:<\/strong>  <\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>1<\/em><\/strong>. \u0421\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u043f\u0440\u0438\u043c\u0435\u0440 \u043a \u0441\u0435\u0431\u0435, \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u044f \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>2<\/em><\/strong>. \u0427\u0435\u0440\u0435\u0437 FTP \u043f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u043d\u0430\u0448 \u0444\u0430\u0439\u043b \u0431\u043e\u0442\u0430 \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>3<\/em><\/strong>. \u0427\u0435\u0440\u0435\u0437 SSH \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 aiogram.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>4<\/em><\/strong>. \u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430 \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>5<\/em><\/strong>. \u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0432\u0435\u0431-\u0441\u0430\u0439\u0442 \u043d\u0430 \u043f\u0435\u0440\u0435\u0430\u0434\u0440\u0435\u0441\u0430\u0446\u0438\u044e \u0432\u0441\u0435\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043d\u0430 \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>6<\/em><\/strong>. \u041e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0431\u043e\u0442\u0430 \u0441 \u0443\u0447\u0435\u0442\u043e\u043c \u043d\u0430\u0448\u0438\u0445 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>7<\/em><\/strong>. \u041f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u043a \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0431\u043e\u0442\u0430, \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0431\u043e\u0442\u0430. \u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440 \u043b\u043e\u0433\u043e\u0432.<\/p>\n<p>_________________________________________________________<\/p>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 1<\/em><\/strong>. <strong><em>\u0421\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u043f\u0440\u0438\u043c\u0435\u0440 \u043a \u0441\u0435\u0431\u0435, \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u044f \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/em><\/strong><\/p>\n<p> \u0418\u0434\u0435\u043c \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0439 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 Aiogram:<\/p>\n<p><a href=\"https:\/\/docs.aiogram.dev\/en\/v2.25.1\/examples\/webhook_example.html\" rel=\"noopener noreferrer nofollow\">https:\/\/docs.aiogram.dev\/en\/v2.25.1\/examples\/webhook_example.html<\/a><\/p>\n<p>\u041a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 <em>webhook_example.py <\/em>\u043a \u0441\u0435\u0431\u0435 \u0432 \u0444\u0430\u0439\u043b webhook.py \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/abd\/202\/de2\/abd202de23e4b5ba5c929f7fef964069.png\" alt=\"\u0440\u0438\u0441.. 1\" title=\"\u0440\u0438\u0441.. 1\" width=\"1673\" height=\"898\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/abd\/202\/de2\/abd202de23e4b5ba5c929f7fef964069.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441.. 1<\/figcaption><\/div>\n<\/figure>\n<p> \u0420\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u0443\u0435\u043c\u0441\u044f \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435: <a href=\"https:\/\/www.alwaysdata.com\/\" rel=\"noopener noreferrer nofollow\">https:\/\/www.alwaysdata.com\/<\/a> \u043d\u0430 \u0431\u0435\u0441\u043f\u043b\u0430\u0442\u043d\u043e\u043c \u0442\u0430\u0440\u0438\u0444\u0435 \u00abFree for life\u00bb.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/f95\/937\/0fb\/f959370fbedb0063cf3cc87f36cafb01.png\" alt=\"\u0440\u0438\u0441. 2\" title=\"\u0440\u0438\u0441. 2\" width=\"1364\" height=\"876\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f95\/937\/0fb\/f959370fbedb0063cf3cc87f36cafb01.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 2<\/figcaption><\/div>\n<\/figure>\n<p> \u041f\u043e\u0441\u043b\u0435 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438, \u0432 \u043f\u0430\u043d\u0435\u043b\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f, \u0436\u043c\u0435\u043c \u0441\u043b\u0435\u0432\u0430 \u0432 \u0440\u0430\u0437\u0434\u0435\u043b\u0435 \u00abWEB\u00bb \u2192 \u00abSites\u00bb. \u0421\u043f\u0440\u0430\u0432\u0430 \u0443\u0432\u0438\u0434\u0438\u043c \u043d\u0430\u0448 \u0441\u0430\u0439\u0442 \u0441 \u0434\u043e\u043c\u0435\u043d\u043d\u044b\u043c \u0438\u043c\u0435\u043d\u0435\u043c 3-\u0435\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f.<\/p>\n<p>  \u0423 \u043c\u0435\u043d\u044f \u00abrupyt.alwaysdata.net\u00bb, \u0433\u0434\u0435 rupyt \u2014 \u0438\u043c\u044f \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u044f \u0434\u0430\u0432\u0430\u043b \u043f\u0440\u0438 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438, \u0443 \u0412\u0430\u0441 \u0431\u0443\u0434\u0435\u0442 \u0441\u0432\u043e\u0451.  <\/p>\n<p> <em><u>\u043f\u0440\u0438\u043c. \u0412\u0435\u0437\u0434\u0435 \u0433\u0434\u0435 \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043e \u00abrupyt\u00bb, \u043c\u0435\u043d\u044f\u0435\u043c \u043d\u0430 \u0441\u0432\u043e\u0451 \u0438\u043c\u044f.<\/u><\/em><\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/ae7\/2a1\/da3\/ae72a1da31048086d021e8f4e9cf5047.png\" alt=\"\u0440\u0438\u0441. 3\" title=\"\u0440\u0438\u0441. 3\" width=\"1972\" height=\"644\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/ae7\/2a1\/da3\/ae72a1da31048086d021e8f4e9cf5047.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 3<\/figcaption><\/div>\n<\/figure>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 2<\/em><\/strong>.  <strong><em>\u0427\u0435\u0440\u0435\u0437 FTP \u043f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u043d\u0430\u0448 \u0444\u0430\u0439\u043b \u0431\u043e\u0442\u0430 \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/em><\/strong><\/p>\n<p>\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c\u0441\u044f \u043f\u043e FTP \u043a \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0443 \u043b\u044e\u0431\u044b\u043c \u0432\u0430\u0448\u0438\u043c FTP-\u043a\u043b\u0438\u0435\u043d\u0442\u043e\u043c.<\/p>\n<p> \u0421\u0442\u0440\u043e\u043a\u0430 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f <a href=\"ftp:\/\/rupyt@ftp-rupyt.alwaysdata.net\/\" rel=\"noopener noreferrer nofollow\">ftp:\/\/rupyt@ftp-rupyt.alwaysdata.net<\/a> \u0434\u043b\u044f \u043c\u0435\u043d\u044f.  <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/052\/ee1\/b9a\/052ee1b9a9e1e0c459364014100c4690.png\" alt=\"\u0440\u0438\u0441. 4\" title=\"\u0440\u0438\u0441. 4\" width=\"939\" height=\"477\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/052\/ee1\/b9a\/052ee1b9a9e1e0c459364014100c4690.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 4<\/figcaption><\/div>\n<\/figure>\n<p>\u0415\u0449\u0435 \u0440\u0430\u0437 \u043d\u0430\u043f\u043e\u043c\u043d\u044e, \u0432\u043c\u0435\u0441\u0442\u043e <s>rupyt<\/s>, \u0441\u0442\u0430\u0432\u0438\u043c \u0441\u0432\u043e\u0435 \u0438\u043c\u044f, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0432\u044b \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u043b\u0438 \u043f\u0440\u0438 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438.  <\/p>\n<p>\u0410\u0434\u0440\u0435\u0441 \u0445\u043e\u0441\u0442\u0430 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c, \u0435\u0441\u043b\u0438 \u043d\u0430\u0436\u0430\u0442\u044c \u0432 \u043f\u0430\u043d\u0435\u043b\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u043e\u043c, \u0441\u043b\u0435\u0432\u0430 \u00abRemote access\u00bb \u2192 \u00abFTP\u00bb:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/f4e\/cb2\/b41\/f4ecb2b417ea36737bafdb2389299bf5.png\" alt=\"\u0440\u0438\u0441. 5\" title=\"\u0440\u0438\u0441. 5\" width=\"1088\" height=\"768\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/f4e\/cb2\/b41\/f4ecb2b417ea36737bafdb2389299bf5.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 5<\/figcaption><\/div>\n<\/figure>\n<p> \u041f\u043e\u0441\u043b\u0435 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043f\u0430\u0434\u0430\u0435\u043c \u0432 \u0434\u043e\u043c\u0430\u0448\u043d\u044e\u044e \u043f\u0430\u043f\u043a\u0443.<\/p>\n<p> \u0412 \u043d\u0435\u0439 \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u043f\u0430\u043f\u043a\u0430 \u00abwww\u00bb \u0434\u043b\u044f \u0432\u0435\u0431-\u0441\u0430\u0439\u0442\u043e\u0432.<\/p>\n<p> \u0417\u0430\u0445\u043e\u0434\u0438\u043c \u0432 \u043d\u0435\u0435, \u0441\u043e\u0437\u0434\u0430\u0451\u043c \u043f\u0430\u043f\u043a\u0443 \u00abbot\u00bb<\/p>\n<p> \u041a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u043d\u0430\u0448 \u043f\u0440\u0438\u043c\u0435\u0440 webhook.py \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433 \u0432 \u044d\u0442\u0443 \u043f\u0430\u043f\u043a\u0443:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/648\/dc3\/d0c\/648dc3d0ca7f0cb7ec1b40a0fd7f7880.png\" alt=\"\u0440\u0438\u0441. 6\" title=\"\u0440\u0438\u0441. 6\" width=\"1539\" height=\"527\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/648\/dc3\/d0c\/648dc3d0ca7f0cb7ec1b40a0fd7f7880.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 6<\/figcaption><\/div>\n<\/figure>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 3<\/em><\/strong>.  <strong><em>\u0427\u0435\u0440\u0435\u0437 SSH \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 aiogram.<\/em><\/strong><\/p>\n<p> \u0414\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043f\u043e SSH, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u0434\u043b\u044f \u043d\u0435\u0433\u043e.<\/p>\n<p> \u0418\u0434\u0435\u043c \u0432 \u043f\u0430\u043d\u0435\u043b\u044c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u00abRemote access\u00bb \u2192 \u00abSSH\u00bb, \u0436\u043c\u0435\u043c \u043d\u0430 \u00ab\u0448\u0435\u0441\u0442\u0435\u0440\u0435\u043d\u043a\u0443\u00bb \u0441\u043f\u0440\u0430\u0432\u0430, \u0434\u043b\u044f \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/3ff\/6a9\/879\/3ff6a987952eb60c961a792b3a5fe1c4.png\" alt=\"\u0440\u0438\u0441. 7\" title=\"\u0440\u0438\u0441. 7\" width=\"1010\" height=\"805\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/3ff\/6a9\/879\/3ff6a987952eb60c961a792b3a5fe1c4.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 7<\/figcaption><\/div>\n<\/figure>\n<p> \u0421\u0442\u0430\u0432\u0438\u043c \u0433\u0430\u043b\u043a\u0443 \u043d\u0430 \u00abEnable password login\u00bb \u0434\u043b\u044f \u0432\u0445\u043e\u0434\u0430 \u043f\u043e \u043f\u0430\u0440\u043e\u043b\u044e. \u0421\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c\u0441\u044f, \u0436\u043c\u0435\u043c \u00abSubmit\u00bb:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/73e\/e1a\/9d7\/73ee1a9d78f8d212a4f47cb3fb42a1f1.png\" alt=\"\u0440\u0438\u0441. 8\" title=\"\u0440\u0438\u0441. 8\" width=\"1017\" height=\"973\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/73e\/e1a\/9d7\/73ee1a9d78f8d212a4f47cb3fb42a1f1.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 8<\/figcaption><\/div>\n<\/figure>\n<p> \u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f \u043c\u043e\u0436\u043d\u043e \u0434\u0432\u0443\u043c\u044f \u0441\u043f\u043e\u0441\u043e\u0431\u0430\u043c\u0438.<\/p>\n<p> <u>\u041f\u0435\u0440\u0432\u044b\u0439 \u0441\u043f\u043e\u0441\u043e\u0431<\/u> \u0447\u0435\u0440\u0435\u0437 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b \u0432\u0432\u0435\u0434\u044f:  \u00abssh <a href=\"mailto:rupyt@ssh-rupyt.alwaysdata.net\" rel=\"noopener noreferrer nofollow\">rupyt@ssh-rupyt.alwaysdata.net<\/a>\u00bb.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/671\/0dd\/a18\/6710dda185609e3a4c37ff73aaa666d6.png\" alt=\"\u0440\u0438\u0441. 9\" title=\"\u0440\u0438\u0441. 9\" width=\"1179\" height=\"573\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/671\/0dd\/a18\/6710dda185609e3a4c37ff73aaa666d6.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 9<\/figcaption><\/div>\n<\/figure>\n<p> <u>\u0412\u0442\u043e\u0440\u043e\u0439 \u0441\u043f\u043e\u0441\u043e\u0431<\/u> \u043f\u0440\u044f\u043c\u043e \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435, \u043d\u0430\u0436\u0430\u0432 \u043d\u0430 \u00ab(also\u00a0<a href=\"https:\/\/ssh-rupyt.alwaysdata.net\/\" rel=\"noopener noreferrer nofollow\">Web<\/a>\u00a0accessible)\u00bb.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/e1b\/e9a\/1ee\/e1be9a1eefb15dd6c147b4592e009954.png\" alt=\"\u0440\u0438\u0441. 10\" title=\"\u0440\u0438\u0441. 10\" width=\"1012\" height=\"835\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e1b\/e9a\/1ee\/e1be9a1eefb15dd6c147b4592e009954.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 10<\/figcaption><\/div>\n<\/figure>\n<p> \u0412\u0432\u043e\u0434\u0438\u043c \u043b\u043e\u0433\u0438\u043d (\u0443 \u043c\u0435\u043d\u044f rupyt) \u0438 \u043f\u0430\u0440\u043e\u043b\u044c.<\/p>\n<p> \u0417\u0434\u0435\u0441\u044c \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0434\u043e\u043c\u0430\u0448\u043d\u0438\u0439 \u043a\u0430\u0442\u0430\u043b\u043e\u0433 (\u043a\u043e\u043c\u0430\u043d\u0434\u0430 pwd), \u043f\u0435\u0440\u0435\u0439\u0442\u0438 \u0432 \u043a\u0430\u0442\u0430\u043b\u043e\u0433 \u00abwww\/bot\u00bb \u0438 \u0444\u0430\u0439\u043b \u00abwebhook.py\u00bb, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043b\u0438  \u043f\u043e FTP.<\/p>\n<p> \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c \u00abAiogram\u00bb, \u043d\u0430\u0431\u0440\u0430\u0432 \u00ab<strong>pip install aiogram<\/strong>\u00bb.<\/p>\n<p> \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u043c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 \u00abpip freeze\u00bb.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/435\/f9f\/5d5\/435f9f5d56b9e5d36184d5bf1cec11cf.png\" alt=\"\u0440\u0438\u0441. 11\" title=\"\u0440\u0438\u0441. 11\" width=\"1004\" height=\"799\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/435\/f9f\/5d5\/435f9f5d56b9e5d36184d5bf1cec11cf.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 11<\/figcaption><\/div>\n<\/figure>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 4<\/em><\/strong>.  <strong><em>\u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430 \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/em><\/strong><\/p>\n<p> \u0418\u0434\u0435\u043c \u0432 \u043f\u0430\u043d\u0435\u043b\u044c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u00abAdvanced\u00bb \u2192 \u00abServices\u00bb, \u0436\u043c\u0435\u043c \u043d\u0430 \u00ab+Add a service\u00bb:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/853\/81f\/8c6\/85381f8c60a57b86110bb43b8da4d311.png\" alt=\"\u0440\u0438\u0441. 12\" title=\"\u0440\u0438\u0441. 12\" width=\"957\" height=\"916\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/853\/81f\/8c6\/85381f8c60a57b86110bb43b8da4d311.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 12<\/figcaption><\/div>\n<\/figure>\n<p> \u041f\u043e\u043f\u0430\u0434\u0430\u0435\u043c \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438. <\/p>\n<p> 1. SSH user \u2014 \u043d\u0435 \u0442\u0440\u043e\u0433\u0430\u0435\u043c. <\/p>\n<p> 2. \u0412 \u00abCommand\u00bb \u043f\u0438\u0448\u0435\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0444\u0430\u0439\u043b\u0430 \u0431\u043e\u0442\u0430 \u043d\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u00abwebhook.py\u00bb:  <\/p>\n<p> \u00abpython \/home\/rupyt\/www\/bot\/webhook.py\u00bb<\/p>\n<p> 3. \u0412 \u00abEnvironment\u00bb \u0437\u0430\u043f\u0438\u0448\u0435\u043c \u0442\u043e\u043a\u0435\u043d \u0442\u0435\u043b\u0435\u0433\u0440\u0430\u043c \u0431\u043e\u0442\u0430, \u0431\u0435\u0437 \u043a\u0430\u0432\u044b\u0447\u0435\u043a TG_TOKEN=62671\u2026.<\/p>\n<p> 4. \u0412 \u00abWorking directory\u00bb \u0443\u043a\u0430\u0436\u0435\u043c \u043f\u0443\u0442\u044c \u0433\u0434\u0435 \u043b\u0435\u0436\u0438\u0442 \u043d\u0430\u0448 \u0444\u0430\u0439\u043b \u00abwebhook.py\u00bb:<\/p>\n<p> \u00ab\/home\/rupyt\/www\/bot\/\u00bb   <\/p>\n<p> 5. \u0412 \u00abAnnotation\u00bb \u0434\u0430\u0434\u0438\u043c \u043b\u044e\u0431\u043e\u0435 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u0430, \u044f \u0434\u0430\u043b \u00abAiogram Webhook service\u00bb.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/8ae\/ae9\/d23\/8aeae9d23df5f58dc862975274bed9d8.png\" alt=\"\u0440\u0438\u0441. 13\" title=\"\u0440\u0438\u0441. 13\" width=\"973\" height=\"1019\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8ae\/ae9\/d23\/8aeae9d23df5f58dc862975274bed9d8.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 13<\/figcaption><\/div>\n<\/figure>\n<p> 6. \u0421\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c\u0441\u044f, \u0436\u043c\u0435\u043c \u00abSubmit\u00bb <\/p>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 5<\/em><\/strong>. <strong><em>\u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0430\u0439\u0442 \u043d\u0430 \u043f\u0435\u0440\u0435\u0430\u0434\u0440\u0435\u0441\u0430\u0446\u0438\u044e \u0432\u0441\u0435\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043d\u0430 \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430.<\/em><\/strong><\/p>\n<p> \u0418\u0434\u0435\u043c \u0432 \u043f\u0430\u043d\u0435\u043b\u044c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u00abWeb\u00bb \u2192 \u00abSites\u00bb, \u0436\u043c\u0435\u043c \u043d\u0430 \u0448\u0435\u0441\u0442\u0435\u0440\u0435\u043d\u043a\u0443 \u00abEdit\u00bb \u0434\u043b\u044f \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043d\u0430\u0448\u0435\u0433\u043e \u0441\u0430\u0439\u0442\u0430:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/07b\/f4f\/831\/07bf4f831d655ddc7dcf46d4d42a1048.png\" alt=\"\u0440\u0438\u0441. 14\" title=\"\u0440\u0438\u0441. 14\" width=\"968\" height=\"557\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/07b\/f4f\/831\/07bf4f831d655ddc7dcf46d4d42a1048.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 14<\/figcaption><\/div>\n<\/figure>\n<p> 1. \u041f\u043e\u043f\u0430\u0434\u0430\u0435\u043c \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u00ab<a href=\"https:\/\/admin.alwaysdata.com\/site\/770585\/#configuration\" rel=\"noopener noreferrer nofollow\">CONFIGURATION<\/a>\u00bb. <\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/de5\/10a\/17d\/de510a17d12c3de7f99ce19c82102e82.png\" alt=\"\u0440\u0438\u0441. 16\" title=\"\u0440\u0438\u0441. 16\" width=\"1061\" height=\"1275\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/de5\/10a\/17d\/de510a17d12c3de7f99ce19c82102e82.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 16<\/figcaption><\/div>\n<\/figure>\n<p> 2. \u00abAddresses\u00bb &#8212; \u043d\u0435 \u0442\u0440\u043e\u0433\u0430\u0435\u043c, \u044d\u0442\u043e \u0438 \u0435\u0441\u0442\u044c \u0412\u0430\u0448 \u0430\u0434\u0440\u0435\u0441 \u0432\u0435\u0431-\u0441\u0430\u0439\u0442\u0430. \u0423 \u043c\u0435\u043d\u044f \u00abrupyt.alwaysdata.net\u00bb.<\/p>\n<p> 3. \u0412 \u00abConfiguration\u00bb \u00abType*\u00bb \u0432\u044b\u0431\u0438\u0440\u0430\u0435\u043c \u00abRedirect\u00bb. <\/p>\n<p> 4. \u0412 \u00abDestination URL*\u00bb \u043f\u0440\u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u043c \u0430\u0434\u0440\u0435\u0441 \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043d\u0430\u0448 \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430.<\/p>\n<p> \u0423 \u043c\u0435\u043d\u044f \u00ab<a href=\"http:\/\/services-rupyt.alwaysdata.net:8350\/\" rel=\"noopener noreferrer nofollow\">http:\/\/services-rupyt.alwaysdata.net:8350<\/a>\u00bb.<\/p>\n<p>  \u0413\u0434\u0435 \u00abservices\u00bb &#8212; \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e  \u044d\u0442\u043e \u0441\u0435\u0440\u0432\u0438\u0441, \u00abrupyt\u00bb &#8212; \u043c\u043e\u0435 \u0438\u043c\u044f, \u00ab8350\u00bb &#8212; \u043f\u043e\u0440\u0442 \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u0438\u0437 \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d\u0430 8300-8499, \u043a\u0430\u043a \u0441\u043a\u0430\u0437\u0430\u043d\u043e \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438.   <\/p>\n<p> \u0424\u043e\u0440\u043c\u0430\u0442 \u0437\u0430\u043f\u0438\u0441\u0438 \u043c\u043e\u0436\u043d\u043e \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 <a href=\"https:\/\/help.alwaysdata.com\/en\/services\/\" rel=\"noopener noreferrer nofollow\">https:\/\/help.alwaysdata.com\/en\/services\/<\/a>:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/e72\/4b6\/04e\/e724b604e9349a416d189152b2a7c0cf.png\" alt=\"\u0440\u0438\u0441. 15\" title=\"\u0440\u0438\u0441. 15\" width=\"1057\" height=\"466\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/e72\/4b6\/04e\/e724b604e9349a416d189152b2a7c0cf.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 15<\/figcaption><\/div>\n<\/figure>\n<p> 5. \u0412 \u00abForwarding type*\u00bb \u0432\u044b\u0431\u0438\u0440\u0430\u0435\u043c \u0442\u0438\u043f: \u00abtransparent(reverse proxy)\u00bb.<\/p>\n<p> 6. \u0421\u0442\u0430\u0432\u0438\u043c \u0433\u0430\u043b\u043e\u0447\u043a\u0443 \u043d\u0430 \u00abAppend request path\u00bb \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e \u0431\u044b \u043f\u0443\u0442\u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u043b\u0438\u0441\u044c \u0432 \u0430\u0434\u0440\u0435\u0441 \u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f, \u0442\u043e \u0435\u0441\u0442\u044c \u0432 \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430.<\/p>\n<p> 7. \u0412 \u00abAnnotation\u00bb \u0434\u0430\u0434\u0438\u043c \u043b\u044e\u0431\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u044f, \u044f \u0434\u0430\u043b \u00abRedirect For Bot\u00bb.<\/p>\n<p> 8. \u0418\u0434\u0435\u043c \u0432\u043e \u0432\u043a\u043b\u0430\u0434\u043a\u0443 \u00abSSL\u00bb \u0438 \u0441\u0442\u0430\u0432\u0438\u043c \u0433\u0430\u043b\u043e\u0447\u043a\u0443 \u0434\u043b\u044f HTTPS  \u00abForce HTTPS usage\u00bb:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/7b3\/c5c\/fd9\/7b3c5cfd9ce322f3ad4201805d3e563b.png\" alt=\"\u0440\u0438\u0441. 17\" title=\"\u0440\u0438\u0441. 17\" width=\"1044\" height=\"379\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/7b3\/c5c\/fd9\/7b3c5cfd9ce322f3ad4201805d3e563b.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 17<\/figcaption><\/div>\n<\/figure>\n<p> \u0421\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c\u0441\u044f, \u0436\u043c\u0435\u043c \u00abSubmit\u00bb <\/p>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 6<\/em><\/strong>. <strong>\u041e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0431\u043e\u0442\u0430 \u0441 \u0443\u0447\u0435\u0442\u043e\u043c \u043d\u0430\u0448\u0438\u0445 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a.<\/strong><\/p>\n<p> \u041d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435 \u0447\u0435\u0440\u0435\u0437 FTP, \u043e\u0442\u043a\u0440\u043e\u0435\u043c \u043d\u0430\u0448 \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0444\u0430\u0439\u043b \u00abwebhook.py\u00bb \u0438 \u043e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u0443\u0435\u043c.<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/8cf\/858\/dc5\/8cf858dc5266a4c9bc8ffcfb1e34c92f.png\" alt=\"\u0440\u0438\u0441. 18\" title=\"\u0440\u0438\u0441. 18\" width=\"1068\" height=\"818\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/8cf\/858\/dc5\/8cf858dc5266a4c9bc8ffcfb1e34c92f.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 18<\/figcaption><\/div>\n<\/figure>\n<p> 1. \u0418\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u0443\u0435\u043c \u043c\u043e\u0434\u0443\u043b\u044c \u00abOS\u00bb \u0434\u043b\u044f \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0442\u043e\u043a\u0435\u043d\u0430 \u0447\u0435\u0440\u0435\u0437 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f.<\/p>\n<p> 2. \u0423\u043a\u0430\u0436\u0435\u043c \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0443 \u0442\u043e\u043a\u0435\u043d\u0430 \u0447\u0435\u0440\u0435\u0437 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u00abAPI_TOKEN = os.environ[&#8216;TG_TOKEN&#8217;]\u00bb, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u043b\u0438 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 , \u0441\u043c\u043e\u0442\u0440\u0438 \u0420\u0438\u0441.13.<\/p>\n<p> 3. \u0414\u043b\u044f WEBHOOK_HOST  \u0443\u043a\u0430\u0436\u0435\u043c \u043d\u0430\u0448 \u0430\u0434\u0440\u0435\u0441 \u0432\u0435\u0431\u0441\u0430\u0439\u0442\u0430:<\/p>\n<p>  \u00ab WEBHOOK_HOST = &#8216;<a href=\"https:\/\/rupyt.alwaysdata.net\/\" rel=\"noopener noreferrer nofollow\">https:\/\/rupyt.alwaysdata.net\/<\/a>&#8216; \u00bb <\/p>\n<p> 4. \u041f\u0443\u0442\u044c \u044f \u0443\u043a\u0430\u0437\u0430\u043b \u00abWEBHOOK_PATH = &#8216;\/bot\/&#8217;\u00bb, \u043c\u043e\u0436\u043d\u043e \u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043f\u0443\u0441\u0442\u044b\u043c \u0432 \u043a\u0430\u0432\u044b\u0447\u043a\u0430\u0445 &#187;.<\/p>\n<p> 5. WEBAPP_HOST = &#8216;::&#8217; , \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c \u0434\u0432\u0430 \u0434\u0432\u043e\u0435\u0442\u043e\u0447\u0438\u044f, \u043a\u0430\u043a \u0441\u043a\u0430\u0437\u0430\u043d\u043e \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 (\u0421\u043c\u043e\u0442\u0440\u0438 \u0420\u0438\u0441. 15.), \u0447\u0442\u043e \u0441\u0435\u0440\u0432\u0438\u0441 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0437\u0430\u043f\u0443\u0449\u0435\u043d, \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 IP \u0432\u0435\u0440\u0441\u0438\u0438 6.  <\/p>\n<p> 6. WEBAPP_PORT = 8350 , \u0432\u044b\u0431\u0440\u0430\u043b\u0438 \u0438\u0437 \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d\u0430 8300-8499, \u0443\u043a\u0430\u0437\u0430\u043b\u0438 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 \u00abSites\u00bb \u0441\u043c\u043e\u0442\u0440\u0438 \u0420\u0438\u0441. 16.<\/p>\n<p> \u0421\u043e\u0445\u0440\u0430\u043d\u0438\u043c \u043d\u0430\u0448 \u0444\u0430\u0439\u043b.<\/p>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 7<\/em><\/strong>. <strong><em>\u041f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u043a \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0431\u043e\u0442\u0430, \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0431\u043e\u0442\u0430. \u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440 \u043b\u043e\u0433\u043e\u0432.<\/em><\/strong><\/p>\n<p> \u0418\u0434\u0435\u043c \u0432 \u043f\u0430\u043d\u0435\u043b\u044c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u00abAdvanced\u00bb \u2192 \u00abServices\u00bb, \u0436\u043c\u0435\u043c \u043d\u0430 \u00abRestart\u00bb:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/a35\/788\/639\/a357886391243b8b4342cd7d7c016366.png\" alt=\"\u0440\u0438\u0441. 19\" title=\"\u0440\u0438\u0441. 19\" width=\"1058\" height=\"628\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a35\/788\/639\/a357886391243b8b4342cd7d7c016366.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 19<\/figcaption><\/div>\n<\/figure>\n<p> \u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u0442\u0435\u043b\u0435\u0433\u0440\u0430\u043c\u043c \u043a\u043b\u0438\u0435\u043d\u0442\u0430, \u0438 \u0432\u0432\u0435\u0434\u0435\u043c \u0447\u0442\u043e-\u043d\u0438\u0431\u0443\u0434\u044c. \u0412\u0438\u0434\u0438\u043c \u0447\u0442\u043e \u0431\u043e\u0442 \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442 \u00ab\u044d\u0445\u043e\u043c\u00bb. \u0423\u0440\u0430!<\/p>\n<p> \u041c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u043b\u043e\u0433\u0438 \u0434\u043b\u044f \u0441\u0430\u0439\u0442\u0430 \u0438\u043b\u0438 \u0441\u0435\u0440\u0432\u0438\u0441\u0430.  <\/p>\n<p> \u0414\u043b\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0438\u0434\u0435\u043c  \u0432 \u043f\u0430\u043d\u0435\u043b\u044c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u00abAdvanced\u00bb \u2192 \u00abServices\u00bb, \u0436\u043c\u0435\u043c \u043d\u0430 \u00abLogs\u00bb:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/4f0\/3c8\/dc0\/4f03c8dc0a522883bfcf69c017dc13e4.png\" alt=\"\u0440\u0438\u0441. 20\" title=\"\u0440\u0438\u0441. 20\" width=\"1602\" height=\"784\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/4f0\/3c8\/dc0\/4f03c8dc0a522883bfcf69c017dc13e4.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 20<\/figcaption><\/div>\n<\/figure>\n<p> \u0412 \u043b\u043e\u0433\u0430\u0445 \u0432\u0438\u0434\u0438\u043c:<\/p>\n<p> &#8212; \u0437\u0430\u043f\u0443\u0441\u043a \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u043d\u0430 IPv6 \u00ab::\u00bb \u0438 \u043f\u043e\u0440\u0442\u0443 8350<\/p>\n<p> &#8212; \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u0437\u0430\u043f\u0443\u0441\u043a\u0430, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0443\u043a\u0430\u0437\u0430\u043b\u0438 \u0434\u043b\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u0430.<\/p>\n<p> &#8212; \u0438\u043c\u044f \u0431\u043e\u0442\u0430 \u0438 \u0443\u0434\u0430\u0447\u043d\u044b\u0439 \u0437\u0430\u043f\u0443\u0441\u043a \u0435\u0433\u043e.<\/p>\n<p> &#8212; POST \u0437\u0430\u043f\u0440\u043e\u0441 \u043f\u043e path \u00ab\/bot\/\u00bb, c \u0443\u0434\u0430\u0447\u043d\u044b\u043c status_code = 200.<\/p>\n<p> <strong>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0437\u0430\u043a\u043e\u043d\u0447\u0435\u043d\u0430 !!! <\/strong> <\/p>\n<p> \u0414\u043b\u044f \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0430 \u0441\u0432\u043e\u0435\u0433\u043e \u0431\u043e\u0442\u0430 \u0441 polling-\u043e\u043c \u043d\u0430 \u0432\u0435\u0431\u0445\u0443\u043a, \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0445\u0435\u043d\u0434\u043b\u0435\u0440\u044b \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0432 \u043d\u0430\u0448 \u0444\u0430\u0439\u043b webhook.py \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435:<\/p>\n<figure class=\"full-width\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/habrastorage.org\/r\/w1560\/getpro\/habr\/upload_files\/a2b\/f45\/955\/a2bf459555478b5a77b1bf8ecc4345a5.png\" alt=\"\u0440\u0438\u0441. 21\" title=\"\u0440\u0438\u0441. 21\" width=\"1537\" height=\"907\" data-src=\"https:\/\/habrastorage.org\/getpro\/habr\/upload_files\/a2b\/f45\/955\/a2bf459555478b5a77b1bf8ecc4345a5.png\"\/><\/p>\n<div><figcaption>\u0440\u0438\u0441. 21<\/figcaption><\/div>\n<\/figure>\n<p> <em>\u041d\u0430\u0434\u0435\u044e\u0441\u044c \u043a\u043e\u043c\u0443-\u0442\u043e \u043f\u043e\u043c\u043e\u0436\u0435\u0442. \u0412\u0441\u0435\u043c \u0443\u0434\u0430\u0447\u0438! )<\/em><\/p>\n<\/p>\n<\/div>\n<\/div>\n<\/div>\n<p><!----><!----><\/div>\n<p><!----><!----><br \/> \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\/articles\/730310\/\"> https:\/\/habr.com\/ru\/articles\/730310\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div><!--[--><!--]--><\/div>\n<div id=\"post-content-body\">\n<div>\n<div class=\"article-formatted-body article-formatted-body article-formatted-body_version-2\">\n<div xmlns=\"http:\/\/www.w3.org\/1999\/xhtml\">\n<p> \u0420\u0430\u0441\u0441\u043a\u0430\u0436\u0443 \u0441\u0430\u043c\u044b\u0439 \u043f\u0440\u043e\u0441\u0442\u043e\u0439 \u0438 \u0431\u0435\u0441\u043f\u043b\u0430\u0442\u043d\u044b\u0439 \u0441\u043f\u043e\u0441\u043e\u0431 \u0440\u0430\u0437\u0432\u0435\u0440\u043d\u0443\u0442\u044c \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435 \u0442\u0435\u043b\u0435\u0433\u0440\u0430\u043c\u043c \u0431\u043e\u0442\u0430, \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043d\u043e\u0433\u043e \u043d\u0430 aiogram \u0438 \u043f\u0435\u0440\u0435\u0432\u0435\u0441\u0442\u0438 \u043d\u0430 webhook.  \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0432\u0438\u0434\u0435\u043e \u0432\u0435\u0440\u0441\u0438\u044e, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u044f \u0432\u044b\u043b\u043e\u0436\u0438\u043b, <a href=\"https:\/\/youtu.be\/Gw-cVvsaOGE\" rel=\"noopener noreferrer nofollow\">\u043c\u043e\u0436\u043d\u043e \u043d\u0430 YouTube<\/a>.<\/p>\n<p> \u0411\u043e\u0442 \u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c 24\/7 \u043f\u043e\u0436\u0438\u0437\u043d\u0435\u043d\u043d\u043e.    <\/p>\n<p> \u0411\u0435\u0437 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f VPS, \u0432\u0435\u0431-\u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0430 django, flask, fastapi,.., pythonanywhere \u0438 heroku.  <\/p>\n<p>  <strong>\u041a\u0440\u0430\u0442\u043a\u043e\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0430\u043d\u0438\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u0439:<\/strong>  <\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>1<\/em><\/strong>. \u0421\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u043f\u0440\u0438\u043c\u0435\u0440 \u043a \u0441\u0435\u0431\u0435, \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u044f \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>2<\/em><\/strong>. \u0427\u0435\u0440\u0435\u0437 FTP \u043f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u043d\u0430\u0448 \u0444\u0430\u0439\u043b \u0431\u043e\u0442\u0430 \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>3<\/em><\/strong>. \u0427\u0435\u0440\u0435\u0437 SSH \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 aiogram.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>4<\/em><\/strong>. \u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430 \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>5<\/em><\/strong>. \u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0432\u0435\u0431-\u0441\u0430\u0439\u0442 \u043d\u0430 \u043f\u0435\u0440\u0435\u0430\u0434\u0440\u0435\u0441\u0430\u0446\u0438\u044e \u0432\u0441\u0435\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043d\u0430 \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>6<\/em><\/strong>. \u041e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0431\u043e\u0442\u0430 \u0441 \u0443\u0447\u0435\u0442\u043e\u043c \u043d\u0430\u0448\u0438\u0445 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a.<\/p>\n<p><strong><em>\u041f\u0443\u043d\u043a\u0442<\/em><\/strong> <strong><em>7<\/em><\/strong>. \u041f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u043a \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0431\u043e\u0442\u0430, \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0431\u043e\u0442\u0430. \u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440 \u043b\u043e\u0433\u043e\u0432.<\/p>\n<p>_________________________________________________________<\/p>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 1<\/em><\/strong>. <strong><em>\u0421\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u043f\u0440\u0438\u043c\u0435\u0440 \u043a \u0441\u0435\u0431\u0435, \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u044f \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/em><\/strong><\/p>\n<p> \u0418\u0434\u0435\u043c \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443 \u043e\u0444\u0438\u0446\u0438\u0430\u043b\u044c\u043d\u043e\u0439 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 Aiogram:<\/p>\n<p><a href=\"https:\/\/docs.aiogram.dev\/en\/v2.25.1\/examples\/webhook_example.html\" rel=\"noopener noreferrer nofollow\">https:\/\/docs.aiogram.dev\/en\/v2.25.1\/examples\/webhook_example.html<\/a><\/p>\n<p>\u041a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 <em>webhook_example.py <\/em>\u043a \u0441\u0435\u0431\u0435 \u0432 \u0444\u0430\u0439\u043b webhook.py \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c.<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441.. 1<\/figcaption><\/div>\n<\/figure>\n<p> \u0420\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u0443\u0435\u043c\u0441\u044f \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435: <a href=\"https:\/\/www.alwaysdata.com\/\" rel=\"noopener noreferrer nofollow\">https:\/\/www.alwaysdata.com\/<\/a> \u043d\u0430 \u0431\u0435\u0441\u043f\u043b\u0430\u0442\u043d\u043e\u043c \u0442\u0430\u0440\u0438\u0444\u0435 \u00abFree for life\u00bb.<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 2<\/figcaption><\/div>\n<\/figure>\n<p> \u041f\u043e\u0441\u043b\u0435 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438, \u0432 \u043f\u0430\u043d\u0435\u043b\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f, \u0436\u043c\u0435\u043c \u0441\u043b\u0435\u0432\u0430 \u0432 \u0440\u0430\u0437\u0434\u0435\u043b\u0435 \u00abWEB\u00bb \u2192 \u00abSites\u00bb. \u0421\u043f\u0440\u0430\u0432\u0430 \u0443\u0432\u0438\u0434\u0438\u043c \u043d\u0430\u0448 \u0441\u0430\u0439\u0442 \u0441 \u0434\u043e\u043c\u0435\u043d\u043d\u044b\u043c \u0438\u043c\u0435\u043d\u0435\u043c 3-\u0435\u0433\u043e \u0443\u0440\u043e\u0432\u043d\u044f.<\/p>\n<p>  \u0423 \u043c\u0435\u043d\u044f \u00abrupyt.alwaysdata.net\u00bb, \u0433\u0434\u0435 rupyt \u2014 \u0438\u043c\u044f \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u044f \u0434\u0430\u0432\u0430\u043b \u043f\u0440\u0438 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438, \u0443 \u0412\u0430\u0441 \u0431\u0443\u0434\u0435\u0442 \u0441\u0432\u043e\u0451.  <\/p>\n<p> <em><u>\u043f\u0440\u0438\u043c. \u0412\u0435\u0437\u0434\u0435 \u0433\u0434\u0435 \u0431\u0443\u0434\u0435\u0442 \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043e \u00abrupyt\u00bb, \u043c\u0435\u043d\u044f\u0435\u043c \u043d\u0430 \u0441\u0432\u043e\u0451 \u0438\u043c\u044f.<\/u><\/em><\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 3<\/figcaption><\/div>\n<\/figure>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 2<\/em><\/strong>.  <strong><em>\u0427\u0435\u0440\u0435\u0437 FTP \u043f\u043e\u043c\u0435\u0441\u0442\u0438\u0442\u044c \u043d\u0430\u0448 \u0444\u0430\u0439\u043b \u0431\u043e\u0442\u0430 \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/em><\/strong><\/p>\n<p>\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0430\u0435\u043c\u0441\u044f \u043f\u043e FTP \u043a \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0443 \u043b\u044e\u0431\u044b\u043c \u0432\u0430\u0448\u0438\u043c FTP-\u043a\u043b\u0438\u0435\u043d\u0442\u043e\u043c.<\/p>\n<p> \u0421\u0442\u0440\u043e\u043a\u0430 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f <a href=\"ftp:\/\/rupyt@ftp-rupyt.alwaysdata.net\/\" rel=\"noopener noreferrer nofollow\">ftp:\/\/rupyt@ftp-rupyt.alwaysdata.net<\/a> \u0434\u043b\u044f \u043c\u0435\u043d\u044f.  <\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 4<\/figcaption><\/div>\n<\/figure>\n<p>\u0415\u0449\u0435 \u0440\u0430\u0437 \u043d\u0430\u043f\u043e\u043c\u043d\u044e, \u0432\u043c\u0435\u0441\u0442\u043e <s>rupyt<\/s>, \u0441\u0442\u0430\u0432\u0438\u043c \u0441\u0432\u043e\u0435 \u0438\u043c\u044f, \u043a\u043e\u0442\u043e\u0440\u043e\u0435 \u0432\u044b \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u043b\u0438 \u043f\u0440\u0438 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438.  <\/p>\n<p>\u0410\u0434\u0440\u0435\u0441 \u0445\u043e\u0441\u0442\u0430 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c, \u0435\u0441\u043b\u0438 \u043d\u0430\u0436\u0430\u0442\u044c \u0432 \u043f\u0430\u043d\u0435\u043b\u0438 \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u043e\u043c, \u0441\u043b\u0435\u0432\u0430 \u00abRemote access\u00bb \u2192 \u00abFTP\u00bb:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 5<\/figcaption><\/div>\n<\/figure>\n<p> \u041f\u043e\u0441\u043b\u0435 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u043f\u0430\u0434\u0430\u0435\u043c \u0432 \u0434\u043e\u043c\u0430\u0448\u043d\u044e\u044e \u043f\u0430\u043f\u043a\u0443.<\/p>\n<p> \u0412 \u043d\u0435\u0439 \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u043f\u0430\u043f\u043a\u0430 \u00abwww\u00bb \u0434\u043b\u044f \u0432\u0435\u0431-\u0441\u0430\u0439\u0442\u043e\u0432.<\/p>\n<p> \u0417\u0430\u0445\u043e\u0434\u0438\u043c \u0432 \u043d\u0435\u0435, \u0441\u043e\u0437\u0434\u0430\u0451\u043c \u043f\u0430\u043f\u043a\u0443 \u00abbot\u00bb<\/p>\n<p> \u041a\u043e\u043f\u0438\u0440\u0443\u0435\u043c \u043d\u0430\u0448 \u043f\u0440\u0438\u043c\u0435\u0440 webhook.py \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433 \u0432 \u044d\u0442\u0443 \u043f\u0430\u043f\u043a\u0443:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 6<\/figcaption><\/div>\n<\/figure>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 3<\/em><\/strong>.  <strong><em>\u0427\u0435\u0440\u0435\u0437 SSH \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0443 aiogram.<\/em><\/strong><\/p>\n<p> \u0414\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043f\u043e SSH, \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u0434\u043b\u044f \u043d\u0435\u0433\u043e.<\/p>\n<p> \u0418\u0434\u0435\u043c \u0432 \u043f\u0430\u043d\u0435\u043b\u044c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u00abRemote access\u00bb \u2192 \u00abSSH\u00bb, \u0436\u043c\u0435\u043c \u043d\u0430 \u00ab\u0448\u0435\u0441\u0442\u0435\u0440\u0435\u043d\u043a\u0443\u00bb \u0441\u043f\u0440\u0430\u0432\u0430, \u0434\u043b\u044f \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 7<\/figcaption><\/div>\n<\/figure>\n<p> \u0421\u0442\u0430\u0432\u0438\u043c \u0433\u0430\u043b\u043a\u0443 \u043d\u0430 \u00abEnable password login\u00bb \u0434\u043b\u044f \u0432\u0445\u043e\u0434\u0430 \u043f\u043e \u043f\u0430\u0440\u043e\u043b\u044e. \u0421\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c\u0441\u044f, \u0436\u043c\u0435\u043c \u00abSubmit\u00bb:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 8<\/figcaption><\/div>\n<\/figure>\n<p> \u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f \u043c\u043e\u0436\u043d\u043e \u0434\u0432\u0443\u043c\u044f \u0441\u043f\u043e\u0441\u043e\u0431\u0430\u043c\u0438.<\/p>\n<p> <u>\u041f\u0435\u0440\u0432\u044b\u0439 \u0441\u043f\u043e\u0441\u043e\u0431<\/u> \u0447\u0435\u0440\u0435\u0437 \u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b \u0432\u0432\u0435\u0434\u044f:  \u00abssh <a href=\"mailto:rupyt@ssh-rupyt.alwaysdata.net\" rel=\"noopener noreferrer nofollow\">rupyt@ssh-rupyt.alwaysdata.net<\/a>\u00bb.<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 9<\/figcaption><\/div>\n<\/figure>\n<p> <u>\u0412\u0442\u043e\u0440\u043e\u0439 \u0441\u043f\u043e\u0441\u043e\u0431<\/u> \u043f\u0440\u044f\u043c\u043e \u0432 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0435, \u043d\u0430\u0436\u0430\u0432 \u043d\u0430 \u00ab(also\u00a0<a href=\"https:\/\/ssh-rupyt.alwaysdata.net\/\" rel=\"noopener noreferrer nofollow\">Web<\/a>\u00a0accessible)\u00bb.<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 10<\/figcaption><\/div>\n<\/figure>\n<p> \u0412\u0432\u043e\u0434\u0438\u043c \u043b\u043e\u0433\u0438\u043d (\u0443 \u043c\u0435\u043d\u044f rupyt) \u0438 \u043f\u0430\u0440\u043e\u043b\u044c.<\/p>\n<p> \u0417\u0434\u0435\u0441\u044c \u043c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0434\u043e\u043c\u0430\u0448\u043d\u0438\u0439 \u043a\u0430\u0442\u0430\u043b\u043e\u0433 (\u043a\u043e\u043c\u0430\u043d\u0434\u0430 pwd), \u043f\u0435\u0440\u0435\u0439\u0442\u0438 \u0432 \u043a\u0430\u0442\u0430\u043b\u043e\u0433 \u00abwww\/bot\u00bb \u0438 \u0444\u0430\u0439\u043b \u00abwebhook.py\u00bb, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043b\u0438  \u043f\u043e FTP.<\/p>\n<p> \u0423\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c \u00abAiogram\u00bb, \u043d\u0430\u0431\u0440\u0430\u0432 \u00ab<strong>pip install aiogram<\/strong>\u00bb.<\/p>\n<p> \u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u0435 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 \u043c\u043e\u0436\u043d\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 \u00abpip freeze\u00bb.<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 11<\/figcaption><\/div>\n<\/figure>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 4<\/em><\/strong>.  <strong><em>\u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430 \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435.<\/em><\/strong><\/p>\n<p> \u0418\u0434\u0435\u043c \u0432 \u043f\u0430\u043d\u0435\u043b\u044c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u00abAdvanced\u00bb \u2192 \u00abServices\u00bb, \u0436\u043c\u0435\u043c \u043d\u0430 \u00ab+Add a service\u00bb:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 12<\/figcaption><\/div>\n<\/figure>\n<p> \u041f\u043e\u043f\u0430\u0434\u0430\u0435\u043c \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438. <\/p>\n<p> 1. SSH user \u2014 \u043d\u0435 \u0442\u0440\u043e\u0433\u0430\u0435\u043c. <\/p>\n<p> 2. \u0412 \u00abCommand\u00bb \u043f\u0438\u0448\u0435\u043c \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0444\u0430\u0439\u043b\u0430 \u0431\u043e\u0442\u0430 \u043d\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u0438\u043c\u0435\u0440\u0430 \u00abwebhook.py\u00bb:  <\/p>\n<p> \u00abpython \/home\/rupyt\/www\/bot\/webhook.py\u00bb<\/p>\n<p> 3. \u0412 \u00abEnvironment\u00bb \u0437\u0430\u043f\u0438\u0448\u0435\u043c \u0442\u043e\u043a\u0435\u043d \u0442\u0435\u043b\u0435\u0433\u0440\u0430\u043c \u0431\u043e\u0442\u0430, \u0431\u0435\u0437 \u043a\u0430\u0432\u044b\u0447\u0435\u043a TG_TOKEN=62671\u2026.<\/p>\n<p> 4. \u0412 \u00abWorking directory\u00bb \u0443\u043a\u0430\u0436\u0435\u043c \u043f\u0443\u0442\u044c \u0433\u0434\u0435 \u043b\u0435\u0436\u0438\u0442 \u043d\u0430\u0448 \u0444\u0430\u0439\u043b \u00abwebhook.py\u00bb:<\/p>\n<p> \u00ab\/home\/rupyt\/www\/bot\/\u00bb   <\/p>\n<p> 5. \u0412 \u00abAnnotation\u00bb \u0434\u0430\u0434\u0438\u043c \u043b\u044e\u0431\u043e\u0435 \u043d\u0430\u0437\u0432\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u0430, \u044f \u0434\u0430\u043b \u00abAiogram Webhook service\u00bb.<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 13<\/figcaption><\/div>\n<\/figure>\n<p> 6. \u0421\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c\u0441\u044f, \u0436\u043c\u0435\u043c \u00abSubmit\u00bb <\/p>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 5<\/em><\/strong>. <strong><em>\u041d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u0441\u0430\u0439\u0442 \u043d\u0430 \u043f\u0435\u0440\u0435\u0430\u0434\u0440\u0435\u0441\u0430\u0446\u0438\u044e \u0432\u0441\u0435\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u043d\u0430 \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430.<\/em><\/strong><\/p>\n<p> \u0418\u0434\u0435\u043c \u0432 \u043f\u0430\u043d\u0435\u043b\u044c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u00abWeb\u00bb \u2192 \u00abSites\u00bb, \u0436\u043c\u0435\u043c \u043d\u0430 \u0448\u0435\u0441\u0442\u0435\u0440\u0435\u043d\u043a\u0443 \u00abEdit\u00bb \u0434\u043b\u044f \u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043d\u0430\u0448\u0435\u0433\u043e \u0441\u0430\u0439\u0442\u0430:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 14<\/figcaption><\/div>\n<\/figure>\n<p> 1. \u041f\u043e\u043f\u0430\u0434\u0430\u0435\u043c \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u00ab<a href=\"https:\/\/admin.alwaysdata.com\/site\/770585\/#configuration\" rel=\"noopener noreferrer nofollow\">CONFIGURATION<\/a>\u00bb. <\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 16<\/figcaption><\/div>\n<\/figure>\n<p> 2. \u00abAddresses\u00bb &#8212; \u043d\u0435 \u0442\u0440\u043e\u0433\u0430\u0435\u043c, \u044d\u0442\u043e \u0438 \u0435\u0441\u0442\u044c \u0412\u0430\u0448 \u0430\u0434\u0440\u0435\u0441 \u0432\u0435\u0431-\u0441\u0430\u0439\u0442\u0430. \u0423 \u043c\u0435\u043d\u044f \u00abrupyt.alwaysdata.net\u00bb.<\/p>\n<p> 3. \u0412 \u00abConfiguration\u00bb \u00abType*\u00bb \u0432\u044b\u0431\u0438\u0440\u0430\u0435\u043c \u00abRedirect\u00bb. <\/p>\n<p> 4. \u0412 \u00abDestination URL*\u00bb \u043f\u0440\u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0435\u043c \u0430\u0434\u0440\u0435\u0441 \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043d\u0430\u0448 \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430.<\/p>\n<p> \u0423 \u043c\u0435\u043d\u044f \u00ab<a href=\"http:\/\/services-rupyt.alwaysdata.net:8350\/\" rel=\"noopener noreferrer nofollow\">http:\/\/services-rupyt.alwaysdata.net:8350<\/a>\u00bb.<\/p>\n<p>  \u0413\u0434\u0435 \u00abservices\u00bb &#8212; \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442, \u0447\u0442\u043e  \u044d\u0442\u043e \u0441\u0435\u0440\u0432\u0438\u0441, \u00abrupyt\u00bb &#8212; \u043c\u043e\u0435 \u0438\u043c\u044f, \u00ab8350\u00bb &#8212; \u043f\u043e\u0440\u0442 \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u0438\u0437 \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d\u0430 8300-8499, \u043a\u0430\u043a \u0441\u043a\u0430\u0437\u0430\u043d\u043e \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438.   <\/p>\n<p> \u0424\u043e\u0440\u043c\u0430\u0442 \u0437\u0430\u043f\u0438\u0441\u0438 \u043c\u043e\u0436\u043d\u043e \u0443\u0432\u0438\u0434\u0435\u0442\u044c \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 <a href=\"https:\/\/help.alwaysdata.com\/en\/services\/\" rel=\"noopener noreferrer nofollow\">https:\/\/help.alwaysdata.com\/en\/services\/<\/a>:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 15<\/figcaption><\/div>\n<\/figure>\n<p> 5. \u0412 \u00abForwarding type*\u00bb \u0432\u044b\u0431\u0438\u0440\u0430\u0435\u043c \u0442\u0438\u043f: \u00abtransparent(reverse proxy)\u00bb.<\/p>\n<p> 6. \u0421\u0442\u0430\u0432\u0438\u043c \u0433\u0430\u043b\u043e\u0447\u043a\u0443 \u043d\u0430 \u00abAppend request path\u00bb \u0434\u043b\u044f \u0442\u043e\u0433\u043e, \u0447\u0442\u043e \u0431\u044b \u043f\u0443\u0442\u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0432\u0430\u043b\u0438\u0441\u044c \u0432 \u0430\u0434\u0440\u0435\u0441 \u043d\u0430\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f, \u0442\u043e \u0435\u0441\u0442\u044c \u0432 \u0441\u0435\u0440\u0432\u0438\u0441 \u0431\u043e\u0442\u0430.<\/p>\n<p> 7. \u0412 \u00abAnnotation\u00bb \u0434\u0430\u0434\u0438\u043c \u043b\u044e\u0431\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u044f, \u044f \u0434\u0430\u043b \u00abRedirect For Bot\u00bb.<\/p>\n<p> 8. \u0418\u0434\u0435\u043c \u0432\u043e \u0432\u043a\u043b\u0430\u0434\u043a\u0443 \u00abSSL\u00bb \u0438 \u0441\u0442\u0430\u0432\u0438\u043c \u0433\u0430\u043b\u043e\u0447\u043a\u0443 \u0434\u043b\u044f HTTPS  \u00abForce HTTPS usage\u00bb:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 17<\/figcaption><\/div>\n<\/figure>\n<p> \u0421\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c\u0441\u044f, \u0436\u043c\u0435\u043c \u00abSubmit\u00bb <\/p>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 6<\/em><\/strong>. <strong>\u041e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0444\u0430\u0439\u043b \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0431\u043e\u0442\u0430 \u0441 \u0443\u0447\u0435\u0442\u043e\u043c \u043d\u0430\u0448\u0438\u0445 \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a.<\/strong><\/p>\n<p> \u041d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435 \u0447\u0435\u0440\u0435\u0437 FTP, \u043e\u0442\u043a\u0440\u043e\u0435\u043c \u043d\u0430\u0448 \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0444\u0430\u0439\u043b \u00abwebhook.py\u00bb \u0438 \u043e\u0442\u0440\u0435\u0434\u0430\u043a\u0442\u0438\u0440\u0443\u0435\u043c.<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 18<\/figcaption><\/div>\n<\/figure>\n<p> 1. \u0418\u043c\u043f\u043e\u0440\u0442\u0438\u0440\u0443\u0435\u043c \u043c\u043e\u0434\u0443\u043b\u044c \u00abOS\u00bb \u0434\u043b\u044f \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0438 \u0442\u043e\u043a\u0435\u043d\u0430 \u0447\u0435\u0440\u0435\u0437 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f.<\/p>\n<p> 2. \u0423\u043a\u0430\u0436\u0435\u043c \u0437\u0430\u0433\u0440\u0443\u0437\u043a\u0443 \u0442\u043e\u043a\u0435\u043d\u0430 \u0447\u0435\u0440\u0435\u0437 \u043e\u043a\u0440\u0443\u0436\u0435\u043d\u0438\u044f \u00abAPI_TOKEN = os.environ[&#8216;TG_TOKEN&#8217;]\u00bb, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u043b\u0438 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 \u0441\u0435\u0440\u0432\u0438\u0441\u0430 , \u0441\u043c\u043e\u0442\u0440\u0438 \u0420\u0438\u0441.13.<\/p>\n<p> 3. \u0414\u043b\u044f WEBHOOK_HOST  \u0443\u043a\u0430\u0436\u0435\u043c \u043d\u0430\u0448 \u0430\u0434\u0440\u0435\u0441 \u0432\u0435\u0431\u0441\u0430\u0439\u0442\u0430:<\/p>\n<p>  \u00ab WEBHOOK_HOST = &#8216;<a href=\"https:\/\/rupyt.alwaysdata.net\/\" rel=\"noopener noreferrer nofollow\">https:\/\/rupyt.alwaysdata.net\/<\/a>&#8216; \u00bb <\/p>\n<p> 4. \u041f\u0443\u0442\u044c \u044f \u0443\u043a\u0430\u0437\u0430\u043b \u00abWEBHOOK_PATH = &#8216;\/bot\/&#8217;\u00bb, \u043c\u043e\u0436\u043d\u043e \u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u043f\u0443\u0441\u0442\u044b\u043c \u0432 \u043a\u0430\u0432\u044b\u0447\u043a\u0430\u0445 &#187;.<\/p>\n<p> 5. WEBAPP_HOST = &#8216;::&#8217; , \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c \u0434\u0432\u0430 \u0434\u0432\u043e\u0435\u0442\u043e\u0447\u0438\u044f, \u043a\u0430\u043a \u0441\u043a\u0430\u0437\u0430\u043d\u043e \u0432 \u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430\u0446\u0438\u0438 (\u0421\u043c\u043e\u0442\u0440\u0438 \u0420\u0438\u0441. 15.), \u0447\u0442\u043e \u0441\u0435\u0440\u0432\u0438\u0441 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0437\u0430\u043f\u0443\u0449\u0435\u043d, \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430 IP \u0432\u0435\u0440\u0441\u0438\u0438 6.  <\/p>\n<p> 6. WEBAPP_PORT = 8350 , \u0432\u044b\u0431\u0440\u0430\u043b\u0438 \u0438\u0437 \u0434\u0438\u0430\u043f\u0430\u0437\u043e\u043d\u0430 8300-8499, \u0443\u043a\u0430\u0437\u0430\u043b\u0438 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 \u00abSites\u00bb \u0441\u043c\u043e\u0442\u0440\u0438 \u0420\u0438\u0441. 16.<\/p>\n<p> \u0421\u043e\u0445\u0440\u0430\u043d\u0438\u043c \u043d\u0430\u0448 \u0444\u0430\u0439\u043b.<\/p>\n<p> <strong><em>\u041f\u0443\u043d\u043a\u0442 7<\/em><\/strong>. <strong><em>\u041f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u043a \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0431\u043e\u0442\u0430, \u043f\u0440\u043e\u0432\u0435\u0440\u043a\u0430 \u0431\u043e\u0442\u0430. \u041f\u0440\u043e\u0441\u043c\u043e\u0442\u0440 \u043b\u043e\u0433\u043e\u0432.<\/em><\/strong><\/p>\n<p> \u0418\u0434\u0435\u043c \u0432 \u043f\u0430\u043d\u0435\u043b\u044c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u00abAdvanced\u00bb \u2192 \u00abServices\u00bb, \u0436\u043c\u0435\u043c \u043d\u0430 \u00abRestart\u00bb:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 19<\/figcaption><\/div>\n<\/figure>\n<p> \u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c \u0442\u0435\u043b\u0435\u0433\u0440\u0430\u043c\u043c \u043a\u043b\u0438\u0435\u043d\u0442\u0430, \u0438 \u0432\u0432\u0435\u0434\u0435\u043c \u0447\u0442\u043e-\u043d\u0438\u0431\u0443\u0434\u044c. \u0412\u0438\u0434\u0438\u043c \u0447\u0442\u043e \u0431\u043e\u0442 \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442 \u00ab\u044d\u0445\u043e\u043c\u00bb. \u0423\u0440\u0430!<\/p>\n<p> \u041c\u043e\u0436\u043d\u043e \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u043b\u043e\u0433\u0438 \u0434\u043b\u044f \u0441\u0430\u0439\u0442\u0430 \u0438\u043b\u0438 \u0441\u0435\u0440\u0432\u0438\u0441\u0430.  <\/p>\n<p> \u0414\u043b\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u0438\u0434\u0435\u043c  \u0432 \u043f\u0430\u043d\u0435\u043b\u044c \u0443\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u00abAdvanced\u00bb \u2192 \u00abServices\u00bb, \u0436\u043c\u0435\u043c \u043d\u0430 \u00abLogs\u00bb:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 20<\/figcaption><\/div>\n<\/figure>\n<p> \u0412 \u043b\u043e\u0433\u0430\u0445 \u0432\u0438\u0434\u0438\u043c:<\/p>\n<p> &#8212; \u0437\u0430\u043f\u0443\u0441\u043a \u0441\u0435\u0440\u0432\u0438\u0441\u0430 \u043d\u0430 IPv6 \u00ab::\u00bb \u0438 \u043f\u043e\u0440\u0442\u0443 8350<\/p>\n<p> &#8212; \u043a\u043e\u043c\u0430\u043d\u0434\u0443 \u0437\u0430\u043f\u0443\u0441\u043a\u0430, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0443\u043a\u0430\u0437\u0430\u043b\u0438 \u0434\u043b\u044f \u0441\u0435\u0440\u0432\u0438\u0441\u0430.<\/p>\n<p> &#8212; \u0438\u043c\u044f \u0431\u043e\u0442\u0430 \u0438 \u0443\u0434\u0430\u0447\u043d\u044b\u0439 \u0437\u0430\u043f\u0443\u0441\u043a \u0435\u0433\u043e.<\/p>\n<p> &#8212; POST \u0437\u0430\u043f\u0440\u043e\u0441 \u043f\u043e path \u00ab\/bot\/\u00bb, c \u0443\u0434\u0430\u0447\u043d\u044b\u043c status_code = 200.<\/p>\n<p> <strong>\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0437\u0430\u043a\u043e\u043d\u0447\u0435\u043d\u0430 !!! <\/strong> <\/p>\n<p> \u0414\u043b\u044f \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0430 \u0441\u0432\u043e\u0435\u0433\u043e \u0431\u043e\u0442\u0430 \u0441 polling-\u043e\u043c \u043d\u0430 \u0432\u0435\u0431\u0445\u0443\u043a, \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0441\u043a\u043e\u043f\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0445\u0435\u043d\u0434\u043b\u0435\u0440\u044b \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0432 \u043d\u0430\u0448 \u0444\u0430\u0439\u043b webhook.py \u043d\u0430 \u0445\u043e\u0441\u0442\u0438\u043d\u0433\u0435:<\/p>\n<figure class=\"full-width\">\n<div><figcaption>\u0440\u0438\u0441. 21<\/figcaption><\/div>\n<\/figure>\n<p> <em>\u041d\u0430\u0434\u0435\u044e\u0441\u044c \u043a\u043e\u043c\u0443-\u0442\u043e \u043f\u043e\u043c\u043e\u0436\u0435\u0442. \u0412\u0441\u0435\u043c \u0443\u0434\u0430\u0447\u0438! )<\/em><\/p>\n<\/p>\n<\/div>\n<\/div>\n<\/div>\n<p><!----><!----><\/div>\n<p><!----><!----><br \/> \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\/articles\/730310\/\"> https:\/\/habr.com\/ru\/articles\/730310\/<\/a><br \/><\/br><\/br><\/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-415826","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/415826","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=415826"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/415826\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=415826"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=415826"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=415826"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}