https://github.com/casl0/aosp-builder
AOSP Build
https://github.com/casl0/aosp-builder
aosp aosp-build aws terraform
Last synced: about 1 month ago
JSON representation
AOSP Build
- Host: GitHub
- URL: https://github.com/casl0/aosp-builder
- Owner: CASL0
- License: mit
- Created: 2024-02-04T14:34:32.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2026-04-20T04:23:32.000Z (about 1 month ago)
- Last Synced: 2026-04-20T06:28:00.933Z (about 1 month ago)
- Topics: aosp, aosp-build, aws, terraform
- Language: HCL
- Homepage:
- Size: 118 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# aosp-builder
Android OS ビルド用の VM を構築します。
## Prerequisites
1. Terraform をインストールしてください。
- https://developer.hashicorp.com/terraform/tutorials/aws-get-started/install-cli
1. EC2 で`ec2-key`という名前のキーペアを作成してください。
- https://docs.aws.amazon.com/ja_jp/AWSEC2/latest/UserGuide/create-key-pairs.html
## Usage
1. 次のコマンドを実行し、EC2 を構築してください。
```sh
terraform plan
terraform apply -auto-approve
```
1. SSH で EC2 にアクセスしてください。
```sh
ssh ubuntu@
```
1. 次のコマンドで Android のソースコードをダウンロードします。
```sh
repo init -u https://android.googlesource.com/platform/manifest
repo sync -j32
```
1. 次のコマンドでビルドに必要なツール(lunch 等)をセットアップします。
```sh
source build/envsetup.sh
```
1. 次のコマンドを実行すると、ビルドのターゲットが列挙されるのでターゲットを決定してください。
```sh
lunch
```
1. 次のコマンドでビルド開始します。
```sh
m
```
## 参考
https://source.android.com/docs/setup/start?hl=ja
## Tips
### デスクトップ環境、XRDP の設定
```sh
sudo adduser user
sudo gpasswd -a user sudo
sudo apt install -y ubuntu-desktop
sudo apt install -y xrdp
sudo systemctl restart xrdp
sudo systemctl enable xrdp.service
sudo systemctl enable xrdp-sesman.service
```
## Requirements
| Name | Version |
|------|---------|
| [terraform](#requirement\_terraform) | >= 1.0 |
| [aws](#requirement\_aws) | >= 5.00 |
## Providers
No providers.
## Modules
| Name | Source | Version |
|------|--------|---------|
| [aws\_resources](#module\_aws\_resources) | ./modules/aws | n/a |
## Resources
No resources.
## Inputs
No inputs.
## Outputs
| Name | Description |
|------|-------------|
| [ssh](#output\_ssh) | ssh command |