{"id":281214,"date":"2016-11-20T04:20:03","date_gmt":"2016-11-20T01:20:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=281214"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=281214","title":{"rendered":"\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 Virtual Private Network \u043d\u0430 AWS EC2 c OpenVPN \u043d\u0430 Linux"},"content":{"rendered":"<p>Amazon Web Service \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0431\u0435\u0441\u043f\u043b\u0430\u0442\u043d\u043e\u0433\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0432 \u0442\u0435\u0447\u0435\u043d\u0438\u0435 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0433\u043e \u043f\u0435\u0440\u0438\u043e\u0434\u0430 (12 \u043c\u0435\u0441\u044f\u0446\u0435\u0432) \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432 Amazon EC2. \u0422\u0430\u043a\u043e\u0439 \u0441\u0435\u0440\u0432\u0435\u0440 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d \u0434\u043b\u044f VPN (\u0430\u043d\u0433\u043b. Virtual Private Network \u2014 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u0430\u044f \u0447\u0430\u0441\u0442\u043d\u0430\u044f \u0441\u0435\u0442\u044c). \u041f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u044d\u0442\u043e\u0439 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0439 \u0441\u0435\u0440\u0432\u0435\u0440 \u0441\u043b\u0443\u0436\u0438\u0442 \u043f\u043e\u0441\u0440\u0435\u0434\u043d\u0438\u043a\u043e\u043c \u043c\u0435\u0436\u0434\u0443 \u0432\u0430\u0448\u0438\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u043e\u043c \u0438 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u0441\u0435\u0440\u0432\u0435\u0440\u0430\u043c\u0438 \u0432 \u0418\u043d\u0442\u0435\u0440\u043d\u0435\u0442. <\/p>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043f\u043e\u043b\u0435\u0437\u043d\u043e \u0432 \u0441\u043b\u0443\u0447\u0430\u044f\u0445 \u043a\u043e\u0433\u0434\u0430 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0437\u0430\u0439\u0442\u0438 \u043d\u0430 \u0441\u0430\u0439\u0442 \u0432 \u043e\u0431\u0445\u043e\u0434 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043e\u043a (\u0434\u043b\u044f \u0432\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u043e\u0432\u0430\u0439\u0434\u0435\u0440\u0430 \u0432\u044b \u0441\u0432\u044f\u0437\u044b\u0432\u0430\u0435\u0442\u0435\u0441\u044c \u0441 \u0432\u0430\u0448\u0438\u043c VPN \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u043c, \u0430 \u043d\u0435 \u0441 \u0441\u0430\u0439\u0442\u043e\u043c \u0441 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0432\u044b \u0444\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0435 \u0434\u0430\u043d\u043d\u044b\u0435), \u0438\u043b\u0438, \u0441\u043a\u0430\u0436\u0435\u043c, \u0438\u043c\u0435\u0442\u044c \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u044b\u0439 IP \u0441 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u043c \u0441\u0435\u0440\u0432\u0438\u0441\u0430\u043c, \u0438\u043b\u0438 \u0438\u043c\u0435\u0442\u044c IP \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0439 \u043d\u0435 \u0441 \u0442\u0435\u043c \u0440\u0435\u0433\u0438\u043e\u043d\u043e\u043c \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0432\u044b \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u0438 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0435\u0441\u044c (\u0441\u0430\u0439\u0442 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 \u0437\u0430\u0445\u043e\u0434 \u0441 IP \u0432\u0430\u0448\u0435\u0433\u043e \u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u0430 \u043d\u0435 \u0441 IP \u0432\u0430\u0448\u0435\u0439 \u0440\u0430\u0431\u043e\u0447\u0435\u0439 \u043c\u0430\u0448\u0438\u043d\u044b)<\/p>\n<p><a name=\"habracut\"><\/a>  <\/p>\n<h4 id=\"sozdanie-servera-na-aws-ec2\">\u0421\u043e\u0437\u0434\u0430\u043d\u0438\u0435 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u043d\u0430 AWS EC2<\/h4>\n<p>  <\/p>\n<p>\u0418\u0442\u0430\u043a, \u0434\u043b\u044f \u043d\u0430\u0447\u0430\u043b\u0430 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0438\u0440\u0443\u0435\u043c\u0441\u044f \u043d\u0430 <a href=\"https:\/\/aws.amazon.com\">https:\/\/aws.amazon.com<\/a>, \u0434\u043b\u044f \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438 \u043f\u043e\u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0449\u0430\u044f \u043a\u0440\u0435\u0434\u0438\u0442\u043d\u0430\u044f \u043a\u0430\u0440\u0442\u0430. <\/p>\n<p>  <\/p>\n<p>\u041f\u043e\u0441\u043b\u0435 \u0440\u0435\u0433\u0438\u0441\u0442\u0440\u0430\u0446\u0438\u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u044c <a href=\"https:\/\/console.aws.amazon.com\/console\/home\">https:\/\/console.aws.amazon.com\/console\/home<\/a><\/p>\n<p>  <\/p>\n<p>\u0412 \u043f\u0440\u0430\u0432\u043e\u043c \u0432\u0435\u0440\u0445\u043d\u0435\u043c \u0443\u0433\u043b\u0443 \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u043d\u0430 \u043c\u0435\u043d\u044e &quot;Services&quot; \u0438 \u0432 \u0440\u0430\u0437\u0434\u0435\u043b\u0435 &quot;Compute&quot; \u0432\u044b\u0431\u0438\u0440\u0430\u0435\u043c &quot;EC2&quot; <\/p>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/30e\/09d\/639\/30e09d639c704d0ab1b16b2c2a332eff.png\" alt=\"image\"\/><\/p>\n<p>  <\/p>\n<p>\u0414\u043b\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u0431\u0443\u0434\u0443\u0449\u0435\u043c\u0443 \u0441\u0435\u0440\u0432\u0435\u0440\u0443 \u043d\u0430\u043c \u043f\u043e\u0442\u0440\u0435\u0431\u0443\u0435\u0442\u0441\u044f \u0441\u043e\u0437\u0434\u0430\u0442\u044c \u043a\u043b\u044e\u0447. <\/p>\n<p>  <\/p>\n<p>\u041d\u0430\u0436\u0438\u043c\u0430\u0435\u043c &quot;Key Pairs&quot;, \u0434\u0430\u043b\u0435\u0435 \u043a\u043d\u043e\u043f\u043a\u0443 &quot;Create Key Paire&quot;, \u0437\u0430\u0434\u0430\u0435\u043c \u0438\u043c\u044f \u0434\u043b\u044f \u043a\u043b\u044e\u0447\u0430, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 &quot;myVPNkey&quot; \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c \u044d\u0442\u043e\u0442 \u0444\u0430\u0439\u043b (c \u0440\u0430\u0441\u0448\u0438\u0440\u0435\u043d\u0438\u0435\u043c .pem) \u043d\u0430 \u0441\u0432\u043e\u0439 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440, \u043e\u0431\u044b\u0447\u043d\u043e \u0432 \u043f\u0430\u043f\u043a\u0443 ~\/.ssh <\/p>\n<p>  <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u0432 \u043f\u0430\u043f\u043a\u0443 \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u043c\u044b \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u043b\u0438 \u043a\u043b\u044e\u0447 \u0438 \u0437\u0430\u0434\u0430\u0435\u043c \u043f\u0440\u0430\u0432\u0430 \u043d\u0430 \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0444\u0430\u0439\u043b\u0443: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">cd ~\/.ssh  chmod 400 myVPNkey.pem<\/code><\/pre>\n<p>  <\/p>\n<p>\u0422\u0430\u043a\u0436\u0435 \u043d\u0443\u0436\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043a\u043e\u043f\u0438\u044e \u044d\u0442\u043e\u0433\u043e \u0444\u0430\u0439\u043b\u0430 \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u0442\u044c \u0432 \u043d\u0430\u0434\u0435\u0436\u043d\u043e\u043c \u043c\u0435\u0441\u0442\u0435. <\/p>\n<p>  <\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043d\u0430 \u0441\u0430\u0439\u0442\u0435 AWS \u0432\u043e\u0437\u0432\u0440\u0430\u0449\u0430\u0435\u043c\u0441\u044f \u0432 EC2 Dashboard (\u0441\u043c. \u043c\u0435\u043d\u044e \u0432 \u0432 \u043b\u0435\u0432\u043e\u043c \u0432\u0435\u0440\u0445\u043d\u0435\u043c \u0443\u0433\u043b\u0443), \u0438 \u0442\u0430\u043c \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u043d\u0430 \u0431\u043e\u043b\u044c\u0448\u0443\u044e \u0441\u0438\u043d\u044e\u044e \u043a\u043d\u043e\u043f\u043a\u0443 &quot;Launch Instance&quot; <\/p>\n<p>  <\/p>\n<ol>\n<li>\n<p>\u0412\u044b\u0431\u0438\u0440\u0430\u0435\u043c \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u043e\u043d\u043d\u0443\u044e \u0441\u0438\u0441\u0442\u0435\u043c\u0443 \u0434\u043b\u044f \u0441\u0435\u0440\u0432\u0435\u0440\u0430: Ubuntu Server 16.04 LTS (HVM) 64-bit, \u0438\u043b\u0438 Ubuntu Server 14.04 LTS<\/p>\n<p>  <\/li>\n<li>\n<p>\u0412\u044b\u0431\u0438\u0440\u0430\u0435\u043c \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u044e \u0441\u0435\u0440\u0432\u0435\u0440\u0430. \u0414\u043b\u044f \u043d\u0430\u0448\u0438\u0445 \u0446\u0435\u043b\u0435\u0439 \u0432\u043f\u043e\u043b\u043d\u0435 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 \u0431\u0435\u0441\u043f\u043b\u0430\u0442\u043d\u043e\u0439 \u043d\u0430 \u043f\u0440\u043e\u0431\u043d\u044b\u0439 \u043f\u0435\u0440\u0438\u043e\u0434:<br \/>  t2.micro (Variable ECUs, 1 vCPUs, 2.5 GHz, Intel Xeon Family, 1 GiB memory, EBS only) \u2014 \u0431\u0443\u0434\u0435\u0442 \u043e\u0442\u043c\u0435\u0447\u0435\u043d \u0437\u0435\u043b\u0435\u043d\u044b\u043c \u044f\u0440\u043b\u044b\u043a\u043e\u043c &quot;Free tier eligible&quot;. \u041d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u0441\u0438\u043d\u044e\u044e \u043a\u043d\u043e\u043f\u043a\u0443 &quot;Review and launch&quot; <\/p>\n<p>  <\/li>\n<li>\n<p>(Step 7: Review Instance Launch) \u0432 \u0440\u0430\u0437\u0434\u0435\u043b\u0435 Security Groups \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u043c &quot;Edit security groups&quot; <\/p>\n<p>  <\/li>\n<li>(Configure Security Group )\u0412\u044b\u0431\u0438\u0440\u0430\u0435\u043c: Assign a security group: * Create a new security group<\/li>\n<\/ol>\n<p>  <\/p>\n<p>\u0412\u044b\u0431\u0438\u0440\u0430\u0435\u043c \u0438\u043c\u044f \u0432 Security group name, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 &quot;myVPN&quot; <\/p>\n<p>  <\/p>\n<p>\u0414\u0430\u043b\u0435\u0435 \u043c\u044b \u0432\u0438\u0434\u0438\u043c \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u044e\u0449\u0438\u0435 \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u0441\u0435\u0440\u0432\u0435\u0440\u0443. \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0435\u0441\u0442\u044c \u043e\u0434\u043d\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u043e: <\/p>\n<p>  <\/p>\n<p>Type: SSH <\/p>\n<p>  <\/p>\n<p>Protocol: TCP<\/p>\n<p>  <\/p>\n<p>Port Range: 22<\/p>\n<p>  <\/p>\n<p>Source: Custom 0.0.0.0\/0<\/p>\n<p>  <\/p>\n<p>\u0412 \u0434\u0430\u043d\u043d\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u0438\u043c\u0435\u0435\u0442\u0441\u044f \u0432 \u0432\u0438\u0434\u0443 \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d\u043e \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043a \u0441\u0435\u0440\u0432\u0435\u0440\u0443 \u0441 \u043b\u044e\u0431\u043e\u0433\u043e IP \u043a \u043f\u043e\u0440\u0442\u0443 22 \u043f\u043e \u043f\u0440\u043e\u0442\u043e\u043a\u043e\u043b\u0443 SSH. \u042d\u0442\u043e \u0441\u0442\u0430\u043d\u0434\u0430\u0440\u0442\u043d\u044b\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0435 \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f ssh. <\/p>\n<p>  <\/p>\n<p>\u041d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u043a\u043d\u043e\u043f\u043a\u0443 &quot;Add Rule&quot;, \u0438 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0435\u043c \u043d\u043e\u0432\u043e\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u043e: <\/p>\n<p>  <\/p>\n<p>Type: All traffic<\/p>\n<p>  <\/p>\n<p>Protocol: All <\/p>\n<p>  <\/p>\n<p>Port Range: 0-65535<\/p>\n<p>  <\/p>\n<p>Source: My IP<\/p>\n<p>  <\/p>\n<p>\u0432 Source \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c IP \u0432\u0430\u0448\u0435\u0439 \u0440\u0430\u0431\u043e\u0447\u0435\u0439 \u043c\u0430\u0448\u0438\u043d\u044b, \u0435\u0441\u043b\u0438 \u0432\u044b\u0431\u0440\u0430\u0442\u044c &quot;My IP&quot;, \u043e\u043d \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u0441\u044f \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438.<br \/>  \u0423\u043a\u0430\u0437\u0430\u043d\u0438\u0435 IP \u043e\u0437\u043d\u0430\u0447\u0430\u0435\u0442 \u0447\u0442\u043e \u0432 \u0440\u0430\u043c\u043a\u0430\u0445 \u044d\u0442\u043e\u0433\u043e \u043f\u0440\u0430\u0432\u0438\u043b\u0430 \u0434\u043e\u0441\u0442\u0443\u043f \u0440\u0430\u0437\u0440\u0435\u0448\u0435\u043d \u0442\u043e\u043b\u044c\u043a\u043e \u0441 \u044d\u0442\u043e\u0433\u043e IP (\u0435\u0433\u043e \u043f\u043e\u0442\u043e\u043c \u043c\u043e\u0436\u043d\u043e \u0431\u0443\u0434\u0435\u0442, \u0435\u0441\u0442\u0435\u0441\u0442\u0432\u0435\u043d\u043d\u043e, \u043c\u0435\u043d\u044f\u0442\u044c, \u0435\u0441\u043b\u0438 \u0432\u044b \u0431\u0443\u0434\u0435\u0442\u0435 \u0437\u0430\u0445\u043e\u0434\u0438\u0442\u044c \u0432 \u0418\u043d\u0442\u0435\u0440\u043d\u0435\u0442 \u043f\u043e\u0434 \u0434\u0440\u0443\u0433\u0438\u043c IP)<\/p>\n<p>  <\/p>\n<p>\u0421\u0432\u043e\u0439 IP \u043c\u043e\u0436\u043d\u043e \u0443\u0437\u043d\u0430\u0442\u044c\/\u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0437\u0430\u0434\u0430\u0432 \u0432 \u043f\u043e\u0438\u0441\u043a\u0435 Google &quot;my ip&quot;. \u0418\u043b\u0438 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0441\u043f\u0435\u0446\u0438\u0430\u043b\u0438\u0437\u0438\u0440\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0441\u0430\u0439\u0442\u043e\u0432. \u0412 \u043a\u043e\u043d\u0441\u043e\u043b\u0438: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">wget -qO- http:\/\/ipecho.net\/plain ; echo<\/code><\/pre>\n<p>  <\/p>\n<p>\u0438\u043b\u0438 <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">curl ipecho.net\/plain ; echo<\/code><\/pre>\n<p>  <\/p>\n<p>\u041f\u0435\u0440\u0432\u043e\u0435 \u043f\u0440\u0430\u0432\u0438\u043b\u043e \u043c\u043e\u0436\u043d\u043e \u0443\u0434\u0430\u043b\u0438\u0442\u044c (\u0440\u0435\u043a\u043e\u043c\u0435\u043d\u0434\u0443\u0435\u0442\u0441\u044f). \u0418\u043b\u0438 \u043f\u0440\u043e\u043f\u0438\u0441\u0430\u0442\u044c \u0432 \u043d\u0435\u043c \u0442\u0430\u043a\u0436\u0435 \u0441\u0432\u043e\u0439 IP. \u0418\u043b\u0438 \u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u0441 \u043b\u044e\u0431\u043e\u0433\u043e IP \u0438 \u043f\u0440\u043e\u0438\u0433\u043d\u043e\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u043f\u0440\u0435\u0434\u0443\u043f\u0440\u0435\u0436\u0434\u0435\u043d\u0438\u0435 &quot;Rules with source of 0.0.0.0\/0 allow all IP addresses to access your instance. We recommend setting security group rules to allow access from known IP addresses only&quot; <\/p>\n<p>  <\/p>\n<p>\u0421\u043d\u043e\u0432\u0430 \u0436\u043c\u0435\u043c &quot;Review and Launch&quot;, \u043f\u0440\u043e\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u0435\u043c \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e, \u0438 \u0436\u043c\u0435\u043c &quot;Launch&quot; \u2014 \u0443 \u043d\u0430\u0441 \u043f\u043e\u044f\u0432\u0438\u0442\u044c\u0441\u044f \u043e\u043a\u043d\u043e \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u043d\u0443\u0436\u043d\u043e \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u043a\u043b\u044e\u0447 \u0434\u043b\u044f \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u0441\u0435\u0440\u0432\u0435\u0440\u0443. <\/p>\n<p>  <\/p>\n<p>\u0412\u044b\u0431\u0438\u0440\u0430\u0435\u043c \u043a\u043b\u044e\u0447 \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043c\u044b \u0440\u0430\u043d\u0435\u0435 \u0441\u043e\u0437\u0434\u0430\u043b\u0438 (existing key par), \u043e\u0442\u043c\u0435\u0447\u0430\u0435\u043c \u043f\u0443\u043d\u043a\u0442 &quot;I acknowledge that I have access to the selected private key file (myVPNkey.pem), and that without this file, I won&#8217;t be able to log into my instance&quot; \u0438 \u043d\u0430\u0436\u0438\u043c\u0430\u0435\u043c &quot;Launch Instances&quot;. <\/p>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u0432\u0441\u0435 \u0445\u043e\u0440\u043e\u0448\u043e, \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 \u0447\u0442\u043e \u0441\u0435\u0440\u0432\u0435\u0440 \u0437\u0430\u043f\u0443\u0449\u0435\u043d. \u041d\u0430\u0436\u0438\u043c\u0430\u0435\u043c \u043a\u043d\u043e\u043f\u043a\u0443 &quot;View Instances&quot; \u0438 \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u044c \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0443\u0432\u0438\u0434\u0438\u043c \u0441\u043f\u0438\u0441\u043e\u043a \u043d\u0430\u0448\u0438\u0445 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432. \u041a\u043e\u0433\u0434\u0430 \u043c\u044b \u043e\u0442\u043c\u0435\u0447\u0430\u0435\u043c \u0441\u0435\u0440\u0432\u0435\u0440 \u0432 \u0441\u043f\u0438\u0441\u043a\u0435 \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u0440\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0435\u0433\u043e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e, \u0432 \u0447\u0430\u0441\u0442\u043d\u043e\u0441\u0442\u0438 \u0435\u0433\u043e IP, \u0430 \u0442\u0430\u043a\u0436\u0435 \u0432\u044b\u043f\u043e\u043b\u043d\u0438\u0442\u044c \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f \u0441 \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u043c (\u043e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c, \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u0442\u044c, \u0443\u0434\u0430\u043b\u0438\u0442\u044c \u0438 \u0442.\u043f.) \u041d\u0430\u0436\u0430\u0442\u0438\u0435 \u043a\u043d\u043e\u043f\u043a\u0438 &quot;Connect&quot; \u0432\u044b\u0432\u0435\u0434\u0435\u0442 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u0443\u044e \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043a \u0441\u0435\u0440\u0432\u0435\u0440\u0443.<\/p>\n<p>  <\/p>\n<h4 id=\"nastroyka-servera\">\u041d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0430<\/h4>\n<p>  <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0438\u0437 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c\u0441\u044f \u0441 \u0441\u0435\u0440\u0432\u0435\u0440\u0443 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f ssh. \u0418\u043c\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e: ubuntu, \u0434\u043b\u044f \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043b\u0438\u0431\u043e IP \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u043b\u0438\u0431\u043e \u0435\u0433\u043e \u0434\u043e\u043c\u0435\u043d\u043d\u043e\u0435 \u0438\u043c\u044f \u0432\u0438\u0434\u0430: ec2-35-163-203-49.us-west-2.compute.amazonaws.com<\/p>\n<p>  <\/p>\n<p>\u0412\u0432\u043e\u0434\u0438\u043c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u0443: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">ssh -i &quot;~\/.ssh\/myVPNkey.pem&quot; ubuntu@ec2-35-163-203-49.us-west-2.compute.amazonaws.com<\/code><\/pre>\n<p>  <\/p>\n<p>\u043f\u0440\u0438 \u043f\u0435\u0440\u0432\u043e\u043c \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0438 \u043d\u0430\u043c \u043d\u0443\u0436\u043d\u043e \u0431\u0443\u0434\u0435\u0442 \u043d\u0430 \u0432\u043e\u043f\u0440\u043e\u0441: Are you sure you want to continue connecting (yes\/no)? \u2014 \u043d\u0430\u0431\u0440\u0430\u0442\u044c \u043e\u0442\u0432\u0435\u0442 &quot;yes&quot; (\u043f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u043e\u0442\u0432\u0435\u0442 &quot;no&quot;, \u0438 \u0435\u0441\u043b\u0438 \u043f\u0440\u043e\u0441\u0442\u043e \u043d\u0430\u0436\u0430\u0442\u044c Enter, \u043f\u043e\u043b\u0443\u0447\u0438\u043c \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435 &quot;Host key verification failed.&quot;<\/p>\n<p>  <\/p>\n<p>\u041f\u0440\u0438 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0438 \u0442\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u0435\u0442 \u0432\u044b\u0434\u0430\u0432\u0430\u0442\u044c\u0441\u044f \u043e\u0448\u0438\u0431\u043a\u0430:<br \/>  &quot;Permissions 0644 for &#8216;~\/.ssh\/myVPNkey.pem&#8217; are too open.<br \/>  It is required that your private key files are NOT accessible by others.<br \/>  This private key will be ignored.&quot;<br \/>  \u042d\u0442\u043e\u043c \u0441\u043b\u0443\u0447\u0430\u0435 \u043d\u0443\u0436\u043d\u043e \u043a\u0430\u043a \u0431\u044b\u043b\u043e \u0443\u043a\u0430\u0437\u0430\u043d\u043e \u0432\u044b\u0448\u0435 \u0438\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u043f\u0440\u0430\u0432\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u0444\u0430\u0439\u043b\u0443<\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">chmod 400 ~\/.ssh\/myVPNkey.pem<\/code><\/pre>\n<p>  <\/p>\n<p>\u0415\u0441\u043b\u0438 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043f\u0440\u043e\u0438\u0441\u0445\u043e\u0434\u0438\u0442 \u0431\u043b\u0430\u0433\u043e\u043f\u043e\u043b\u0443\u0447\u043d\u043e, \u043c\u044b \u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u044c \u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u043e \u0447\u0435\u043c \u0441\u0432\u0438\u0434\u0435\u0442\u0435\u043b\u044c\u0441\u0442\u0432\u0443\u0435\u0442 \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u043e\u043a\u0438 \u043d\u0430 \u0447\u0442\u043e-\u0442\u043e \u0432\u0440\u043e\u0434\u0435 ubuntu@ip-172-31-21-156:~$ <\/p>\n<p>  <\/p>\n<h4 id=\"ustanovka-openvpn-na-servere\">\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 OpenVPN \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0435<\/h4>\n<p>  <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u0441\u043d\u0430\u0447\u0430\u043b\u0430 (\u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e) \u043e\u0431\u043d\u043e\u0432\u043b\u044f\u0435\u043c \u043f\u0440\u043e\u0433\u0440\u0430\u043c\u043c\u043d\u043e\u0435 \u043e\u0431\u0435\u0441\u043f\u0435\u0447\u0435\u043d\u0438\u0435: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo apt-get update &amp;&amp; sudo apt-get upgrade -y &amp;&amp; sudo apt-get -y autoremove &amp;&amp; sudo apt-get install -f<\/code><\/pre>\n<p>  <\/p>\n<p>\u043f\u043e\u0442\u043e\u043c \u0443\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c OpenVPN<\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo apt-get install -y openvpn<\/code><\/pre>\n<p>  <\/p>\n<p>\u043d\u0430\u0441\u0442\u0440\u0430\u0438\u0432\u0430\u0435\u043c \u043f\u0435\u0440\u0435\u0430\u0434\u0440\u0435\u0441\u0430\u0446\u0438\u044e (IP forwarding) (<em>\u043f\u0440\u0438 \u0432\u044b\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0438\/\u043f\u0435\u0440\u0435\u0437\u0430\u043f\u0443\u0441\u043a\u0435 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u044d\u0442\u043e \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0435\u043c<\/em>): <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo modprobe iptable_nat echo 1 | sudo tee \/proc\/sys\/net\/ipv4\/ip_forward sudo iptables -t nat -A POSTROUTING -s 10.4.0.1\/2 -o eth0 -j MASQUERADE<\/code><\/pre>\n<p>  <\/p>\n<p>\u043f\u0435\u0440\u0435\u0445\u043e\u0434\u0438\u043c \u0432 \u043f\u0430\u043f\u043a\u0443 openvpn \u0438 \u0441\u043e\u0437\u0434\u0430\u0435\u043c \u0441\u0435\u043a\u0440\u0435\u0442\u043d\u044b\u0439 \u043a\u043b\u044e\u0447: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">cd \/etc\/openvpn sudo openvpn --genkey --secret ovpn.key<\/code><\/pre>\n<p>  <\/p>\n<p>\u0441\u043e\u0437\u0434\u0430\u0435\u043c \u0444\u0430\u0439\u043b \u043a\u043e\u043d\u0444\u0438\u0433\u0443\u0440\u0430\u0446\u0438\u0438 OpenVPN, \u043d\u0430\u0437\u043e\u0432\u0435\u043c \u0435\u0433\u043e openvpn.server.conf, \u0434\u043b\u044f \u044d\u0442\u043e\u0433\u043e \u0432\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0441\u044f \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440\u043e\u043c nano \u0440\u0430\u0431\u043e\u0442\u0430\u044e\u0449\u0438\u043c \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438:<\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo nano openvpn.server.conf <\/code><\/pre>\n<p>  <\/p>\n<p>\u0432 \u0444\u0430\u0439\u043b \u0432\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u043c: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">port 1194 proto tcp-server dev tun1 ifconfig 10.4.0.1 10.4.0.2 status server-tcp.log verb 3 secret ovpn.key<\/code><\/pre>\n<p>  <\/p>\n<p>\u043d\u0430\u0436\u0438\u043c\u0430\u0435\u043c CTRL+O \u0438 \u043f\u043e\u0434\u0442\u0432\u0435\u0440\u0436\u0434\u0430\u0435\u043c \u0437\u0430\u043f\u0438\u0441\u044c \u0432 \u0444\u0430\u0439\u043b, \u0432\u044b\u0445\u043e\u0434\u0438\u043c \u0438\u0437 \u0440\u0435\u0434\u0430\u043a\u0442\u043e\u0440\u0430 \u2014 CTRL-Z.<\/p>\n<p>  <\/p>\n<p>\u0417\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c OpenVPN \u043d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439 <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo service openvpn start<\/code><\/pre>\n<p>  <\/p>\n<p>\u041e\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c \u0441\u043e\u043e\u0442\u0432\u0435\u0442\u0441\u0442\u0432\u0435\u043d\u043d\u043e \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439:<\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo service openvpn start<\/code><\/pre>\n<p>  <\/p>\n<p>\u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0435\u043c \u0437\u0430\u043f\u0443\u0449\u0435\u043d \u043b\u0438 \u0443 \u043d\u0430\u0441 openvpn <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo service openvpn status<\/code><\/pre>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/a2c\/ccf\/4be\/a2cccf4be18c4d959a5a9808881eccac.png\" alt=\"image\"\/><\/p>\n<p>  <\/p>\n<h4 id=\"ustanovka-i-nastroyka-openvpn-na-lokalnoy-mashine\">\u0423\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0438 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430 OpenVPN \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0448\u0438\u043d\u0435<\/h4>\n<p>  <\/p>\n<p>\u041e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u043c \u0435\u0449\u0435 \u043e\u0434\u043d\u043e \u043e\u043a\u043d\u043e \u043a\u043e\u043d\u0441\u043e\u043b\u0438 (\u0442\u0435\u0440\u043c\u0438\u043d\u0430\u043b\u0430) \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0448\u0438\u043d\u0435.<br \/>  \u0423\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0435\u043c OpenVPN \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo apt-get install -y openvpn<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 <em>\u0441\u0435\u0440\u0432\u0435\u0440\u0430<\/em> \u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e \u043c\u0435\u043d\u044f\u0435\u043c \u043f\u0440\u0430\u0432\u0430 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043d\u0430 \u0444\u0430\u0439\u043b \u043a\u043b\u044e\u0447\u0430: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo chmod 777 \/etc\/openvpn\/ovpn.key<\/code><\/pre>\n<p>  <\/p>\n<p>\u0412 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0448\u0438\u043d\u044b \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u043f\u0430\u043f\u043a\u0443 \u0434\u043b\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a OpenVPN: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">mkdir ~\/OpenVPNconf &amp;&amp; cd  ~\/OpenVPNconf<\/code><\/pre>\n<p>  <\/p>\n<p>\u0438 \u0441\u043a\u0430\u0447\u0430\u0435\u043c \u0442\u0443\u0434\u0430 \u0441 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u043a\u043b\u044e\u0447 OpenVPN: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">scp -i &quot;~\/.ssh\/myVPNkey.pem&quot; ubuntu@ec2-35-163-203-49.us-west-2.compute.amazonaws.com:\/etc\/openvpn\/ovpn.key  ~\/OpenVPNconf\/<\/code><\/pre>\n<p>  <\/p>\n<p>\u041d\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0435 \u0432\u0435\u0440\u043d\u0435\u043c \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u0434\u043b\u044f \u0444\u0430\u0439\u043b\u0430 \u043a\u043b\u044e\u0447\u0430: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo chmod 600 \/etc\/openvpn\/ovpn.key<\/code><\/pre>\n<p>  <\/p>\n<p>\u0422\u0430\u043a\u0436\u0435 \u0438 \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u0439: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo chmod 600 ~\/OpenVPNconf\/ovpn.key<\/code><\/pre>\n<p>  <\/p>\n<p>\u041d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u0439 \u043c\u0430\u0448\u0438\u043d\u0435 \u0441\u043e\u0437\u0434\u0430\u0434\u0438\u043c \u0444\u0430\u0439\u043b \u0441 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u043c\u0438 OpenVPN, \u043d\u0430\u0437\u043e\u0432\u0435\u043c \u0435\u0433\u043e openvpn.server.conf, <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">gedit openvpn.server.conf <\/code><\/pre>\n<p>  <\/p>\n<p>\u0432 \u0444\u0430\u0439\u043b \u0432\u0441\u0442\u0430\u0432\u0438\u043c: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">proto tcp-client remote \u0442\u0443\u0442.IP.\u0430\u0434\u0440\u0435\u0441.\u0441\u0435\u0440\u0432\u0435\u0440\u0430.\u043d\u0430.\u0410\u043c\u0430\u0437\u043e\u043d port 1194                    dev tun                    secret &quot;\/home\/\u0418\u043c\u044f\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f\/OpenVPNconf\/ovpn.key&quot;             redirect-gateway def1        ifconfig 10.4.0.2 10.4.0.1<\/code><\/pre>\n<p>  <\/p>\n<p>\u041e\u0431\u0440\u0430\u0442\u0438\u0442\u0435 \u0432\u043d\u0438\u043c\u0430\u043d\u0438\u0435 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 \u0432 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0435 &quot;secret&quot; \u0434\u043e\u043b\u0436\u0435\u043d \u0431\u044b\u0442\u044c \u043f\u043e\u043b\u043d\u044b\u0439 \u0430\u0434\u0440\u0435\u0441 \u0444\u0430\u0439\u043b\u0430 \u043a\u043b\u044e\u0447\u0430 (&quot;\u0418\u043c\u044f\u041f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f&quot; \u0434\u043e\u043b\u0436\u043d\u043e \u043a\u043e\u043d\u0435\u0447\u043d\u043e \u0431\u044b\u0442\u044c \u0442\u0430\u043a\u0438\u043c \u043a\u0430\u043a \u0432 \u0432\u0430\u0448\u0435\u0439 \u0441\u0438\u0441\u0442\u0435\u043c\u0435), remote \u0443\u043a\u0430\u0437\u044b\u0432\u0430\u0435\u043c \u0430\u0434\u0440\u0435\u0441 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u043d\u0430 Amazon \u0432\u0438\u0434\u0430 35.163.203.49 \u0438\u043b\u0438 ec2-35-163-203-49.us-west-2.compute.amazonaws.com<br \/>  \u0421\u043e\u0445\u0440\u0430\u043d\u044f\u0435\u043c \u0444\u0430\u0439\u043b openvpn.server.conf<\/p>\n<p>  <\/p>\n<p>\u0422\u0435\u043f\u0435\u0440\u044c \u043f\u0440\u043e\u0441\u0442\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0435\u043c OpenVPN \u0432 \u043a\u043e\u043d\u0441\u043e\u043b\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u043e\u0439: <\/p>\n<p>  <\/p>\n<pre><code class=\"bash\">sudo openvpn --config ~\/OpenVPNconf\/openvpn.server.conf<\/code><\/pre>\n<p>  <\/p>\n<p><img decoding=\"async\" src=\"https:\/\/habrastorage.org\/files\/ef3\/cc8\/f57\/ef3cc8f571eb4e4981e955b274c1dd82.png\" alt=\"image\"\/><br \/>  \u0438 \u0437\u0430\u0445\u043e\u0434\u0438\u043c \u043d\u0430 <a href=\"http:\/\/ipecho.net\/plain\">http:\/\/ipecho.net\/plain<\/a> \u2014 \u0442\u0435\u043f\u0435\u0440\u044c \u043e\u043d \u0434\u043e\u043b\u0436\u0435\u043d \u043f\u043e\u043a\u0430\u0437\u0430\u0442\u044c IP \u0430\u0434\u0440\u0435\u0441 \u043d\u0430\u0448\u0435\u0433\u043e \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u043d\u0430 Amazon. \u041c\u043e\u0436\u043d\u043e \u0442\u0430\u043a\u0436\u0435 \u043f\u043e\u043f\u0440\u043e\u0431\u043e\u0432\u0430\u0442\u044c \u0437\u0430\u0439\u0442\u0438 \u043d\u0430 \u0441\u0430\u0439\u0442 \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u043d\u0435\u0434\u043e\u0441\u0442\u0443\u043f\u0435\u043d \u0432 \u0432\u0430\u0448\u0435\u043c \u0440\u0435\u0433\u0438\u043e\u043d\u0435.<\/p>\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:\/\/habrahabr.ru\/post\/315664\/\"> https:\/\/habrahabr.ru\/post\/315664\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Amazon Web Service \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u043b\u044f\u0435\u0442 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u044c \u0431\u0435\u0441\u043f\u043b\u0430\u0442\u043d\u043e\u0433\u043e \u0437\u0430\u043f\u0443\u0441\u043a\u0430 \u0432 \u0442\u0435\u0447\u0435\u043d\u0438\u0435 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0433\u043e \u043f\u0435\u0440\u0438\u043e\u0434\u0430 (12 \u043c\u0435\u0441\u044f\u0446\u0435\u0432) \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u0432 Amazon EC2. \u0422\u0430\u043a\u043e\u0439 \u0441\u0435\u0440\u0432\u0435\u0440 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d \u0434\u043b\u044f VPN (\u0430\u043d\u0433\u043b. Virtual Private Network \u2014 \u0432\u0438\u0440\u0442\u0443\u0430\u043b\u044c\u043d\u0430\u044f \u0447\u0430\u0441\u0442\u043d\u0430\u044f \u0441\u0435\u0442\u044c). \u041f\u0440\u0438 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 \u044d\u0442\u043e\u0439 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0439 \u0441\u0435\u0440\u0432\u0435\u0440 \u0441\u043b\u0443\u0436\u0438\u0442 \u043f\u043e\u0441\u0440\u0435\u0434\u043d\u0438\u043a\u043e\u043c \u043c\u0435\u0436\u0434\u0443 \u0432\u0430\u0448\u0438\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u043e\u043c \u0438 \u0434\u0440\u0443\u0433\u0438\u043c\u0438 \u0441\u0435\u0440\u0432\u0435\u0440\u0430\u043c\u0438 \u0432 \u0418\u043d\u0442\u0435\u0440\u043d\u0435\u0442. <\/p>\n<p>  <\/p>\n<p>\u042d\u0442\u043e \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043f\u043e\u043b\u0435\u0437\u043d\u043e \u0432 \u0441\u043b\u0443\u0447\u0430\u044f\u0445 \u043a\u043e\u0433\u0434\u0430 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0437\u0430\u0439\u0442\u0438 \u043d\u0430 \u0441\u0430\u0439\u0442 \u0432 \u043e\u0431\u0445\u043e\u0434 \u0431\u043b\u043e\u043a\u0438\u0440\u043e\u0432\u043e\u043a (\u0434\u043b\u044f \u0432\u0430\u0448\u0435\u0433\u043e \u043f\u0440\u043e\u0432\u0430\u0439\u0434\u0435\u0440\u0430 \u0432\u044b \u0441\u0432\u044f\u0437\u044b\u0432\u0430\u0435\u0442\u0435\u0441\u044c \u0441 \u0432\u0430\u0448\u0438\u043c VPN \u0441\u0435\u0440\u0432\u0435\u0440\u043e\u043c, \u0430 \u043d\u0435 \u0441 \u0441\u0430\u0439\u0442\u043e\u043c \u0441 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0432\u044b \u0444\u0430\u043a\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0435 \u0434\u0430\u043d\u043d\u044b\u0435), \u0438\u043b\u0438, \u0441\u043a\u0430\u0436\u0435\u043c, \u0438\u043c\u0435\u0442\u044c \u043f\u043e\u0441\u0442\u043e\u044f\u043d\u043d\u044b\u0439 IP \u0441 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u043e\u0441\u0443\u0449\u0435\u0441\u0442\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u044b\u043c \u0441\u0435\u0440\u0432\u0438\u0441\u0430\u043c, \u0438\u043b\u0438 \u0438\u043c\u0435\u0442\u044c IP \u0441\u0432\u044f\u0437\u0430\u043d\u043d\u044b\u0439 \u043d\u0435 \u0441 \u0442\u0435\u043c \u0440\u0435\u0433\u0438\u043e\u043d\u043e\u043c \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0432\u044b \u0444\u0438\u0437\u0438\u0447\u0435\u0441\u043a\u0438 \u043d\u0430\u0445\u043e\u0434\u0438\u0442\u0435\u0441\u044c (\u0441\u0430\u0439\u0442 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u044f\u0435\u0442 \u0437\u0430\u0445\u043e\u0434 \u0441 IP \u0432\u0430\u0448\u0435\u0433\u043e \u0441\u0435\u0440\u0432\u0435\u0440\u0430, \u0430 \u043d\u0435 \u0441 IP \u0432\u0430\u0448\u0435\u0439 \u0440\u0430\u0431\u043e\u0447\u0435\u0439 \u043c\u0430\u0448\u0438\u043d\u044b)<\/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-281214","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/281214","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=281214"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/281214\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=281214"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=281214"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=281214"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}