I have an ec2 instance. and I use this instance for serving Nodejs applications with GitHub action. everything is working as expected. but sometimes like after 1/2 days, the instance is not reachable by anything. it's showing an offline flag on the GitHub action tab. But, in the AWS ec2 console. it's showing running. All stats look normal. I actually have no idea why this behaves like this.
every time this happened, I have to stop and start the instance manually to up and run my server.
I actually think, there may be resource limitations, therefore the instance is hanging. but after I upgrade my instance type to t2.xlarge it still happens.