Dancing with Nginx
So, you're on Nginx. That alone is an awesome move. As long as you're sure that everything you need is within Nginx, no need to load up on features that you won't use (from Apache).
Some of the things important to keep in mind about Nginx:
usual Nginx configuration file path:
usual Nginx access log file path
usual Nginx error log file path
sudo service nginx start
sudo service nginx stop
sudo service nginx reload
Because I encountered these problems, here are some tips I learned:
If you have this directive:
just make sure that you remove text/html in the values you provide.
gzip_types already include text/html by default.
If you encounter any errors on binding to any ports, such as this:
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
make sure that you kill all those connected to the port in question. You can either do:
sudo fuser -k 80/tcp
sudo killall nginx
before you start/restart nginx again.
When deploying a rails app, put
environment with whatever you call your environment: [development, staging, test, production, etc]
- and my own debugging experience
I turn tech ideas into websites using Ruby. I'm a budding Buddhist practitioner, passionate about health & fitness, a certified yoga teacher, and a cat fanatic!
- blood pressure
- live book signing
- healthy living
- lowering blood pressure
- new year
- quotes to live by
- travelers notebook
- Monday Motivation
- himalayan salt lamp
- life tips
- digital ocean
- open letter
- tech talks
- song lyrics
- life lessons
- short story
- living life
- my Nyey
- new normal
- jump rope
- two-wheel journey
- planner girl
- mental health
I'm sharing with you P150 gift from GoFutureFresh! Click here to accept my gift.