SPA Deployment

I just deployed a MEAN stack app. It went pretty smoothly, but required some manual steps I’ll need to work out how to automate. I also need to add some security and set up HTTPS. That should be pretty simple with Let’s Encrypt, but I have to make sure communication between the frontend and backend apps isn’t interrupted.

I’m hosting both on my regular server at separate subdomains. For the Express backend, I’m using passenger, which is already set up for my Rails apps. I hadn’t installed NVM yet, and I ran into some issues with the Angular CLI when I tried to install it with sudo. I found a configuration for serving Angular from an Apache VirtualHost on StackOverflow. That seems to work pretty well, but in this case I’m not actually using any routes.

I’m using a free sandbox on Mongo Atlas for the database. It took some effort to find a connection string that worked. It should be reliable enough for the small amount of data I’ll be storing.

This is another app I’m not sure will ever be marketable for public use, but if I wanted to it would need some polish and additional security features. For now it will work well enough to share with some friends.

Leave a Reply

Your email address will not be published.