Quick Start¶
This guide starts Syfon with SQLite, local Basic Auth, and an S3-compatible object store. For the full config reference, see Server Configuration.
Prerequisites¶
Install Go and Docker. Initialize the DRS schema submodule, then build the server:
Start MinIO with the credentials used by the config:
docker run --name minio --rm -p 9000:9000 \
-e MINIO_ROOT_USER=minio-user \
-e MINIO_ROOT_PASSWORD=minio-pass \
quay.io/minio/minio server /data
In a second terminal, create local-bucket before you start Syfon:
docker run --rm --network container:minio --entrypoint sh minio/mc -c \
'mc alias set local http://127.0.0.1:9000 minio-user minio-pass && \
mc mb -p local/local-bucket'
The examples use localhost:9000, the bucket local-bucket, and the credentials minio-user and minio-pass. Keep the MinIO terminal running while you use Syfon.
Create a config file¶
Save this as config.local.yaml:
port: 8080
auth:
mode: local
basic:
username: drs-user
password: drs-pass
database:
sqlite:
file: ./data/drs.db
credential_encryption:
local_key_file: ./data/.syfon-credential-kek
buckets:
- bucket: local-bucket
provider: s3
region: us-east-1
endpoint: http://localhost:9000
access_key: minio-user
secret_key: minio-pass
resources:
- organization: example
projects:
- project_id: example
Create the directories named by the config before starting the server:
Start Syfon¶
In another terminal, check the health endpoint:
Use the CLI¶
Set the server and local credentials for CLI requests:
export SYFON_SERVER_URL=http://localhost:8080
export SYFON_USERNAME=drs-user
export SYFON_PASSWORD=drs-pass
Upload and list a file:
bin/syfon upload --file ./README.md --org example --project example
bin/syfon ls --organization example --project example
Download a record by DID from the ls output:
The upload command derives a DID from the file checksum and project scope when you omit --did. The --project flag is required in that case.
Read next¶
- Local Deployment covers local storage and Docker runs.
- Kubernetes Deployment covers the Gen3 chart.
- Server Configuration documents every config field.
- Troubleshooting covers startup, storage, auth, and database errors.