Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 8 additions & 16 deletions .env.example
Original file line number Diff line number Diff line change
@@ -1,19 +1,11 @@
# Storage Configuration
STORAGE_DATA_DIR=./.storage-data
STORAGE_QUOTA_GB=100
STORAGE_DISCOVERY_PORT=8089
STORAGE_MAX_PEERS=50

# Network Discoverability Configuration
# NAT traversal method: any, none, upnp, pmp, or extip:<IP>
STORAGE_NAT=any

# Listen addresses (multi-address format, comma-separated)
# Default listens on all interfaces with random TCP port
STORAGE_LISTEN_ADDRS=/ip4/0.0.0.0/tcp/0

# Bootstrap nodes - comma-separated SPR URIs
STORAGE_BOOTSTRAP_NODES=
# Kubo IPFS Configuration
KUBO_API_URL=http://127.0.0.1:5001
KUBO_API_TIMEOUT_SECS=300
KUBO_PIN_ON_UPLOAD=true

# Kubo API Authentication (optional, for remote nodes with Basic Auth)
KUBO_API_USERNAME=
KUBO_API_PASSWORD=

# Database Paths
WHOSONFIRST_DB_PATH=./assets/whosonfirst-data-admin-latest.db
Expand Down
96 changes: 96 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
name: CI

on:
pull_request:
branches:
- "*"

# Cancel in-progress runs when a new commit is pushed
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

permissions:
contents: read
pull-requests: write
statuses: write

jobs:
setup:
runs-on: ubuntu-latest
timeout-minutes: 10
outputs:
cache-hit: ${{ steps.cache-deps.outputs.cache-hit }}

steps:
- name: Checkout Code
uses: actions/checkout@v4

- name: Set up Rust using mise
uses: jdx/mise-action@v2
with:
cache: true

- name: Cache dependencies
id: cache-deps
uses: actions/cache@v4
with:
path: |
~/.cargo
./target
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
${{ runner.os }}-cargo-

lint:
needs: setup
runs-on: ubuntu-latest
timeout-minutes: 5

steps:
- name: Checkout Code
uses: actions/checkout@v4

- name: Set up Rust using mise
uses: jdx/mise-action@v4
with:
cache: true

- name: Restore dependencies
uses: actions/cache/restore@v4
with:
path: |
~/.cargo
./target
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- name: Lint
run: |
cargo fmt -- --check
cargo clippy --all-targets -- -D warnings
cargo check --quiet 2>&1

test:
needs: setup
runs-on: ubuntu-latest
timeout-minutes: 10

steps:
- name: Checkout Code
uses: actions/checkout@v4

- name: Set up Rust using mise
uses: jdx/mise-action@v2
with:
cache: true

- name: Restore dependencies
uses: actions/cache/restore@v4
with:
path: |
~/.cargo
./target
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- name: Test
run: cargo test --lib --quiet
Loading
Loading