1
0
mirror of https://github.com/lineageos4microg/docker-lineage-cicd synced 2024-11-09 10:09:56 +01:00
docker-lineage-cicd/README.md

79 lines
3.0 KiB
Markdown
Raw Normal View History

2017-01-06 15:02:14 +01:00
# docker-lineage-cicd
2017-01-08 17:37:37 +01:00
2017-01-06 15:02:14 +01:00
Docker microservice for LineageOS Continuous Integration and Continous Deployment
2017-01-08 17:37:37 +01:00
## Why
Because I always believe that even advanced technologies should be available to everyone. This is a tentative to offer everyone the possibility to build his own images of LineageOS, when he wants, how he wants. You don't have to wait anymore for build bots. No more scene drama. Just build and enjoy your favourite Android ROM.
## Why Docker?
Because I'm a big fan of isolating everything if possible. I don't want to reinstall my OS or triage with dirty packages, just because today I need somethng, and tomorrow I'll need something else.
2017-01-08 17:50:24 +01:00
## Requirements
- At least Dual Core CPU ( Higher is better )
- At least 6GB RAM ( Higher is better )
- At least 200GB HDD Space ( Higher is better )
2017-01-08 17:37:37 +01:00
## How it works
This docker will autobuild any device list given for a specified branch every midnight at 02:00 UTC. In the end, any built ZIP will be moved to the relative volume mapped directory to `/srv/zips`.
2017-01-08 17:37:37 +01:00
2017-01-08 17:50:24 +01:00
> **IMPORTANT:** Remember to use VOLUME mapping. By default Docker creates container with max 10GB of Space. If you will not map volumes, the docker will just break during Source syncronization!
## Configuration
You can configure the Docker by passing custom environment variables to it. See the [Dockerfile](Dockerfile#L11) for more details.
2017-01-08 17:37:37 +01:00
## How to use
### Simple mode
2017-01-08 19:49:38 +01:00
build cm14.1 LineageOS for `hammerhead` with default settings
2017-01-08 17:37:37 +01:00
```
docker run \
--restart=always \
-d \
2017-01-08 19:49:38 +01:00
-e "USER_NAME=John Doe" \
-e "USER_MAIL=john.doe@awesome.email" \
2017-01-08 17:37:37 +01:00
-e "DEVICE_LIST=hammerhead" \
-v "/home/user/ccache:/srv/ccache" \
-v "/home/user/source:/srv/src" \
-v "/home/user/zips:/srv/zips" \
2017-01-08 17:37:37 +01:00
julianxhokaxhiu/docker-lineage-cicd
```
### Advanced mode
build cm-13.0 LineageOS for `hammerhead` and `bullhead`
```
docker run \
--restart=always \
-d \
2017-01-08 19:49:38 +01:00
-e "USER_NAME=John Doe" \
-e "USER_MAIL=john.doe@awesome.email" \
2017-01-08 17:37:37 +01:00
-e "BRANCH_NAME=cm-13.0" \
-e "DEVICE_LIST=hammerhead,bullhead" \
-v "/home/user/ccache:/srv/ccache" \
-v "/home/user/source:/srv/src" \
-v "/home/user/zips:/srv/zips" \
2017-01-08 17:37:37 +01:00
julianxhokaxhiu/docker-lineage-cicd
2017-01-08 19:49:38 +01:00
```
### Expert mode
2017-01-21 13:54:11 +01:00
build cm-14.1 LineageOS for a device that doesn't exist inside the main project, but comes from a special manifest ( has to be created inside `/home/user/local_manifests/` ). Finally provide a custom OTA URL for this ROM so users can update using built-in OTA Updater.
2017-01-08 19:49:38 +01:00
```
docker run \
--restart=always \
-d \
-e "USER_NAME=John Doe" \
-e "USER_MAIL=john.doe@awesome.email" \
-e "BRANCH_NAME=cm-14.1" \
-e "DEVICE_LIST=n80xx" \
-e "OTA_URL=http://cool.domain/api" \
-v "/home/user/ccache:/srv/ccache" \
-v "/home/user/source:/srv/src" \
-v "/home/user/zips:/srv/zips" \
2017-01-21 13:54:11 +01:00
-v "/home/user/local_manifests:/srv/local_manifests" \
2017-01-08 19:49:38 +01:00
julianxhokaxhiu/docker-lineage-cicd
```
2017-01-21 13:54:11 +01:00
**NOTE:** `/home/user/local_manifests/` may contain multiple XMLs, since all the files will be then copied inside `.repo/local_manifests/`