Kosmos is a comprehensive Docker-based development environment designed for modern cross-platform engineering. It provides a ready-to-use stack for Android, Java/Kotlin, Rust, and Web Automation, ensuring consistency across development and CI/CD pipelines.
- Overview
- Core Features
- Quick Start
- Environment Reference
- Build Configuration
- Project Structure
- Contributing
- License & Ethics
Developing across multiple ecosystems like Android, JVM, and Rust can be challenging due to complex toolchain dependencies. Kosmos eliminates this "works on my machine" syndrome by:
- Standardizing the Toolchain: Provides pre-configured versions of JDK, Android SDK, and Gradle.
- Integrating Native Support: Full Rust toolchain inclusion for native development and cross-compilation.
- Automating Web Testing: Pre-installed Headless Chrome for robust web automation and integration testing.
- Ensuring Security: Designed with non-root user execution as a default for improved container security.
Kosmos comes with a full Android SDK stack optimized for modern builds:
- Android SDK: Pre-installed Platform version 36.
- Build Tools: Version 35.0.1 included by default.
- Command-Line Tools: Includes
sdkmanager,platform-tools, andcmdline-toolsfor automated management.
Built on top of industry-standard runtimes:
- Eclipse Temurin JDK 17: High-performance, open-source Java distribution.
- Gradle 9.5.1: Optimized build system for JVM and Android projects.
- Ready for Kotlin: Fully compatible with Kotlin Multiplatform and JVM targets.
Seamless integration for native systems programming:
- Rustup & Cargo: Full access to the Rust ecosystem.
- Native Interop: Ideal for projects using JNI or Rust-based Kotlin Multiplatform components.
- Cross-Compilation: Ready for building native binaries within the container.
Headless browser support for modern web workflows:
- Google Chrome: Pre-installed for headless execution.
- Automation Ready: Compatible with Selenium, Playwright, and Puppeteer.
- System Binaries: Environment variable
CHROME_BINis pre-configured for easy tool discovery.
Clone the repository and build the image locally:
docker build -t kosmos-dev .Run an interactive shell inside the environment, mounting your current directory:
docker run -it --rm -v $(pwd):/app kosmos-dev| Variable | Path | Description |
|---|---|---|
ANDROID_SDK_ROOT |
/sdk |
Root directory for Android SDK tools and platforms |
GRADLE_HOME |
/opt/gradle/gradle-9.5.1 |
Location of the Gradle installation |
CHROME_BIN |
/usr/bin/google-chrome |
Path to the Google Chrome binary |
CARGO_HOME |
/usr/local/cargo |
Storage for Rust Cargo binaries and packages |
RUSTUP_HOME |
/usr/local/rustup |
Directory for Rust toolchains and metadata |
Note: The system PATH is automatically updated to include Android tools, Gradle, and Cargo binaries.
You can customize the installed versions by passing --build-arg during the build process:
| Argument | Default Value | Description |
|---|---|---|
CMDLINE_TOOLS_VERSION |
14742923_latest |
Android command-line tools version |
ANDROID_SDK_VERSION |
36 |
Target Android Platform version |
BUILD_TOOLS_VERSION |
35.0.1 |
Android Build Tools version |
GRADLE_VERSION |
9.5.1 |
Installed Gradle version |
USER_NAME |
developer |
Default non-root user name |
USER_UID |
1000 |
UID for the non-root user |
USER_GID |
1000 |
GID for the non-root user |
docker build --build-arg GRADLE_VERSION=8.10.2 -t kosmos-dev:custom .Dockerfile: The main container image definition.scripts/: Modular shell scripts for component installation.README.md: This documentation.
We welcome contributions to improve the Kosmos environment!
- Issue Reporting: Use the GitHub issue tracker for bugs and feature requests.
- Pull Requests: Ensure any changes to installation scripts are tested and documented.
- License: Published under the Apache License 2.0. See
LICENSEfor details. - Code of Conduct: We adhere to our Code of Conduct.
Maintained by Davils