This repository contains a Docker Compose setup for running a local Masa Bittensor network with multiple services, including subtensor, subnet, miner, validator, and protocol.
- Docker
- Docker Compose
- Make
-
Clone the repository:
git clone https://github.com/masa-finance/masa-bittensor.git cd masa-bittensor
-
Start the network:
make up
This command will automatically pull the pre-built Docker images from the GitHub Container Registry and start all services.
-
Watch the logs:
make logs
Monitor the output of all services. It may take about 20 minutes for the validator to have its weights boosted and become fully operational.
Once the network is up and running:
-
Open your browser and navigate to
http://localhost:8000/docs
to see the available API endpoints. -
Test an endpoint using curl:
curl localhost:8000/data/discord/profile/691473028525195315
This should return data about the queried Discord profile.
-
In the Docker logs (
make logs
), you should see the validator and miner receiving and processing the request, then sending it to the masa protocol node for actual processing.
make up
: Pull images and start all servicesmake down
: Stop and remove all containersmake logs
: View logs from all servicesmake pull
: Pull the latest images without starting the servicesmake build
: Build the images locally (not typically needed)
If you encounter issues:
- Ensure you're using the latest version of Docker and Docker Compose.
- Try stopping the network (
make down
), pulling the latest images (make pull
), and starting again (make up
). - Check the logs (
make logs
) for any error messages.
For development workflows and contribution guidelines, please see CONTRIBUTING.md.
This project is licensed under the MIT License - see the LICENSE file for details.