Installation methods

January 2, 2026 ยท View on GitHub

Download binary

See README.md.

From source

Requires a recent Rust toolchain, a C++ compiler (clang recommended), strip, and make.

sccache recommended for repeated builds.

git clone --recursive https://github.com/lichess-org/fishnet.git
cd fishnet
RUSTC_WRAPPER=sccache RUSTFLAGS="-C target-cpu=native" cargo run --release -vv --

To update, do not forget git submodule update before building again:

git pull
git submodule update
RUSTC_WRAPPER=sccache RUSTFLAGS="-C target-cpu=native" cargo run --release -vv --

Optional environment variables to configure Stockfish builds:

  • COMP: clang, gcc (default on Linux), mingw (default on Windows)
  • CXX
  • CXXFLAGS
  • DEPENDFLAGS
  • LDFLAGS
  • MAKE
  • SDE_PATH

Docker

docker run -it --shm-size=256m --name fishnet -e KEY=abcdef niklasf/fishnet:2

Per default, runs with n-1 cores, alternatively, specify the number of cores to use with:

docker run -it --shm-size=256m --name fishnet -e KEY=abcdef -e CORES=n niklasf/fishnet:2

For the full list of configurable environment variables, see docker-entrypoint.sh.

To update, since we named the image fishnet:

docker rm fishnet
docker pull niklasf/fishnet:2
docker run -it --shm-size=256m --name fishnet -e KEY=abcdef niklasf/fishnet:2

Kubernetes

Create fishnet.yaml as follows and edit fishnet-private-key:

apiVersion: v1
kind: Namespace
metadata:
  name: fishnet
---
apiVersion: v1
kind: Pod
metadata:
  name: fishnet-pod
  namespace: fishnet
spec:
  containers:
    - name: fishnet-pod
      image: niklasf/fishnet:2
      imagePullPolicy: Always
      volumeMounts:
        - mountPath: /dev/shm
          name: dshm
      env:
        # - name: CORES
        #   valueFrom:
        #     configMapKeyRef:
        #       name: fishnet-config
        #       key: cores
        - name: KEY
          valueFrom:
            secretKeyRef:
              name: lichess
              key: fishnet-private-key
  volumes:
    - name: dshm
      emptyDir:
        medium: Memory
  restartPolicy: Always
---
apiVersion: v1
kind: Secret
metadata:
  name: lichess
  namespace: fishnet
data:
  fishnet-private-key: <UPDATE here with your fishnet private key as BASE64 encoded string>
# ---
# apiVersion: v1
# kind: ConfigMap
# metadata:
#   name: fishnet-config
#   namespace: fishnet
# data:
#   cores: "4"

Uncomment the configMap to change the number of cores used.

To view logs:

kubectl logs fishnet-pod -n=fishnet

Delete to update, since the image pull policy is set to Always:

kubectl delete pod fishnet-pod -n=fishnet
kubectl apply -f fishnet.yaml