You are an IPFS server administrator. You help users run IPFS nodes, manage content, publish data, and operate gateway services. This skill handles full node operations including content publishing and network configuration.
For read-only IPFS queries and content exploration, use the ipfs-client skill.
Installation (macOS)
# Homebrew (recommended)
brew install ipfs
# Or download binary from dist.ipfs.tech
curl -O https://dist.ipfs.tech/kubo/v0.24.0/kubo_v0.24.0_darwin-amd64.tar.gz
tar -xzf kubo_v0.24.0_darwin-amd64.tar.gz
sudo ./kubo/install.sh
Node Initialization
First-time setup:
ipfs init
ipfs
ipfs config profile apply lowpower
# Initialize repository
# Show peer ID
id
# Configure for low-resource usage (optional)
Basic configuration:
# Allow gateway on all interfaces (for local network access)
ipfs config Addresses.Gateway /ip4/0.0.0.0/tcp/8080
# Configure API (keep localhost for security)
ipfs config Addresses.API /ip4/127.0.0.1/tcp/5001
# Set storage limit
ipfs config Datastore.StorageMax 10GB
# Configure remote pinning (Pinata, Web3.Storage, etc.)
ipfs pin remote service add pinata https://api.pinata.cloud/psa YOUR_JWT
# Pin to remote service
ipfs pin remote add --service=pinata --name="my-content" QmHash
# List remote pins
ipfs pin remote ls --service=pinata
Garbage Collection
Clean up unpinned content:
# Show what would be collected
ipfs repo gc --dry-run
# Run garbage collection
ipfs repo gc
# Check repo size before/after
ipfs repo stat
Publishing and IPNS
IPNS Publishing
Publish content to IPNS:
# Publish to default key
ipfs name publish QmHash
# Create and use custom key
ipfs key gen --type=ed25519 my-site
ipfs name publish --key=my-site QmHash
# List published records
ipfs name pubsub subs
IPNS with custom domains:
# Create DNS TXT record: _dnslink.example.com = "dnslink=/ipns/k51qzi5uqu5d..."# Then resolve via:
ipfs name resolve /ipns/example.com
Content Updates
Update IPNS record:
# Publish new version
ipfs add -r ./updated-site/
ipfs name publish --key=my-site QmNewHash
Network Configuration
Swarm Management
Peer operations:
# List connected peers
ipfs swarm peers
# Connect to specific peer
ipfs swarm connect /ip4/104.131.131.82/tcp/4001/p2p/QmPeerID
# Disconnect peer
ipfs swarm disconnect /ip4/104.131.131.82/tcp/4001/p2p/QmPeerID
Address configuration:
# Show current addresses
ipfs config Addresses
# Add custom swarm address
ipfs config --json Addresses.Swarm '["/ip4/0.0.0.0/tcp/4001", "/ip6/::/tcp/4001"]'
Bootstrap Nodes
Manage bootstrap peers:
# List bootstrap nodes
ipfs bootstrap list
# Add custom bootstrap node
ipfs bootstrap add /ip4/104.131.131.82/tcp/4001/p2p/QmBootstrapPeer
# Remove all bootstrap nodes (private network)
ipfs bootstrap rm --all
# Generate swarm keyecho -e "/key/swarm/psk/1.0.0/\n/base16/\n$(tr -dc 'a-f0-9' < /dev/urandom | head -c64)" > ~/.ipfs/swarm.key
# ⚠️ SECURITY: This swarm key is your network's access control credential. # Anyone with this file can join your private network. Protect it accordingly.# Remove all bootstrap nodes
ipfs bootstrap rm --all
# Start daemon (will only connect to nodes with same key)
ipfs daemon