Join 1M+ other developers and:
- Get help and share knowledge in Q&A
- Subscribe to topics of interest
- Get courses & tools that help you grow as a developer or small business owner
How to setup nginx with subdomain only
All of this is very new to me, I’m a junior frontend developer trying to learn more about well everything… and I’ve gotten a bit stuck with nginx as I’ve never used it before.
I have been following tutorials to setup Strapi CMS in a DO droplet and got to the stage of setting up nginx using this tutorial:
I’ve completed everything upto and including step 4, but step 5 is where I am lost.
When I go to my ip, lets say 184.108.40.206 I get the nginx page, when I go to 220.127.116.11:1337 I get the strapi page and when I go to 18.104.22.168:1337/admin/ I get the log in page.
I have my domain in cloudflare, and have made a sub-domain admin.mydomain.com which takes me to nginx homepage, but admin.mydomain.com:1337/admin and admin.mydomain.com/admin do nothing. What I am wanting to do, is have admin.mydomain.com take me to 22.214.171.124:1337/admin/.
However, I don’t understand the next steps and have searched the questions in here but not found something that helps me. Sorry if this has been asked and I just haven’t been able to find it.
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.×