From 4f1b4ca8e44b7167cccc15f1769ca1081a970d02 Mon Sep 17 00:00:00 2001 From: blakadder Date: Fri, 15 Nov 2019 18:58:03 +0100 Subject: [PATCH] remove outdated docker container --- build-container/Dockerfile | 24 ------------- build-container/README.md | 26 -------------- build-container/entrypoint.sh | 35 ------------------- .../init_pio_tasmota/platformio.ini | 30 ---------------- build-container/init_pio_tasmota/src/main.cpp | 3 -- 5 files changed, 118 deletions(-) delete mode 100644 build-container/Dockerfile delete mode 100644 build-container/README.md delete mode 100644 build-container/entrypoint.sh delete mode 100755 build-container/init_pio_tasmota/platformio.ini delete mode 100644 build-container/init_pio_tasmota/src/main.cpp diff --git a/build-container/Dockerfile b/build-container/Dockerfile deleted file mode 100644 index a5852d41c..000000000 --- a/build-container/Dockerfile +++ /dev/null @@ -1,24 +0,0 @@ -FROM python:2 - -LABEL author="Eduard Angold" - -# Install platformio. To be able to build tasmota <=v6.6.0 (and later) -# we have to use version 3.6.7 of platformio. -RUN pip install --upgrade pip &&\ - pip install -U platformio==3.6.7 - -# Init project -COPY init_pio_tasmota /init_pio_tasmota - -# Install project dependencies using a init project. -RUN cd /init_pio_tasmota &&\ - pio run &&\ - cd ../ &&\ - rm -fr init_pio_tasmota &&\ - cp -r /root/.platformio / &&\ - chmod -R 777 /.platformio - -COPY entrypoint.sh /entrypoint.sh - -ENTRYPOINT ["/bin/bash", "/entrypoint.sh"] - diff --git a/build-container/README.md b/build-container/README.md deleted file mode 100644 index 64754f4f1..000000000 --- a/build-container/README.md +++ /dev/null @@ -1,26 +0,0 @@ -# Docker container for tasmota builds -This Container will setup a proper build environment for [Tasmota](https://github.com/arendst/Tasmota) - -## Create container -`docker build -t mytasmota:latest .` - -## Use a ready container from docker hub -Use instead of the container `mytasmota:latest` the published container `eddyhub/docker-tasmota:latest` from docker hub. - -## Build all development binaries -`git clone https://github.com/arendst/Tasmota.git` -`docker run -ti --rm -v $(pwd)/Tasmota:/tasmota -u $UID:$GID mytasmota:latest` - -## Build a specific binary with custom options -Checkout Tasmota: `git clone https://github.com/arendst/Tasmota.git` -Mount the source as volume in `/tasmota`. **Prefix** any parameter available in `Tasmota/sonoff/my_user_config.h` with `TASMOTA_` as a environment variable for the container. **Also don't forget to escape what needs to be escaped in your shell.** **Strings** should be in **double quotes**. My config example: -`docker run -ti --rm -v $(pwd)/Tasmota:/tasmota -e TASMOTA_STA_SSID1='"my-wifi"' -e TASMOTA_STA_PASS1='"my-wifi-password"' -e TASMOTA_MQTT_HOST='my-mqtt-host' -e TASMOTA_MQTT_USER='"my-mqtt-user"' -e TASMOTA_MQTT_PASS='"my-mqtt-password"' -e TASMOTA_WEB_PASSWORD='"my-web-password"' -u $UID:$GID mytasmota:latest --environment sonoff-DE` - -Now you should have the file Tasmota/.pioenvs/sonoff-DE/firmware.bin which can be flashed on your device. - -## Build a specific version of tasmota -Checkout out the needed version before using the build instructions above: -- `git clone https://github.com/arendst/Tasmota.git` -- `git -C Tasmota checkout v6.6.0` -Build it: -- `docker run -ti --rm -v $(pwd)/Tasmota:/tasmota -u $UID:$GID mytasmota:latest` diff --git a/build-container/entrypoint.sh b/build-container/entrypoint.sh deleted file mode 100644 index 8be6c11be..000000000 --- a/build-container/entrypoint.sh +++ /dev/null @@ -1,35 +0,0 @@ -# configure build via environment -#!/bin/bash - -TASMOTA_VOLUME='/tasmota' -USER_CONFIG_OVERRIDE="${TASMOTA_VOLUME}/tasmota/user_config_override.h" - -if [ -d $TASMOTA_VOLUME ]; then - cd $TASMOTA_VOLUME - if [ -n "$(env | grep ^TASMOTA_)" ]; then - echo "Removing $USER_CONFIG_OVERRIDE and creating a new one." - rm "$USER_CONFIG_OVERRIDE" - #export PLATFORMIO_BUILD_FLAGS='-DUSE_CONFIG_OVERRIDE' - sed -i 's/^; *-DUSE_CONFIG_OVERRIDE/ -DUSE_CONFIG_OVERRIDE/' platformio.ini - echo '#ifndef _USER_CONFIG_OVERRIDE_H_' >> $USER_CONFIG_OVERRIDE - echo '#define _USER_CONFIG_OVERRIDE_H_' >> $USER_CONFIG_OVERRIDE - echo '#warning **** user_config_override.h: Using Settings from this File ****' >> $USER_CONFIG_OVERRIDE - echo '#undef CFG_HOLDER' >> $USER_CONFIG_OVERRIDE - echo '#define CFG_HOLDER 1' >> $USER_CONFIG_OVERRIDE - for i in $(env | grep ^TASMOTA_); do - config=${i#TASMOTA_} - key=$(echo $config | cut -d '=' -f 1) - value=$(echo $config | cut -d '=' -f 2) - echo "#undef ${key}" >> $USER_CONFIG_OVERRIDE - echo "#define ${key} ${value}" >> $USER_CONFIG_OVERRIDE - done - echo '#endif' >> $USER_CONFIG_OVERRIDE - fi - echo "Compiling..." - #pio run -t clean - pio run $@ - echo "Everything done you find your builds in .pioenvs//firmware.bin" -else - echo ">>> NO TASMOTA VOLUME MOUNTED --> EXITING" - exit 0; -fi diff --git a/build-container/init_pio_tasmota/platformio.ini b/build-container/init_pio_tasmota/platformio.ini deleted file mode 100755 index 058e9064f..000000000 --- a/build-container/init_pio_tasmota/platformio.ini +++ /dev/null @@ -1,30 +0,0 @@ -[env:core_2_3_0] -; *** Esp8266 core for Arduino version 2.3.0 -platform = espressif8266@1.5.0 -framework = arduino -board = esp01_1m - -[env:core_2_4_2] -; *** Esp8266 core for Arduino version 2.4.2 -platform = espressif8266@1.8.0 -framework = arduino -board = esp01_1m - -[env:core_2_5_2] -; *** Esp8266 core for Arduino version 2.5.2 -platform = espressif8266@~2.2.2 -framework = arduino -board = esp01_1m - -[env:core_stage] -; *** Esp8266 core for Arduino version latest beta -platform = https://github.com/platformio/platform-espressif8266.git#feature/stage -framework = arduino -board = esp01_1m - -[env:core_pre] -; *** Arduino Esp8266 core pre 2.6.x for Tasmota (mqtt reconnects fixed) -platform = https://github.com/Jason2866/platform-espressif8266.git#Tasmota -framework = arduino -board = esp01_1m - diff --git a/build-container/init_pio_tasmota/src/main.cpp b/build-container/init_pio_tasmota/src/main.cpp deleted file mode 100644 index 27f3768b7..000000000 --- a/build-container/init_pio_tasmota/src/main.cpp +++ /dev/null @@ -1,3 +0,0 @@ -#include -void setup() {} -void loop() {}