{"id":438,"date":"2015-01-05T20:49:16","date_gmt":"2015-01-05T11:49:16","guid":{"rendered":"http:\/\/www.typea.info\/blog\/index.php\/2015\/01\/05\/aws_elastic_beanstalk_django_centos65_pydev3_tips\/"},"modified":"2015-01-05T20:49:16","modified_gmt":"2015-01-05T11:49:16","slug":"aws_elastic_beanstalk_django_centos65_pydev3_tips","status":"publish","type":"post","link":"https:\/\/www.typea.info\/blog\/index.php\/2015\/01\/05\/aws_elastic_beanstalk_django_centos65_pydev3_tips\/","title":{"rendered":"AWS Elastic Beanstalk Django \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u74b0\u5883\u3092 CentOS6.5 \u4e0a\u306b PyDev\u3092\u4f7f\u3063\u3066\u69cb\u7bc9\u3059\u308b(3) (TIPS) \u30ed\u30b0\u306e\u78ba\u8a8d\u3068\u30c7\u30d7\u30ed\u30a4\u7d50\u679c\u306e\u78ba\u8a8d"},"content":{"rendered":"<ul>\n<li><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/01\/05\/aws_elastic_beanstalk_django_centos65_pydev1_django\" target=\"_blank\">(1) Django\u8d77\u52d5\u307e\u3067<\/a><\/li>\n<li><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/01\/05\/aws_elastic_beanstalk_django_centos65_pydev2_tips_sshrds\" target=\"_blank\">(2) (TIPS) SSH\u3001RDS\u3078\u306e\u63a5\u7d9a<\/a><\/li>\n<li><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/01\/05\/aws_elastic_beanstalk_django_centos65_pydev3_tips\" target=\"_blank\">(3) (TIPS) \u30ed\u30b0\u306e\u78ba\u8a8d\u3068\u30c7\u30d7\u30ed\u30a4\u7d50\u679c\u306e\u78ba\u8a8d<\/a><\/li>\n<li><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/01\/05\/aws_elastic_beanstalk_django_centos65_pydev4\" target=\"_blank\">(4) \u3044\u304f\u3064\u304b\u306e\u30c8\u30e9\u30d6\u30eb\u30b7\u30e5\u30fc\u30c8<\/a><\/li>\n<li><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/01\/05\/aws_elastic_beanstalk_django_centos65_pydev5\" target=\"_blank\">(5) \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306e\u4f5c\u6210<\/a><\/li>\n<li><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/01\/06\/aws_elastic_beanstalk_django_centos65_pydev6_createadmin\" target=\"_blank\">(6) createadmin \u30b9\u30af\u30ea\u30d7\u30c8\u306e\u5b9f\u884c\u306e\u30c8\u30e9\u30d6\u30eb\u30b7\u30e5\u30fc\u30c8<\/a><\/li>\n<li><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/01\/31\/aws_elastic_beanstalk_django_7_ipdns\" target=\"_blank\">(7) \u9759\u7684IP\u30a2\u30c9\u30ec\u30b9\u306e\u8a2d\u5b9a\u3068\u30c9\u30e1\u30a4\u30f3\u306e\u53d6\u5f97\u3068DNS\u306e\u8a2d\u5b9a<\/a><\/li>\n<li><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/05\/20\/aws_elastic_beanstalk_rds_utf-8\" target=\"_blank\">AWS Elastic Beanstalk RDS \u306e\u6587\u5b57\u30b3\u30fc\u30c9\u3092utf-8\u306b\u8a2d\u5b9a\u3057\u306a\u304a\u3059<\/a><\/li>\n<li><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/07\/02\/djangoaws_elasticbeanstalk\" target=\"_blank\">Django\u3067\u30d0\u30c3\u30c1\u51e6\u7406\u3092\u884c\u3046(AWS Elasticbeanstalk)<\/a><\/li>\n<\/ul>\n<p><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/01\/05\/aws_elastic_beanstalk_django_centos65_pydev1_django\">AWS Elastic Beanstalk Django \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u74b0\u5883\u3092 CentOS6.5 \u4e0a\u306b PyDev\u3092\u4f7f\u3063\u3066\u69cb\u7bc9\u3059\u308b(1) Django\u8d77\u52d5\u307e\u3067<\/a><\/p>\n<p>\u3067\u958b\u767a\u74b0\u5883\u3092\u69cb\u7bc9\u3057\u305f\u3002<\/p>\n<p>\u30ed\u30b0\u306e\u78ba\u8a8d\u65b9\u6cd5\u3068\u30c7\u30d7\u30ed\u30a4\u7d50\u679c\u306e\u78ba\u8a8d\u65b9\u6cd5\u3092\u4ee5\u4e0b\u306b\u8a18\u3059\u3002<\/p>\n<h2>1.\u30ed\u30b0\u306e\u78ba\u8a8d<\/h2>\n<h3>1.1 \u30de\u30cd\u30b8\u30e1\u30f3\u30c8\u30b3\u30f3\u30bd\u30fc\u30eb\u304b\u3089\u78ba\u8a8d<\/h3>\n<p>AWS\u30de\u30cd\u30b8\u30e1\u30f3\u30c8\u30b3\u30f3\u30bd\u30fc\u30eb\u304b\u3089\u3001Elastic Beanstalk  \u30b5\u30fc\u30d3\u30b9 &gt; \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u3092\u305f\u3069\u308b\u3068\u3001Recent  Event \u30ea\u30b9\u30c8\u306b\u3001\u6700\u8fd1\u306e\u64cd\u4f5c\u7d50\u679c\u306e\u30b5\u30de\u30ea\u30fc\u304c\u5f97\u3089\u308c\u308b\u3002<\/p>\n<p><a href=\"https:\/\/www.typea.info\/blog\/wp-content\/uploads\/image\/AWS-Elastic-Beanstalk-Dj.5--PyDev3-TIPS-_11F99\/eb_event_log.jpg\"><img loading=\"lazy\" decoding=\"async\" title=\"eb_event_log\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-width: 0px;\" border=\"0\" alt=\"eb_event_log\" src=\"https:\/\/www.typea.info\/blog\/wp-content\/uploads\/image\/AWS-Elastic-Beanstalk-Dj.5--PyDev3-TIPS-_11F99\/eb_event_log_thumb.jpg\" width=\"378\" height=\"169\" \/><\/a><\/p>\n<p>\u5de6\u5074\u306e\u30c0\u30c3\u30b7\u30e5\u30dc\u30fc\u30c9\u304b\u3089\u3001Logs \u3092\u9078\u629e\u3057\u3001<\/p>\n<p><a href=\"https:\/\/www.typea.info\/blog\/wp-content\/uploads\/image\/AWS-Elastic-Beanstalk-Dj.5--PyDev3-TIPS-_11F99\/eb_logs.jpg\"><img loading=\"lazy\" decoding=\"async\" title=\"eb_logs\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-width: 0px;\" border=\"0\" alt=\"eb_logs\" src=\"https:\/\/www.typea.info\/blog\/wp-content\/uploads\/image\/AWS-Elastic-Beanstalk-Dj.5--PyDev3-TIPS-_11F99\/eb_logs_thumb.jpg\" width=\"257\" height=\"153\" \/><\/a><\/p>\n<p>Reqest Logs \u30d7\u30eb\u30c0\u30a6\u30f3\u3067\u62bd\u51fa\u6761\u4ef6\u3092\u8a2d\u5b9a\u3059\u308b\u3068\u3001Download \u7528\u306e\u30d5\u30a1\u30a4\u30eb\u304c\u751f\u6210\u3055\u308c\u308b\u3002<\/p>\n<p><a href=\"https:\/\/www.typea.info\/blog\/wp-content\/uploads\/image\/AWS-Elastic-Beanstalk-Dj.5--PyDev3-TIPS-_11F99\/eb_logs_create.jpg\"><img loading=\"lazy\" decoding=\"async\" title=\"eb_logs_create\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-width: 0px;\" border=\"0\" alt=\"eb_logs_create\" src=\"https:\/\/www.typea.info\/blog\/wp-content\/uploads\/image\/AWS-Elastic-Beanstalk-Dj.5--PyDev3-TIPS-_11F99\/eb_logs_create_thumb.jpg\" width=\"407\" height=\"91\" \/><\/a><\/p>\n<p>Download \u3092\u9078\u629e\u3059\u308b\u3068\u3001\u30ed\u30b0\u304c\u8868\u793a\u3055\u308c\u308b\u3002<\/p>\n<p><a href=\"https:\/\/www.typea.info\/blog\/wp-content\/uploads\/image\/AWS-Elastic-Beanstalk-Dj.5--PyDev3-TIPS-_11F99\/eb_logs_retrieve.jpg\"><img loading=\"lazy\" decoding=\"async\" title=\"eb_logs_retrieve\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-width: 0px;\" border=\"0\" alt=\"eb_logs_retrieve\" src=\"https:\/\/www.typea.info\/blog\/wp-content\/uploads\/image\/AWS-Elastic-Beanstalk-Dj.5--PyDev3-TIPS-_11F99\/eb_logs_retrieve_thumb.jpg\" width=\"297\" height=\"166\" \/><\/a><\/p>\n<h3>1.2 \u30b5\u30fc\u30d0\u30fc\u304b\u3089\u76f4\u63a5\u78ba\u8a8d<\/h3>\n<p><a href=\"https:\/\/www.typea.info\/blog\/index.php\/2015\/01\/05\/aws_elastic_beanstalk_django_centos65_pydev2_tips_sshrds\">\u30b5\u30fc\u30d0\u3078SSH\u3067\u63a5\u7d9a\u3059\u308b<\/a><\/p>\n<p>\/var\/log \u306b\u5404\u7a2e\u30ed\u30b0\u304c\u5b58\u5728\u3059\u308b\u3002<\/p>\n<pre class=\"prettyprint linenums\">[ec2-user@ip-172-31-0-73 ~]$ cd \/var\/log\r\n[ec2-user@ip-172-31-0-73 log]$ ls\r\nboot.log      cloud-init.log         eb-activity.log          eb-publish-logs.log        maillog   wtmp\r\ncfn-hup.log   cloud-init-output.log  eb-cfn-init-call.log     eb-tools.log               messages  yum.log\r\ncfn-init.log  cron                   eb-cfn-init.log          eb-version-deployment.log  secure\r\ncfn-wire.log  dmesg                  eb-commandprocessor.log  httpd                      spooler<\/pre>\n<p>tail -f \u3092\u4f7f\u3048\u3070\u3001git aws.push \u3057\u305f\u3068\u304d\u306a\u3069\u306b\u9032\u6357\u3092\u30ea\u30a2\u30eb\u30bf\u30a4\u30e0\u306b\u78ba\u8a8d\u51fa\u6765\u308b\u3002<\/p>\n<pre class=\"prettyprint linenums\">[ec2-user@ip-172-31-0-73 log]$ tail f eb-activity.log \r\ntail: cannot open 'f' for reading: No such file or directory\r\n==&gt; eb-activity.log &lt;==\r\n[2015-01-05T11:32:57.678Z] INFO  [28789] - [CMD-TailLogs\/AddonsBefore] : Completed activity.\r\n[2015-01-05T11:32:57.678Z] INFO  [28789] - [CMD-TailLogs\/TailLogs] : Starting activity...\r\n[2015-01-05T11:32:57.678Z] INFO  [28789] - [CMD-TailLogs\/TailLogs\/TailLogs] : Starting activity...\r\n[2015-01-05T11:32:58.075Z] INFO  [28789] - [CMD-TailLogs\/TailLogs\/TailLogs] : Completed activity.\r\n[2015-01-05T11:32:58.075Z] INFO  [28789] - [CMD-TailLogs\/TailLogs] : Completed activity. Result:\r\n  Command CMD-TailLogs stage 0 completed.\r\n[2015-01-05T11:32:58.076Z] INFO  [28789] - [CMD-TailLogs\/AddonsAfter] : Starting activity...\r\n[2015-01-05T11:32:58.076Z] INFO  [28789] - [CMD-TailLogs\/AddonsAfter] : Completed activity.\r\n[2015-01-05T11:32:58.076Z] INFO  [28789] - [CMD-TailLogs] : Completed activity. Result:\r\n  Command CMD-TailLogs succeeded.<\/pre>\n<h2>2.\u30c7\u30d7\u30ed\u30a4\u7d50\u679c<\/h2>\n<p>\/opt\/python\/current\/app \u306b\u30c7\u30d7\u30ed\u30a4\u3055\u308c\u305f\u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u304c\u5c55\u958b\u3055\u308c\u308b\u3002<\/p>\n<pre class=\"prettyprint linenums\">[ec2-user@ip-172-31-0-73 log]$ cd \/opt\/python\/current\/app\r\n[ec2-user@ip-172-31-0-73 app]$ ls -a\r\n.  ..  manage.py  phrase  .project  .pydevproject  requirements.txt<\/pre>\n<p>\u30c7\u30d7\u30ed\u30a4\u3059\u308b\u30d5\u30a1\u30a4\u30eb\u306f\u3001\u5c55\u958b\u3055\u308c\u308b\u524d\u306b\u3001zip \u3067\u56fa\u3081\u3089\u308c\u3001S3\u306b\u4fdd\u5b58\u3055\u308c\u308b\u3002<\/p>\n<p><a href=\"https:\/\/www.typea.info\/blog\/wp-content\/uploads\/image\/AWS-Elastic-Beanstalk-Dj.5--PyDev3-TIPS-_11F99\/s3_resource.jpg\"><img loading=\"lazy\" decoding=\"async\" title=\"s3_resource\" style=\"background-image: none; padding-top: 0px; padding-left: 0px; display: inline; padding-right: 0px; border-width: 0px;\" border=\"0\" alt=\"s3_resource\" src=\"https:\/\/www.typea.info\/blog\/wp-content\/uploads\/image\/AWS-Elastic-Beanstalk-Dj.5--PyDev3-TIPS-_11F99\/s3_resource_thumb.jpg\" width=\"329\" height=\"248\" \/><\/a><\/p>\n<p>\n<iframe loading=\"lazy\" width=\"320\" height=\"240\" style=\"height: 240px; width: 120px;\" marginheight=\"0\" src=\"http:\/\/rcm-fe.amazon-adsystem.com\/e\/cm?lt1=_blank&amp;bc1=FFFFFF&amp;IS2=1&amp;bg1=FFFFFF&amp;fc1=000000&amp;lc1=0000FF&amp;t=typea09-22&amp;o=9&amp;p=8&amp;l=as4&amp;m=amazon&amp;f=ifr&amp;ref=ss_til&amp;asins=4873115817\" frameborder=\"0\" marginwidth=\"0\" scrolling=\"no\"><\/iframe><\/p>\n","protected":false},"excerpt":{"rendered":"<p>(1) Django\u8d77\u52d5\u307e\u3067 (2) (TIPS) SSH\u3001RDS\u3078\u306e\u63a5\u7d9a (3) (TIPS) \u30ed\u30b0\u306e\u78ba\u8a8d\u3068\u30c7\u30d7\u30ed\u30a4\u7d50\u679c\u306e\u78ba\u8a8d (4) \u3044\u304f\u3064\u304b\u306e\u30c8\u30e9\u30d6\u30eb\u30b7\u30e5\u30fc\u30c8 (5) \u30a2\u30d7\u30ea\u30b1\u30fc\u30b7\u30e7\u30f3\u306e\u4f5c\u6210 (6) createa [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"sns_share_botton_hide":"","vkExUnit_sns_title":"","_vk_print_noindex":"","sitemap_hide":"","_veu_custom_css":"","veu_display_promotion_alert":"","vkexunit_cta_each_option":"","footnotes":""},"categories":[79,80],"tags":[],"class_list":["post-438","post","type-post","status-publish","format-standard","hentry","category-aws-ec2","category-aws-elastic-beanstalk"],"veu_head_title_object":{"title":"","add_site_title":""},"_links":{"self":[{"href":"https:\/\/www.typea.info\/blog\/index.php\/wp-json\/wp\/v2\/posts\/438","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.typea.info\/blog\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.typea.info\/blog\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.typea.info\/blog\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.typea.info\/blog\/index.php\/wp-json\/wp\/v2\/comments?post=438"}],"version-history":[{"count":0,"href":"https:\/\/www.typea.info\/blog\/index.php\/wp-json\/wp\/v2\/posts\/438\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.typea.info\/blog\/index.php\/wp-json\/wp\/v2\/media?parent=438"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.typea.info\/blog\/index.php\/wp-json\/wp\/v2\/categories?post=438"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.typea.info\/blog\/index.php\/wp-json\/wp\/v2\/tags?post=438"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}