Skip to main content
Glama
orneryd

M.I.M.I.R - Multi-agent Intelligent Memory & Insight Repository

by orneryd
build-docker.js1.69 kB
#!/usr/bin/env node // Cross-platform build helper: reads package.json version and runs docker-compose with VERSION in env. import { spawnSync } from 'child_process'; import { readFileSync } from 'fs'; import { URL } from 'url'; try { const pkgJson = JSON.parse(readFileSync(new URL('../package.json', import.meta.url))); const version = pkgJson.version || ''; console.log(`Building docker image with VERSION=${version}`); console.log(`Image will be tagged as: timothyswt/mimir-server:${version} and timothyswt/mimir-server:latest`); const env = { ...process.env, VERSION: version }; // Determine compose file based on architecture const arch = process.arch; const composeFile = arch === 'arm64' ? 'docker-compose.arm64.nornicdb.yml' : 'docker-compose.yml'; console.log(`Using compose file: ${composeFile}`); // Try 'docker compose' first (modern Docker Desktop), then fall back to 'docker-compose' // Use --no-cache to ensure fresh build let result = spawnSync('docker', ['compose', '-f', composeFile, 'build', '--no-cache', 'mimir-server'], { stdio: 'inherit', env }); if (result.error && result.error.code === 'ENOENT') { console.log('Trying docker-compose (legacy)...'); result = spawnSync('docker-compose', ['-f', composeFile, 'build', '--no-cache', 'mimir-server'], { stdio: 'inherit', env }); } if (result.error) { console.error('Failed to run docker compose:', result.error); console.error('\nMake sure Docker Desktop is installed and running.'); process.exit(result.status || 1); } process.exit(result.status ?? 0); } catch (err) { console.error('Error preparing docker build:', err); process.exit(1); }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/orneryd/Mimir'

If you have feedback or need assistance with the MCP directory API, please join our Discord server