# 正在端口 4000 创建服务器

**URL:** https://meta.discourse.org/t/creating-server-at-port-4000/122641
**Category:** Development
**Created:** [2019年七月11日 10:11 UTC](https://meta.discourse.org/t/creating-server-at-port-4000/122641 "2019-07-11T10:11:37Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Vishal\_Kaushik](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vishal_kaushik/32/140452_2.png) [@Vishal\_Kaushik](https://meta.discourse.org/u/Vishal_Kaushik)
#### Post date: [2019年七月11日 10:11 UTC](https://meta.discourse.org/t/creating-server-at-port-4000/122641/1 "2019-07-11T10:11:37Z")

</div>

如何在端口 4000 上创建新服务器，因为服务器默认在端口 3000 自动创建。

---

<div class="post-metadata">

### Author: ![rishabh](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/rishabh/32/179446_2.png) [@rishabh](https://meta.discourse.org/u/rishabh)
#### Post date: [2019年七月11日 10:18 UTC](https://meta.discourse.org/t/creating-server-at-port-4000/122641/2 "2019-07-11T10:18:58Z")

</div>

服务器可以通过 `-p` 选项在其他端口上运行，因此运行 `rails s -p 4000` 即可实现。
