You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: misc/README.md
-124Lines changed: 0 additions & 124 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -120,130 +120,6 @@ The reason for running `ipfs` under a shell is to avoid needing to hard-code the
120
120
121
121
Notes:
122
122
123
-
- To check that the job is running, run `launchctl list | grep ipfs`.
124
-
- IPFS should now start whenever you log in (and exit when you log out).
125
-
-[LaunchControl](http://www.soma-zone.com/LaunchControl/) is a GUI tool which simplifies management of LaunchAgents.## init system integration
126
-
127
-
go-ipfs can be started by your operating system's native init system.
128
-
129
-
-[systemd](#systemd)
130
-
-[LSB init script](#initd)
131
-
-[Upstart/startup job](#upstart)
132
-
-[launchd](#launchd)
133
-
134
-
### systemd
135
-
136
-
For `systemd`, the best approach is to run the daemon in a user session. Here is a sample service file:
137
-
138
-
```systemd
139
-
[Unit]
140
-
Description=IPFS daemon
141
-
142
-
[Service]
143
-
# Environment="IPFS_PATH=/data/ipfs" # optional path to ipfs init directory if not default ($HOME/.ipfs)
144
-
ExecStart=/usr/bin/ipfs daemon
145
-
Restart=on-failure
146
-
147
-
[Install]
148
-
WantedBy=default.target
149
-
```
150
-
151
-
To run this in your user session, save it as `~/.config/systemd/user/ipfs.service` (creating directories as necessary). Once you run `ipfs init` to create your IPFS settings, you can control the daemon using the following commands:
152
-
153
-
*`systemctl --user start ipfs` - start the daemon
154
-
*`systemctl --user stop ipfs` - stop the daemon
155
-
*`systemctl --user status ipfs` - get status of the daemon
156
-
*`systemctl --user enable ipfs` - enable starting the daemon at boot
157
-
*`systemctl --user disable ipfs` - disable starting the daemon at boot
158
-
159
-
*Note:* If you want this `--user` service to run at system boot, you must [`enable-linger`](http://www.freedesktop.org/software/systemd/man/loginctl.html) on the account that runs the service:
160
-
161
-
```
162
-
# loginctl enable-linger [user]
163
-
```
164
-
Read more about `--user` services here: [wiki.archlinux.org:Systemd](https://wiki.archlinux.org/index.php/Systemd/User#Automatic_start-up_of_systemd_user_instances)
165
-
166
-
### initd
167
-
168
-
- Here is a full-featured sample service file: https://github.com/dylanPowers/ipfs-linux-service/blob/master/init.d/ipfs
169
-
- Use `service` or your distribution's equivalent to control the service.
170
-
171
-
## upstart
172
-
173
-
- And below is a very basic sample upstart job. **Note the username jbenet**.
174
-
175
-
```
176
-
cat /etc/init/ipfs.conf
177
-
```
178
-
```
179
-
description "ipfs: interplanetary filesystem"
180
-
181
-
start on (local-filesystems and net-device-up IFACE!=lo)
0 commit comments