Meteor.js deploy to “example.com” or “www.example.com”?

前端 未结 4 1832
鱼传尺愫
鱼传尺愫 2020-12-04 07:18

I recently deployed a meteor app using the following command:

$ meteor deploy example.com

and later (thinking that it was the same) using t

4条回答
  •  醉梦人生
    2020-12-04 07:30

    When people go to your page, do you want them to see mydomain.com or www.mydomain.com?

    If it's mydomain.com, then you want to set your DNS zone file with an A record for the domain that points to the IP of origin.meteor.com

    If it's www.mydomain.com, then you want to set your DNS zone file with a CNAME for the subdomain "www" that points to origin.meteor.com

    Then, you want to set "domain forwarding" from one of those choices to the other. For example, I've set up http://playlistparty.net to forward to http://www.playlistparty.net.

    After this, you just run:

    meteor deploy www.playlistparty.net
    


    You can delete the deployment you won't be using with the --delete option.

    meteor deploy www.playlistparty.net --delete
    

提交回复
热议问题