This repository contains a Dockerfile and associated configurations to facilitate the build and generation of APK files for Android applications. By using Docker containers, developers can create a standardized build environment, eliminating dependency issues and ensuring consistent builds across different systems.
To get started with building Android apps using Docker, follow these steps:
-
Clone the Repository:
git clone https://github.com/francoborrelli/android-sdk-builder.git cd your_repository
-
Build the Docker Image:
docker build -t android-build .
-
Run the Docker Container:
docker run --rm -v $(pwd):/workspace android-build
-
Retrieve the APK File: Once the build process is complete, the generated APK file will be available in the
/workspace
directory within the Docker container. You can copy it to your host machine using thedocker cp
command.
The Dockerfile provided in this repository offers a basic configuration for building Android apps. However, you can customize it to suit your specific requirements. Here are some possible modifications:
- Android SDK/NDK Versions: Update the
ANDROID_COMPILE_SDK
,ANDROID_BUILD_TOOLS
, andANDROID_SDK_TOOLS
variables in the Dockerfile to specify the desired versions. - Additional Dependencies: Install additional dependencies required for your Android project by adding corresponding commands to the Dockerfile.
- Environment Variables: Set environment variables in the Dockerfile to configure the build environment as needed.
Contributions to this project are welcome! If you encounter any issues or have suggestions for improvements, please open an issue or submit a pull request.
This project is licensed under the MIT License. Feel free to use and modify the code according to your needs.