Home  >  Q&A  >  body text

How to make nginx point different domain names to different directories of the same IP

Several domain names share a common host and point to different project instances (different directories)? Use nginx!

漂亮男人漂亮男人2712 days ago686

reply all(1)I'll reply

  • 为情所困

    为情所困2017-05-16 17:30:56

    Add virtual machine configuration in nginx/conf/vhosts/ and set different root directories and host names. Then include the virtual host configuration file you created in nginx/conf/nginx.conf.

    Then restart nginx.

    reply
    0
  • Cancelreply