on 1b3790f help sign in
urbit.org/docs/using/setup.md
228 lines 6.2 kB history raw
1---
2navhome: /docs/
3navuptwo: true
4next: true
5sort: 2
6title: Setup
7---
9# Getting started
11On disk your urbit is an append-only log and a checkpoint. Or, in
12simpler terms, a directory where we keep your urbit’s state. We call
13this a _pier_.
15## Initialize
17To create an urbit, we need an identity. This identity is both a network
18address and a memorable name.
20You are probably creating one of two kinds of urbit: a 32-bit _planet_
21or a 128-bit _comet_. For a quick terminology guide and high-level
22refresher, refer to this [handy reference sheet](../../about/glossary/).
24If you have an Urbit invitation, you'll have a planet like
25`~sampel-palnet` and `~sampel-sompel-simpel-sampel`. To create your
26pier:
28```
29$ urbit -w sampel-palnet -t sampel-sompel-simpel-sampel
30```
32This will create a directory `sampel-palnet/` and begin building your
33urbit. This may take a few minutes.
35> If you are booting a star, the process is the same as above, with your
36> respective star name and ticket.
38> If you are booting a galaxy, see
39> [this Fora post](https://urbit.org/fora/posts/~2016.8.17..21.04.11..1450~/).
41If you do not have a ticket, you can still make a _comet_, a wild urbit
42drifting through cyberspace. Pick your own directory name, it doesn't
43matter:
45```
46$ urbit -c mycomet
47```
49This will create the directory `mycomet/` and generate a 128-bit
50identity for your urbit.
52## Orientation
54After about five to ten minutes, when your urbit is finished booting,
55you should see a `dojo>` prompt. Welcome!
57By default your urbit is quite bare-bones. Let's stroll through what's
58already running:
60### Shell — Dojo
62The command prompt in front of you is a simple shell and Hoon REPL.
63Let's make sure it works:
65```
66~your-urbit:dojo> (add 2 2)
67```
69Should produce:
71```
72> (add 2 2)
74```
76Good.
79### Messaging — Talk
81Use `ctrl-x` to change your prompt. Let's join the main Urbit chat
82channel, `/urbit-meta`:
84```
85~your-urbit:talk[] ;join /urbit-meta
86```
88Talk is stateful, so your urbit will download a backlog.
89`/urbit-meta` is the place to ask questions, get help, talk about
90anything Urbit-related, and meet everyone on here.
92### Web — Tree
94Your Urbit is also accessible through its own web interface. If you're
95running Urbit locally on your own machine, try opening:
97```
98http://localhost:8080/~~/
99```
101in your favorite browser.
103Or if you're running your urbit on a cloud instance with a static IP
104address (which we recommend!), something like `212.131.240.20`, assuming
105you've opened up the HTTP/HTTPS ports that Urbit uses (`8080` and `8443`
106by default), try opening:
109```
110http://212.131.240.20:8080/~~/
111```
113This way, if you keep your urbit running securely in the cloud (usually
114in a [`screen`](https://www.gnu.org/software/screen/) or
115[`tmux`](https://github.com/tmux/tmux/wiki) session), you can always
116access your urbit's web interface in any browser on any device, so long
117as you have your password on hand.
119The `/~~/` in the URL will redirect you to a login page, which was
120generated by Tree, the basic Urbit web interface. The page will tell
121you to run the `+code` generator (an Urbit functional shell script) in
122your Dojo to get your password. Copy and paste that into your password
123input box and hit Enter. After loading, you'll find yourself redirected
124to your home page, authenticated, where you can then use the navigation
125bar at the top of the page to visit your Talk web interface and static
126files.
128You can also access your urbit through
129`https://your-urbit.urbit.org/~~/`. Note that this latter approach is
130slower for the time being because we proxy over the Urbit network, Ames,
131but a better, faster solution for this is in the works.
133### Filesystem — Clay
135Clay, the Urbit filesystem, isn't mounted to Unix by default. Switch
136to the Dojo prompt and run:
138```
139~your-urbit:dojo> |mount %
140```
142This should produce:
144```
145> |mount %
146>=
147```
149which indicates the command was processed.
151`|mount %` will cause a `home/` directory to appear inside your pier
152folder. Changes to these files are automatically synced into your urbit.
154<br />
156Here are a few other things you can do to get up and running:
158### Discussion — Fora
160Fora is the place for long-form Urbit discussion. It's hosted on an
161Urbit and served over HTTP via Eyre, Urbit's web server.
163Head on over to:
165```
166https://fora.urbit.org/~~/
167```
169Like on your own web interface, you'll be redirected to a login page and
170prompted to run `+code` in your Dojo to retrive your password and log
171in.
173After loading, you'll get redirected to the Fora home page where you
174can post and comment authenticated as your ship name. Like Talk, Fora
175is a great place to ask questions, get help, chat about anything Urbit, and
176see what's going on.
178### Docs
180We host our docs on `urbit.org`, but it's faster to view them locally
181through your own ship's web interface. So we also host the docs on a
182Clay desk on one of our `urbit.org` planets, which you can merge and
183sync onto your live ship over the network.
185Run in your Dojo:
187```
188~your-urbit:dojo> |sync %home ~ladnub-lorwyn %docs
189```
191Depending on network traffic, this initial merge and sync could take
192anywhere between thirty seconds to a few minutes.
194Upon a successful sync you'll see the output:
196```
197sync succeeded from %docs on ~ladnub-lorwyn to %home
198```
200If for some reason that doesn't work, head to the
201[urbit/docs](https://github.com/urbit/docs) repo and follow the local
202install steps.
204Otherwise, your docs are now live, and you can view them at:
206```
207http://localhost:8080/~~/docs
208```
210We'll update our planet's desk with new doc changes as they happen. You
211should get sync updates automatically through Clay over Ames.
213### Examples
215Similarly, we host some Urbit examples on our same `urbit.org` planet as
216above. Head to our [examples repo](https://github.com/urbit/examples) for
217full instructions if you're interested, though you may want to start
218with the [Urbyte](../../urbyte/), [Nock](../../nock/),
219[Hoon](../../hoon/) or [Arvo](../../arvo/) sections so you can really
220understand the example code.
222## Learn more
224If you're eager to get started programming you're ready to head over to
225[the Hoon section](../../hoon/mission/).
227To learn more about using the system, let's keep going: