简体   繁体   中英

Can I run more than one app on an instance of Amazon EC2?

I admit the answer is probably obvious, but I'm new to server administration, and despite Googling and reading through Amazon's docs I can't seem to figure this out.

Can I run more than one Application on one instance of EC2? Maybe on separate ports? Is it more security prudent to run a single application per instance? What about a Database, can I run CouchDB along with Node on one EC2 instance?

Yes, you can run more than on application per instance. You could potentially run them on different ports if you don't mind appending a port number to your http urls. yourdomain.com/ & yourdomain.com:8080 .

There's nothing wrong with that approach, but you can also run virtual domains in a single Node.js instance using the vhost directive.

Of you can put an Nginx server in front and reverse proxy to two or more server processes in the background so you can mix and match servers like Node.js and Apache/PHP all on the same EC2 instance.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM