ℹ️ This project is a fork based on verydogelabs/wonky-ord-dogecoin.
You can see a running version here: LUCKY-ORD.COM - Credits to @DogepayDRC20.
Find the API documentation here. You can view it conveniently in the Swagger Editor by importing the openapi.yaml
file via URL: https://raw.githubusercontent.com/toregua/ord-luckycoin/main/openapi.yaml
.
Install required dependencies:
sudo apt-get update
sudo apt-get install -y build-essential libssl-dev pkg-config curl git
ord-luckycoin requires Rust to build from source. Install Rust and Cargo with:
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
source $HOME/.cargo/env
Verify the Rust installation:
cargo --version
Clone the ord-luckycoin repository and build the project:
git clone https://github.com/toregua/ord-luckycoin.git
cd ord-luckycoin
cargo build --release
The compiled binary will be located in the target/release
directory.
Ensure your Luckycoin Core node is running and fully synced. You can install and run it manually or use Docker. Here’s a Docker guide to set up and sync a Luckycoin node: run a luckycoin node inside a docker container.
Make sure txindex=1
is set in luckycoin.conf
to enable transaction indexing, as ord-luckycoin requires this.
--index-transactions
: Enables storing transaction data, required for--index-lky20
and enhances API performance.--index-lky20
: Tracks luckyscriptions with user balances, tick list, and tick holders.--index-lunes
: Enables tracking of lunes (analogous to BTC RUNE or Dogecoin DUNE).--nr-parallel-requests
: Sets the number of parallel RPC requests.16
is recommended for standard setups.
Set up a .env
file (copy from .env.example
) with the following:
FIRST_INSCRIPTION_HEIGHT
: Set to0
to handle all inscriptions, or use a specific height for faster indexing.FIRST_LUNE_HEIGHT
: Set to0
initially; update if LUNE data is deployed on Luckycoin.RPC_URL
: Provide your node RPC URL (e.g.,http://user:[email protected]:9918
).
To start the ord-luckycoin indexer and server in the foreground:
./target/release/ord \
--first-inscription-height=0 \
--rpc-url=http://127.0.0.1:9918/ \
--data-dir=/root/.local/share/ord \
server --http-port=8080
This command:
- Starts the indexer from block
0
and connects to the Luckycoin node at127.0.0.1:9918
. - Specifies the data directory at
/root/.local/share/ord
. - Runs the server on HTTP port
8080
.
This will keep the process running in the foreground so that you can monitor it directly.
If you prefer to capture logs, you can redirect the output to a log file:
./target/release/ord \
--first-inscription-height=0 \
--rpc-url=http://127.0.0.1:9918/ \
--data-dir=/root/.local/share/ord \
server --http-port=8080 > ~/ord-luckycoin.log 2>&1
To view the log output in real-time, open a new terminal and use:
tail -f ~/ord-luckycoin.log
Using Docker to run the ord-luckycoin indexer/server is recommended.
- System Requirements: Ubuntu or a similar Linux distribution.
- Luckycoin Node: Install and sync a Luckycoin node (recommended via Docker guide).
- Install Docker and Docker-Compose: Docker installation guide.
- Clone Repository: Clone this repository and navigate to the cloned directory.
To build and run the ord-luckycoin Docker container:
# Build Docker image
docker-compose build
# Start ord-luckycoin in background
docker-compose up -d
# View logs
docker-compose logs -f --tail 200
When stopping the container, add a timeout to avoid database issues.
docker-compose stop -t 600
docker-compose down