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
49 changes: 9 additions & 40 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,7 @@
[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
[![Version](https://img.shields.io/badge/Version-0.1.0-green.svg)](Cargo.toml)

Athena is a powerful CLI toolkit for back-end developers and DevOps engineers that simplifies project creation and infrastructure setup. It provides two main capabilities:

1. **Docker Compose Generator**: Transform a COBOL-inspired DSL into production-ready Docker Compose configurations with minimal effort.
2. **Project Boilerplate Generator**: Quickly scaffold full-stack back-end projects using frameworks like FastAPI, Go (Gin/Echo/Fiber), and Flask, with modern best practices and Docker integration.

Athena is a powerful CLI tool for back-end developers and DevOps engineers that transforms a COBOL-inspired DSL into production-ready Docker Compose configurations with minimal effort.

Built with performance and maintainability in mind, Athena uses intelligent defaults and modern Docker standards to generate optimized configurations with minimal configuration.

Expand Down Expand Up @@ -103,7 +99,7 @@ Suggestion: Use different host ports, e.g., 8080, 8081
### Installation
```bash
# Install from source
git clone https://github.com/your-org/athena.git
git clone https://github.com/Jeck0v/Athena
cd athena
cargo install --path .

Expand Down Expand Up @@ -131,15 +127,6 @@ END SERVICE' > deploy.ath
athena build deploy.ath
```

### Generate Full-Stack Project
```bash
# Create FastAPI + PostgreSQL project
athena init fastapi my-api --with-postgresql

# Create Go + MongoDB microservice
athena init go my-service --framework gin --with-mongodb
```

## Key Features

### Enhanced Error Handling System (New!)
Expand All @@ -149,14 +136,14 @@ athena init go my-service --framework gin --with-mongodb
- **Fail-Fast Processing** => Immediate feedback with no partial generation

### Intelligent Defaults 2025+
- No more `version` field modern Docker Compose spec compliance
- Auto check for the Dockerfile
- Auto-detects service types database, Cache, WebApp, Proxy patterns
- Smart restart policies `always` for databases, `unless-stopped` for apps
- Optimized health checks different intervals per service type
- Container naming follows modern conventions (`project-service`)

### Docker-First Approach
- Dockerfile by default => No image? Uses `build.dockerfile: Dockerfile`
- Dockerfile by default => No image? Just dont configure it and athena will check for your Dockerfile nativement
- Intelligent networking => Auto-configured networks with proper isolation
- Production-ready => Security, resource limits, and health monitoring
- Standards compliant => Follows Docker Compose 2025 best practices
Expand All @@ -167,13 +154,7 @@ athena init go my-service --framework gin --with-mongodb
- Optimized parsing => **<1ms parse time, <2ms generation**
- Memory efficient => Pre-allocated structures for large compositions

### Full-Stack Boilerplates
- FastAPI + PostgreSQL/MongoDB => Production authentication, async drivers
- Go + Gin/Echo/Fiber => Clean architecture, proper middleware
- Flask + PostgreSQL => Modern Python web development
- Docker ready => Multi-stage builds, Nginx reverse proxy included

### Syntax Highlighting (New!)
### Syntax Highlighting (SOON)
- **Beautiful DSL highlighting** for `.ath` files with customizable colors
- **Zed editor extension** ready to install in `syntax-highlighting/`
- **Smart color coding** for keywords, directives, template variables, and more
Expand All @@ -186,7 +167,6 @@ athena init go my-service --framework gin --with-mongodb
- [Syntax Highlighting (**New**)](syntax-highlighting/README.md) - Beautiful colors for `.ath` files in Zed editor.
- [Installation Guide](docs/INSTALLATION.md)
- [Docker Compose Generator Usage](docs/DSL_REFERENCE.md)
- [Boilerplate Project Generator](docs/BOILERPLATE.md)
- [Examples](docs/EXAMPLES.md)

### Development
Expand All @@ -196,26 +176,15 @@ athena init go my-service --framework gin --with-mongodb

## Basic Usage

### Docker Compose Generator
```bash
athena build deploy.ath # Generate docker-compose.yml
athena build deploy.ath -o custom.yml # Custom output file
athena validate deploy.ath # Validate syntax only
athena info # Show DSL information
athena info --examples # Show usage examples
athena info --directives # Show all directives
```

### Boilerplate Generator
```bash
# FastAPI projects
athena init fastapi my-api --with-postgresql
athena init fastapi my-api --with-mongodb

# Go projects
athena init go my-service --framework gin
athena init go my-service --framework echo --with-postgresql

# Flask projects
athena init flask my-app --with-postgresql
```
## What Athena Adds Automatically

- Smart service detection (Database, Cache, WebApp, Proxy)
Expand All @@ -241,4 +210,4 @@ This project is licensed under the MIT License see the [LICENSE](LICENSE) file f

---

Built with ❤️ using Rust | Production-ready DevOps made simple
Built with ❤️ using Rust | Make DevOps great again.
56 changes: 56 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# Generated by Athena v0.1.0 from test_no_conflicts deployment
# Developed by UNFAIR Team: https://github.com/Jeck0v/Athena
# Generated: 2025-11-24 09:32:38 UTC
# Features: Intelligent defaults, optimized networking, enhanced health checks

# Services: 3 configured with intelligent defaults

services:
app3:
image: apache:latest
container_name: test-no-conflicts-app3
ports:
- 9000:80
restart: always
networks:
- test_no_conflicts_network
pull_policy: missing
labels:
athena.type: proxy
athena.project: test_no_conflicts
athena.service: app3
athena.generated: 2025-11-24

app1:
image: nginx:alpine
container_name: test-no-conflicts-app1
ports:
- 8080:80
restart: always
networks:
- test_no_conflicts_network
pull_policy: missing
labels:
athena.type: proxy
athena.project: test_no_conflicts
athena.service: app1
athena.generated: 2025-11-24

app2:
image: httpd:alpine
container_name: test-no-conflicts-app2
ports:
- 8081:8000
restart: unless-stopped
networks:
- test_no_conflicts_network
pull_policy: missing
labels:
athena.service: app2
athena.project: test_no_conflicts
athena.type: generic
athena.generated: 2025-11-24
networks:
test_no_conflicts_network:
driver: bridge
name: test_no_conflicts
13 changes: 1 addition & 12 deletions docs/ARCHITECTURE.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,24 +19,13 @@ athena/
│ │ │ ├── compose.rs # Main generator
│ │ │ └── defaults.rs # Intelligent defaults engine
│ │ └── error.rs # Typed error handling
│ ├── boilerplate/ # Project generators
│ │ ├── fastapi.rs # FastAPI project generator
│ │ ├── go.rs # Go project generator
│ │ ├── flask.rs # Flask project generator
│ │ ├── templates.rs # Embedded templates
│ │ └── utils.rs # Template utilities
│ └── main.rs # Application entrypoint
├── docs/ # Documentation
├── tests/ # Comprehensive test suite
│ ├── integration/ # Integration tests organized by functionality
│ │ ├── cli_commands_test.rs # CLI command tests
│ │ ├── docker_compose_generation_test.rs # YAML generation tests
│ │ ├── error_handling_test.rs # Error scenario tests
│ │ ├── boilerplate/ # Modular boilerplate tests
│ │ │ ├── fastapi_tests.rs # FastAPI project generation
│ │ │ ├── flask_tests.rs # Flask project generation
│ │ │ ├── go_tests.rs # Go project generation
│ │ │ └── common_tests.rs # Common init functionality
│ │ └── structural/ # Lightweight structural tests
│ │ ├── basic_structure.rs # YAML structure validation
│ │ ├── service_configuration.rs # Service config tests
Expand Down Expand Up @@ -68,5 +57,5 @@ athena/
- **Parsing** using `pest` for grammar-based parsing
- **YAML generation** using `serde_yaml` for safe serialization
- **Testing** using comprehensive integration tests with GitHub Actions CI/CD
- **Test structure** organized by functionality (structural, boilerplate, CLI, error handling)
- **Test structure** organized by functionality (structural, CLI, error handling)
- **Lightweight testing** approach focusing on logic over format
Loading