Skip to content

An application container (docker) build script for the BrewTroller Cloud Compiler Daemon

License

Notifications You must be signed in to change notification settings

BrewTroller/BTCompilerApplication

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BrewTroller Cloud Compiler Container

Build Status Docker Build Status

A dockerized version of the BrewTroller Cloud Compiler Service.

Build the container

After cloning this repository, use the command

$ cd BTCompilerApplication
$ docker build -t btccs:latest ./

to build the container. All necessary dependancies will be fetched automatically during the container build process.

Setting up a local Dev environement

In order to use the compiler service during local development the following is required:

Setup:

  1. Clone the BrewTroller code repository: $ git clone https://github.com/BrewTroller/BrewTroller-Official
  2. Start a btccs container, pointing at your local BrewTroller source code:
$ docker run -d -v <absolute path to local brewtroller clone>:/localbt \
-p 8080:8080 --entrypoint /var/BTCCS/BTCloudCompilerService btccs:latest \
-git=/localbt -poll=0m30s

Note: You can modify the rate at which the service will check your local clone of BrewTroller source for updates by changing the poll value passed to the container in the command above.

  1. Point your copy of BrewTroller Update at your local BTCCS container. At this time the easiest way to accompilish this is to add an entry for build.brewtroller.net to your machine's hosts file, pointing to 127.0.0.1
  2. Modify the local copy of the BrewTroller source code as required, commiting your changes locally. Any commits that you wish to make available to the BTCCS container need to be tagged with the format vX.X.X where X is any integer number.

Using the container for local manual building

The container contains everything that is necessary to compile the BrewTroller firmware. Optionally, it can be used to compile the firmware locally, without using BrewTroller Update, and without installing all of the dependancies directly onto your local machine.

  1. Start a container, with the directory of your local BrewTroller firmware code mounted inside the container:
$ docker run -it -v <absolute path to local brewtroller clone>:/localbt \
--entrypoint /bin/sh brewtroller/btccs:latest
  1. From here, you can compile the firmware as you normally would, for example:
$ cd /localbt
$ mkdir build
$ cd build
$ cmake -Dboard=BT_PHOENIX_SINGLE_VESSEL ../
$ make
  1. If you compiled the firmware in the build directory, like in the example in step 2, the build products will be available in the build sub-directory of your local clone of the BrewTroller Firmware.

  2. Once you are done, you can remove the the cloud compiler container from your system using the command: docker rm -f $(docker ps -a -q -f "ancestor=brewtroller/btccs:latest")

About

An application container (docker) build script for the BrewTroller Cloud Compiler Daemon

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages