2022-12-11 14:02:55 +00:00
|
|
|
# skynet
|
2023-10-09 11:42:09 +00:00
|
|
|
<div align="center">
|
|
|
|
<img src="https://explorer.skygpu.net/v2/explore/assets/logo.png" width=512 height=512>
|
|
|
|
</div>
|
2022-12-11 14:02:55 +00:00
|
|
|
### decentralized compute platform
|
2023-05-30 03:41:32 +00:00
|
|
|
|
2023-10-03 15:55:57 +00:00
|
|
|
### native install
|
|
|
|
|
|
|
|
system dependencies:
|
|
|
|
- `cuda` 11.8
|
|
|
|
- `llvm` 10
|
|
|
|
- `python` 3.10+
|
|
|
|
- `docker` (for ipfs node)
|
|
|
|
|
2023-05-30 03:41:32 +00:00
|
|
|
```
|
|
|
|
# create and edit config from template
|
2023-10-06 13:24:44 +00:00
|
|
|
cp skynet.toml.example skynet.toml
|
2023-05-30 03:41:32 +00:00
|
|
|
|
2023-10-03 15:55:57 +00:00
|
|
|
# install poetry package manager
|
|
|
|
curl -sSL https://install.python-poetry.org | python3 -
|
2023-05-30 03:41:32 +00:00
|
|
|
|
2023-10-03 15:55:57 +00:00
|
|
|
# install
|
|
|
|
poetry install
|
2023-05-30 03:41:32 +00:00
|
|
|
|
2023-10-03 15:55:57 +00:00
|
|
|
# enable environment
|
|
|
|
poetry shell
|
2023-05-30 03:41:32 +00:00
|
|
|
|
|
|
|
# test you can run this command
|
|
|
|
skynet --help
|
|
|
|
|
2023-10-03 15:55:57 +00:00
|
|
|
# launch ipfs node
|
|
|
|
skynet run ipfs
|
|
|
|
|
2023-05-30 03:41:32 +00:00
|
|
|
# to launch worker
|
|
|
|
skynet run dgpu
|
|
|
|
|
|
|
|
```
|
2023-10-03 15:55:57 +00:00
|
|
|
|
|
|
|
### dockerized install
|
|
|
|
|
2023-10-09 10:39:23 +00:00
|
|
|
## frontend
|
|
|
|
|
|
|
|
system dependencies:
|
|
|
|
- `docker`
|
|
|
|
|
|
|
|
```
|
|
|
|
# create and edit config from template
|
|
|
|
cp skynet.toml.example skynet.toml
|
|
|
|
|
|
|
|
# pull runtime container
|
|
|
|
docker pull guilledk/skynet:runtime-frontend
|
|
|
|
|
|
|
|
# run telegram bot
|
|
|
|
docker run \
|
|
|
|
-it \
|
|
|
|
--rm \
|
|
|
|
--network host \
|
|
|
|
--name skynet-telegram \
|
|
|
|
--mount type=bind,source="$(pwd)",target=/root/target \
|
|
|
|
guilledk/skynet:runtime-frontend \
|
|
|
|
skynet run telegram --db-pass PASSWORD --db-user USER --db-host HOST
|
|
|
|
```
|
|
|
|
|
|
|
|
## worker
|
|
|
|
|
2023-10-03 15:55:57 +00:00
|
|
|
system dependencies:
|
|
|
|
- `docker` with gpu enabled
|
|
|
|
|
|
|
|
```
|
2023-10-06 13:24:44 +00:00
|
|
|
# create and edit config from template
|
|
|
|
cp skynet.toml.example skynet.toml
|
|
|
|
|
2023-10-03 15:55:57 +00:00
|
|
|
# pull runtime container
|
|
|
|
docker pull guilledk/skynet:runtime-cuda
|
|
|
|
|
|
|
|
# or build it (takes a bit of time)
|
|
|
|
./build_docker.sh
|
|
|
|
|
|
|
|
# launch simple ipfs node
|
|
|
|
./launch_ipfs.sh
|
|
|
|
|
2023-10-06 13:24:44 +00:00
|
|
|
# run worker with all gpus
|
2023-10-03 15:55:57 +00:00
|
|
|
docker run \
|
|
|
|
-it \
|
|
|
|
--rm \
|
|
|
|
--gpus all \
|
|
|
|
--network host \
|
2023-10-03 18:42:07 +00:00
|
|
|
--name skynet-worker \
|
2023-10-03 15:55:57 +00:00
|
|
|
--mount type=bind,source="$(pwd)",target=/root/target \
|
2023-10-07 14:04:57 +00:00
|
|
|
guilledk/skynet:runtime-cuda \
|
2023-10-03 15:55:57 +00:00
|
|
|
skynet run dgpu
|
2023-10-06 13:24:44 +00:00
|
|
|
|
|
|
|
# run worker with specific gpu
|
|
|
|
docker run \
|
|
|
|
-it \
|
|
|
|
--rm \
|
|
|
|
--gpus '"device=1"' \
|
|
|
|
--network host \
|
|
|
|
--name skynet-worker-1 \
|
|
|
|
--mount type=bind,source="$(pwd)",target=/root/target \
|
2023-10-07 14:04:57 +00:00
|
|
|
guilledk/skynet:runtime-cuda \
|
2023-10-06 13:24:44 +00:00
|
|
|
skynet run dgpu
|
2023-10-03 15:55:57 +00:00
|
|
|
```
|