{"id":35174205,"url":"https://github.com/skygenesisenterprise/registry-service","last_synced_at":"2025-12-30T21:07:27.275Z","repository":{"id":323469946,"uuid":"1086024349","full_name":"skygenesisenterprise/registry-service","owner":"skygenesisenterprise","description":"The Official Registry Service for Sky Genesis Enterprise Package Ecosystem","archived":false,"fork":false,"pushed_at":"2025-11-10T10:14:45.000Z","size":42,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-11-10T11:24:49.939Z","etag":null,"topics":["cargo","dns","docker","docker-compose","javascript","package-manager","registry","rust","typescript"],"latest_commit_sha":null,"homepage":"https://pkgs.skygenesisenterprise.com","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/skygenesisenterprise.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":".github/CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SECURITY.md","support":".github/SUPPORT.md","governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"patreon":null,"open_collective":"skygenesisenterprise","ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"lfx_crowdfunding":null,"custom":null}},"created_at":"2025-10-29T20:53:06.000Z","updated_at":"2025-11-10T10:14:49.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/skygenesisenterprise/registry-service","commit_stats":null,"previous_names":["skygenesisenterprise/registry-service"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/skygenesisenterprise/registry-service","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skygenesisenterprise%2Fregistry-service","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skygenesisenterprise%2Fregistry-service/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skygenesisenterprise%2Fregistry-service/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skygenesisenterprise%2Fregistry-service/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/skygenesisenterprise","download_url":"https://codeload.github.com/skygenesisenterprise/registry-service/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/skygenesisenterprise%2Fregistry-service/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28104848,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-12-28T02:00:05.685Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cargo","dns","docker","docker-compose","javascript","package-manager","registry","rust","typescript"],"created_at":"2025-12-28T21:50:52.428Z","updated_at":"2025-12-28T21:50:53.583Z","avatar_url":"https://github.com/skygenesisenterprise.png","language":"Rust","funding_links":["https://opencollective.com/skygenesisenterprise"],"categories":[],"sub_categories":[],"readme":"\u003cdiv align=\"center\"\u003e\n\n# Sky Genesis Enterprise Registry Service\n\n[![Crates.io](https://img.shields.io/crates/v/registry-service)](https://crates.io/crates/registry-service)\n[![Rust](https://img.shields.io/badge/rust-1.70+-orange.svg)](https://www.rust-lang.org)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n[![Build Status](https://img.shields.io/github/workflow/status/skygenesisenterprise/registry-service/CI)](https://github.com/skygenesisenterprise/registry-service/actions)\n[![Coverage](https://img.shields.io/codecov/c/github/skygenesisenterprise/registry-service)](https://codecov.io/gh/skygenesisenterprise/registry-service)\n[![Docker](https://img.shields.io/badge/docker-ready-blue.svg)](https://hub.docker.com/r/skygenesisenterprise/registry-service)\n\nA comprehensive enterprise-grade package registry service inspired by Debian's package management system, designed for the Sky Genesis Enterprise ecosystem. This project provides both a RESTful API server and a command-line interface (CLI) tool called `cpkgs` for seamless package management.\n\n\u003c/div\u003e\n\n## 🚀 Quick Start\n\n```bash\n# Clone the repository\ngit clone https://github.com/skygenesisenterprise/registry-service.git\ncd registry-service\n\n# Setup development environment\nmake setup\n\n# Start all services\nmake dev\n```\n\n## 📋 Table of Contents\n\n- [Features](#-features)\n- [Architecture](#-architecture)\n- [Installation](#-installation)\n- [Usage](#-usage)\n- [API Documentation](#-api-documentation)\n- [Configuration](#-configuration)\n- [Development](#-development)\n- [Deployment](#-deployment)\n- [Contributing](#-contributing)\n- [License](#-license)\n\n## ✨ Features\n\n### Core Functionality\n- **Package Management**: Complete CRUD operations for packages\n- **Version Control**: Semantic versioning with dependency resolution\n- **Authentication \u0026 Authorization**: JWT-based secure user management with role-based access\n- **Search \u0026 Discovery**: Advanced package search with filtering capabilities\n- **Dependency Management**: Handle complex package dependencies and conflicts\n- **Multi-Architecture Support**: Package distribution across different architectures\n\n### API Features\n- **RESTful API**: Comprehensive endpoints with proper HTTP semantics\n- **Database**: PostgreSQL with Prisma ORM for type-safe database operations\n- **Security**: JWT authentication, CORS support, and security middleware\n- **Observability**: Structured logging with tracing for monitoring and debugging\n- **Performance**: Connection pooling and optimized query execution\n\n### CLI Features (`cpkgs`)\n- **Interactive Interface**: User-friendly package installation and removal\n- **Advanced Search**: Package search with detailed information and filtering\n- **Session Management**: Secure authentication and token handling\n- **Administrative Tools**: Complete admin operations for package management\n- **Performance**: Local caching and parallel operations\n- **User Experience**: Colored output, progress indicators, and intuitive commands\n\n## 🏗️ Architecture\n\n### System Overview\n\n```\n┌─────────────────┐    ┌─────────────────┐    ┌─────────────────┐\n│   CLI Client    │    │   Web Client    │    │  Mobile Client  │\n│     (cpkgs)     │    │   Interface     │    │   Application   │\n└─────────┬───────┘    └─────────┬───────┘    └─────────┬───────┘\n          │                      │                      │\n          └──────────────────────┼──────────────────────┘\n                                 │\n                    ┌─────────────┴─────────────┐\n                    │      API Gateway          │\n                    │   (Axum + Tower HTTP)     │\n                    └─────────────┬─────────────┘\n                                 │\n                    ┌─────────────┴─────────────┐\n                    │   Business Logic Layer    │\n                    │     (Services)           │\n                    └─────────────┬─────────────┘\n                                 │\n                    ┌─────────────┴─────────────┐\n                    │    Data Access Layer      │\n                    │  (Prisma + PostgreSQL)    │\n                    └───────────────────────────┘\n```\n\n### Project Structure\n\n```\nregistry-service/\n├── api/                           # REST API server\n│   ├── src/\n│   │   ├── config/               # Application configuration\n│   │   ├── controllers/          # Request handlers\n│   │   ├── db/                   # Database connection\n│   │   ├── middlewares/          # HTTP middleware\n│   │   ├── models/               # Data transfer objects\n│   │   ├── queries/              # Database queries\n│   │   ├── routes/               # API route definitions\n│   │   ├── services/             # Business logic\n│   │   └── main.rs               # Application entry point\n│   ├── prisma/\n│   │   └── schema.prisma         # Database schema\n│   └── Cargo.toml\n├── cli/                          # Command-line interface\n│   ├── src/\n│   │   ├── commands/             # CLI command implementations\n│   │   ├── config/               # Configuration management\n│   │   └── main.rs               # CLI entry point\n│   └── Cargo.toml\n├── .github/                      # GitHub workflows\n├── infrastructure/               # Docker and deployment configs\n└── README.md\n```\n\n## 🛠️ Installation\n\n### Prerequisites\n\n- **Rust** 1.70+ (for building from source)\n- **PostgreSQL** 12+ (for the database)\n- **Node.js** 16+ (for Prisma client generation)\n- **Docker** (optional, for containerized deployment)\n\n### From Source\n\n1. **Clone the repository**\n   ```bash\n   git clone https://github.com/skygenesisenterprise/registry-service.git\n   cd registry-service\n   ```\n\n2. **Setup development environment**\n   ```bash\n   make setup\n   ```\n\n3. **Configure environment variables**\n   ```bash\n   cp .env.example .env\n   # Edit .env with your configuration\n   ```\n\n4. **Start the services**\n   ```bash\n   make dev\n   ```\n\n### Using Docker\n\n```bash\n# Build and start all services\nmake docker-up\n\n# Build release images\nmake docker-build-release\n\n# Push to registry\nmake docker-push-release\n```\n\n## 📖 Usage\n\n### API Server\n\nStart the API server:\n```bash\ncd api\ncargo run\n```\n\nThe API will be available at `http://localhost:3000`\n\n### CLI Tool (`cpkgs`)\n\n#### Authentication\n```bash\n# Register a new user\ncpkgs auth register\n\n# Login\ncpkgs auth login\n\n# Check authentication status\ncpkgs auth status\n\n# Logout\ncpkgs auth logout\n```\n\n#### Package Management\n```bash\n# Search for packages\ncpkgs search \"web server\"\n\n# Install a package\ncpkgs install nginx\n\n# Install a specific version\ncpkgs install nginx --version 1.21.0\n\n# List installed packages\ncpkgs list --installed\n\n# List available packages\ncpkgs list\n\n# Get package information\ncpkgs info nginx\n\n# Remove a package\ncpkgs remove nginx\n\n# Update package index\ncpkgs update\n\n# Upgrade all packages\ncpkgs upgrade --all\n```\n\n#### Administrative Operations\n```bash\n# Upload a package (admin only)\ncpkgs admin upload ./package.deb\n\n# Remove a package from registry (admin only)\ncpkgs admin remove nginx 1.21.0\n\n# List all users (admin only)\ncpkgs admin list-users\n\n# Create a new user (admin only)\ncpkgs admin create-user john.doe@company.com\n```\n\n## 📚 API Documentation\n\n### Base URL\n```\nhttp://localhost:3000/api\n```\n\n### Authentication\nAll protected endpoints require a Bearer token:\n```\nAuthorization: Bearer \u003cyour-jwt-token\u003e\n```\n\n### Core Endpoints\n\n#### Packages\n- `GET /packages` - List all packages\n- `GET /packages/:id` - Get package details\n- `POST /packages` - Create a new package\n- `PUT /packages/:id` - Update package\n- `DELETE /packages/:id` - Delete package\n- `GET /packages/:id/download` - Download package file\n- `GET /packages/search/:query` - Search packages\n\n#### Users\n- `GET /users` - List all users\n- `GET /users/:id` - Get user details\n- `POST /users` - Create user\n- `PUT /users/:id` - Update user\n- `DELETE /users/:id` - Delete user\n- `GET /users/:id/packages` - Get user's packages\n\n#### Authentication\n- `POST /auth/login` - User login\n- `POST /auth/register` - User registration\n- `POST /auth/logout` - User logout\n\n### Response Format\n\nAll API responses follow a consistent JSON format:\n\n```json\n{\n  \"id\": \"package_id\",\n  \"name\": \"nginx\",\n  \"version\": \"1.21.0\",\n  \"description\": \"High performance web server\",\n  \"maintainer\": \"admin@company.com\",\n  \"architecture\": \"amd64\",\n  \"size\": 1048576,\n  \"checksum\": \"sha256_hash\",\n  \"created_at\": \"2024-01-01T00:00:00Z\",\n  \"updated_at\": \"2024-01-01T00:00:00Z\",\n  \"author\": \"admin\",\n  \"dependencies\": [\n    {\n      \"name\": \"libc6\",\n      \"version\": \"\u003e=2.28\",\n      \"dependency_type\": \"REQUIRES\"\n    }\n  ],\n  \"tags\": [\n    {\n      \"name\": \"web\",\n      \"color\": \"#007bff\"\n    }\n  ]\n}\n```\n\n## ⚙️ Configuration\n\n### Environment Variables\n\n| Variable | Description | Default |\n|----------|-------------|---------|\n| `DATABASE_URL` | PostgreSQL connection string | - |\n| `RUST_LOG` | Logging level | `info` |\n| `API_HOST` | API server host | `0.0.0.0` |\n| `API_PORT` | API server port | `3000` |\n| `JWT_SECRET` | JWT signing secret | - |\n| `CORS_ORIGINS` | Allowed CORS origins | `*` |\n\n### CLI Configuration\n\nThe CLI stores configuration in `~/.cpkgs/config.toml`:\n\n```toml\nregistry_url = \"http://localhost:3000\"\nauth_token = \"your-jwt-token\"\ncache_dir = \"/home/user/.cpkgs/cache\"\ninstall_dir = \"/home/user/.cpkgs/packages\"\n```\n\n## 🧪 Development\n\n### Running Tests\n\n```bash\n# Run all tests\nmake test\n\n# Run API tests\nmake api-test\n\n# Run CLI tests\ncd cli \u0026\u0026 cargo test\n\n# Run tests with coverage\nmake test-coverage\n```\n\n### Code Quality\n\n```bash\n# Format code\nmake fmt\n\n# Run linter\nmake lint\n\n# Run clippy\nmake clippy\n\n# Security audit\nmake audit\n```\n\n### Development Workflow\n\n```bash\n# Start development environment\nmake dev\n\n# Build all components\nmake build\n\n# Run health checks\nmake health\n\n# Clean build artifacts\nmake clean\n```\n\n## 🚀 Deployment\n\n### Production Deployment\n\n#### Docker Compose\n\n```bash\n# Deploy with Docker Compose\nmake docker-up\n\n# View logs\nmake docker-logs\n\n# Scale services\ndocker-compose up -d --scale api=3\n```\n\n#### Kubernetes\n\n```bash\n# Apply Kubernetes manifests\nkubectl apply -f infrastructure/k8s/\n\n# Check deployment status\nkubectl get pods -n registry-service\n```\n\n### Environment Configuration\n\n#### Development\n- Local PostgreSQL instance\n- Debug logging enabled\n- Hot reload for rapid development\n\n#### Staging\n- Managed PostgreSQL database\n- Structured logging with tracing\n- Performance monitoring enabled\n\n#### Production\n- High-availability PostgreSQL cluster\n- Comprehensive monitoring and alerting\n- Rate limiting and security hardening\n- Automated backups and disaster recovery\n\n## 🤝 Contributing\n\nWe welcome contributions! Please follow our [Contributing Guidelines](CONTRIBUTING.md).\n\n### Development Process\n\n1. **Fork** the repository\n2. **Create** a feature branch (`git checkout -b feature/amazing-feature`)\n3. **Commit** your changes (`git commit -m 'Add amazing feature'`)\n4. **Push** to the branch (`git push origin feature/amazing-feature`)\n5. **Open** a Pull Request\n\n### Code Standards\n\n- Follow [Rust best practices](https://rust-lang.github.io/api-guidelines/)\n- Write comprehensive tests for new features\n- Update documentation for API changes\n- Use [conventional commit messages](https://www.conventionalcommits.org/)\n- Ensure all CI checks pass before submitting\n\n### Reporting Issues\n\n- Use [GitHub Issues](https://github.com/skygenesisenterprise/registry-service/issues) for bug reports\n- Use [GitHub Discussions](https://github.com/skygenesisenterprise/registry-service/discussions) for questions\n- Check existing issues before creating new ones\n\n## 📄 License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n\n## 🆘 Support\n\n- **Documentation**: [Project Wiki](https://github.com/skygenesisenterprise/registry-service/wiki)\n- **Issues**: [GitHub Issues](https://github.com/skygenesisenterprise/registry-service/issues)\n- **Discussions**: [GitHub Discussions](https://github.com/skygenesisenterprise/registry-service/discussions)\n- **Email**: support@skygenesisenterprise.com\n\n## 🗺️ Roadmap\n\n### Upcoming Features\n\n- [ ] **Package Signing**: GPG-based package verification\n- [ ] **Private Repositories**: Organization-specific package repositories\n- [ ] **Web Interface**: React-based management dashboard\n- [ ] **Analytics**: Package usage metrics and insights\n- [ ] **CI/CD Integration**: GitHub Actions, GitLab CI plugins\n- [ ] **Mobile CLI**: iOS and Android applications\n- [ ] **GraphQL API**: Alternative API interface\n- [ ] **Version Rollback**: Safe package version management\n- [ ] **Security Scanning**: Automated vulnerability detection\n- [ ] **Multi-Region**: Global package distribution\n\n### Performance Improvements\n\n- [ ] **CDN Integration**: Faster package downloads\n- [ ] **Caching Layer**: Redis-based response caching\n- [ ] **Database Optimization**: Query performance improvements\n- [ ] **Horizontal Scaling**: Load balancing and clustering\n\n---\n\n\u003cdiv align=\"center\"\u003e\n\n**Sky Genesis Enterprise Package Registry** - Modern package management for enterprise ecosystems.\n\nBuilt with ❤️ by the Sky Genesis Enterprise team\n\n\u003c/div\u003e","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fskygenesisenterprise%2Fregistry-service","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fskygenesisenterprise%2Fregistry-service","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fskygenesisenterprise%2Fregistry-service/lists"}