Skip to content

Installation

This guide will walk you through installing and setting up OstrichDB for development.

Before installing OstrichDB, ensure you have the following:

OstrichDB is written in Odin, so you’ll need the Odin compiler installed on your system.

  1. Visit the official Odin website
  2. Follow the installation instructions for your operating system
  3. Verify the installation by running:
    Terminal window
    odin version
  • Operating System: Linux, macOS, or Windows
  • Memory: At least 512MB RAM available
  • Storage: 100MB+ free disk space for the database files
Terminal window
git clone https://github.com/ArchetypeDynamics/Open-Ostrich.git
cd Open-Ostrich

OstrichDB includes a build script that handles compilation and setup:

Terminal window
./scripts/local_build.sh

This script will:

  • Compile the Odin source code
  • Set up the necessary directory structure
  • Start the server on the default port (8042)

Once the build completes, you should see output indicating that the server has started:

OstrichDB Server starting on localhost:8042
Server ready to accept connections

You can verify the installation by making a request to the health endpoint:

Terminal window
curl http://localhost:8042/health

The server uses JSON configuration files located in the config/ directory:

  • development.json - Development environment settings
  • production.json - Production environment settings

By default, OstrichDB runs with these settings:

  • Port: 8042
  • Host: localhost
  • Environment: development
  • Database Path: ./data/

You can modify these settings by editing the appropriate configuration file.

For initial development and testing, you may want to create test data. Uncomment the following functions in main/main.odin:

// create_test_user()
// test_project_creation()

These functions will create:

  • A test user account
  • Sample projects and collections
  • Example data for development

Build Errors

  • Ensure you have the latest version of the Odin compiler
  • Check that all dependencies are properly installed
  • Verify file permissions on the project directory

Server Won’t Start

  • Check if port 8042 is already in use
  • Verify the configuration file syntax
  • Ensure the data directory is writable

Connection Issues

  • Confirm the server is running on the expected port
  • Check firewall settings
  • Verify network connectivity

If you encounter issues:

  1. Check the server logs for error messages
  2. Review the configuration files
  3. Consult the GitHub repository for known issues
  4. Create an issue if you find a bug

Now that you have OstrichDB installed, continue to the Quick Start guide to learn how to use the database.