amazon-linux-2

Nginx on ec2 instance does not serve static files

孤者浪人 提交于 2021-01-27 13:15:52
问题 What was working I have MERN stack dashboard up and running on AWS EC2 instance. Ec2 instance is at ec2...aws.com React app is served on port 5004 . Node app is running on port 5003 . What was changed The problem started when I set up the domain at GoDaddy to forward (with masking) from somebusiness.com to ec2.....aws.com . First, I set up NGINX reverse proxy to serve / as my react app (frontend) and /api as my node app (backend) (you will find nginx code down below later) http://somebusiness

The deployment to Lightsail instances failed because no instances were found for your deployment group

て烟熏妆下的殇ゞ 提交于 2020-12-12 06:16:33
问题 Following from Marci's answer, I went on and tried to deploy from GitHub using the steps he mentions (adapting the region) but I'm getting The deployment failed because no instances were found for your deployment group. Check your deployment group settings to make sure the tags for your Amazon EC2 instances or Auto Scaling groups correctly identify the instances you want to deploy to, and then try again. According to Gabriel in 2017 Lightsail is intended for smaller projects and doesn't

The deployment to Lightsail instances failed because no instances were found for your deployment group

旧街凉风 提交于 2020-12-12 06:15:31
问题 Following from Marci's answer, I went on and tried to deploy from GitHub using the steps he mentions (adapting the region) but I'm getting The deployment failed because no instances were found for your deployment group. Check your deployment group settings to make sure the tags for your Amazon EC2 instances or Auto Scaling groups correctly identify the instances you want to deploy to, and then try again. According to Gabriel in 2017 Lightsail is intended for smaller projects and doesn't

How to install NGINX on AWS EC2 Linux 2

一世执手 提交于 2020-08-26 20:00:29
问题 I'm new to AWS and trying to understand which version of NGINX I should be installing on my instance. I've found multiple options; Via EPEL as the blog entry Amazon's own (?) version as this answer The 2016 NGINX official tutorial On my development environment (Centos VM) I used sudo yum install nginx . Having tried the EPEL route I don't get the same set up, in particular sites enabled/available is not created as part of the setup. I want to use nginxconfig.io which requires those. Which

Getting “npm ERR! code ELIFECYCLE npm ERR! errno 126” while running npm install

泪湿孤枕 提交于 2020-03-05 03:32:30
问题 I am trying to run npm install on my server and getting this error. > node-cron@2.0.3 postinstall /home/workspace/AgreementCancellationProd/retrymechanism/node_modules/node-cron > opencollective-postinstall /usr/bin/env: node: Permission denied npm WARN retrymechanism@1.0.0 No description npm WARN retrymechanism@1.0.0 No repository field. npm ERR! code ELIFECYCLE npm ERR! errno 126 npm ERR! node-cron@2.0.3 postinstall: `opencollective-postinstall` npm ERR! Exit status 126 npm ERR! npm ERR!

Updating Lambda function to new runtime. Why is cURL no longer working in Node 10 on AWS Lambda?

冷暖自知 提交于 2020-01-16 12:00:09
问题 This is the line in my Lambda function that's raising an error: // running in Node 8 const { execSync } = require('child_process'); execSync('curl https://github.com'); I'm trying to upgrade my Lambda function from Node 8 to Node 10 or Node 12, since Node 8 on Lambda is being deprecated at the end of December, 2019 (so I won't be able to update it). However, when I dig into my CloudWatch logs I'm seeing the following error: bin/sh: curl: command not found And when I update my Lambda function