amazon-elastic-beanstalk

separate environment config elastic beanstalk

梦想与她 提交于 2021-01-27 18:58:31
问题 I'm creating a rails app with both web and worker tier in elastic beanstalk. It's normal to start up web environment with ELB settings inside ebextensions. But I cannot startup worker environment because it doesn't have ELB. Is there any way to separate ebextensions for each environments without creating another branch for this? 回答1: Refer to this link second answer https://forums.aws.amazon.com/message.jspa?messageID=685803 来源: https://stackoverflow.com/questions/42435032/separate

Boto intermittent “unable to load credentials” with EC2 IAM roles

£可爱£侵袭症+ 提交于 2021-01-27 14:18:26
问题 I use an Elastic Beanstalk environment for deploying a web application, and I've set up an IAM role for the instances the application will run on. Everything works flawlessy 99.99% of the time, however intermittently I will see errors in our logs with request failures showing botocore errors like the following: File "/opt/python/run/venv/local/lib/python3.6/site-packages/boto3/resources/factory.py", line 339, in property_loader self.load() File "/opt/python/run/venv/local/lib/python3.6/site

executing commands in AWS ebextensions

允我心安 提交于 2021-01-27 07:25:45
问题 I receive the following error while trying to upload my instance in aws elasticbeanstalk: The configuration file .ebextensions/setup.config in application version t5 contains invalid YAML or JSON. YAML exception: while scanning a quoted scalar in "<reader>", line 3, column 18: command: "aws s3 cp s3:elasticbeanstalk-u ... ^ found unexpected end of stream in "<reader>", line 5, column 1: ^ , JSON exception: Unexpected character (c) at position 0.. Update the configuration file. Below is what

executing commands in AWS ebextensions

会有一股神秘感。 提交于 2021-01-27 07:23:36
问题 I receive the following error while trying to upload my instance in aws elasticbeanstalk: The configuration file .ebextensions/setup.config in application version t5 contains invalid YAML or JSON. YAML exception: while scanning a quoted scalar in "<reader>", line 3, column 18: command: "aws s3 cp s3:elasticbeanstalk-u ... ^ found unexpected end of stream in "<reader>", line 5, column 1: ^ , JSON exception: Unexpected character (c) at position 0.. Update the configuration file. Below is what

AWS Elastic Beanstalk + Laravel, Nginx Configuration

谁说胖子不能爱 提交于 2021-01-27 07:22:33
问题 Recently AWS started distributing the Elastic Beanstalk PHP environment with Amazon Linux 2, which has dropped apache in favor of Nginx, I've been trying to correctly configure my Laravel project to work, I used to just have to add some .htaccess configuration and that was it, on Nginx I can't seem to figure out how to make my app to work, my first issue was the reverse proxy port, which I fixed by setting PORT environment variable to 80, but when I try to access any route from the URL aside

Laravel Scheduling Task on AWS is not working

ⅰ亾dé卋堺 提交于 2021-01-27 06:41:22
问题 I am deploying my Laravel application to ElasticBeanstalk environment. I am trying to run a command in the Scheduling Task on the server. But it is not working. This is what I have done. I schedule my command in the Kernel.php file as follow. $schedule->command('counter:update')->everyMinute()->onOneServer(); I am using Redis as my cache driver and it is working. Then I tried two different approaches. First Approach: Using Laravel AWS Worker package , https://packagist.org/packages/dusterio

Laravel Scheduling Task on AWS is not working

╄→尐↘猪︶ㄣ 提交于 2021-01-27 06:40:19
问题 I am deploying my Laravel application to ElasticBeanstalk environment. I am trying to run a command in the Scheduling Task on the server. But it is not working. This is what I have done. I schedule my command in the Kernel.php file as follow. $schedule->command('counter:update')->everyMinute()->onOneServer(); I am using Redis as my cache driver and it is working. Then I tried two different approaches. First Approach: Using Laravel AWS Worker package , https://packagist.org/packages/dusterio

AWS Elastic Beanstalk - Flask App Cannot Import Custom Module

我只是一个虾纸丫 提交于 2021-01-27 06:33:19
问题 I am trying to host a Flask app on AWS Elastic Beanstalk in Python 3.6, but no matter what I try, the application's url leads to a 500: Internal Server Error. The structure of my app is as follows: myApp: -application.py -mytransformers.py -requirements.txt I took a look at the logs, and the separate python script I need that contains custom Scikit-learn transformers (mytransformers.py) cannot be found by wsgi: AttributeError: Can't get attribute 'MyTransformer' on <module '__main__' (built

AWS Elastic Beanstalk - Flask App Cannot Import Custom Module

情到浓时终转凉″ 提交于 2021-01-27 06:32:12
问题 I am trying to host a Flask app on AWS Elastic Beanstalk in Python 3.6, but no matter what I try, the application's url leads to a 500: Internal Server Error. The structure of my app is as follows: myApp: -application.py -mytransformers.py -requirements.txt I took a look at the logs, and the separate python script I need that contains custom Scikit-learn transformers (mytransformers.py) cannot be found by wsgi: AttributeError: Can't get attribute 'MyTransformer' on <module '__main__' (built

Disable health-check logging in AWS ELB Django Application

放肆的年华 提交于 2021-01-27 05:12:42
问题 I have a Django application running on aws-elastic-beanstalk. I try to disable the logs caused by my health-checks. The health-checks are already routed to a seperate page. Elastic-beanstalk uses Apache + mod_wsgi. The following code is a solution that works with nginx servers. I try to create something similar for apache. I found out that conditional Logs are probably the appropriate way to do it with an Apache Server. My directory struture looks like the following /etc/httpd/ - conf - httpd