mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-25 19:56:30 +00:00
use actual builded safeboot firmwares for all esp32 env (Github Actions only) (#16915)
This commit is contained in:
parent
0d45590ac4
commit
e2391c33e7
148
.github/workflows/Tasmota_build_devel.yml
vendored
148
.github/workflows/Tasmota_build_devel.yml
vendored
@ -1,12 +1,13 @@
|
|||||||
|
|
||||||
name: Build_development
|
name: Build_development
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch: # Manually start a workflow
|
workflow_dispatch: # Manually start a workflow
|
||||||
push:
|
push:
|
||||||
branches: development
|
branches: development
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- '.github/**' # Ignore changes towards the .github directory
|
- '.github/**' # Ignore changes towards the .github directory
|
||||||
- '**.md' # Do no build if *.md files changes
|
- '**.md' # Do no build if *.md files changes
|
||||||
|
|
||||||
# Ensures that only one deploy task per branch/environment will run at a time.
|
# Ensures that only one deploy task per branch/environment will run at a time.
|
||||||
concurrency:
|
concurrency:
|
||||||
@ -14,38 +15,13 @@ concurrency:
|
|||||||
cancel-in-progress: true
|
cancel-in-progress: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
base-images:
|
safeboot-images:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: github.repository == 'arendst/Tasmota'
|
if: github.repository == 'arendst/Tasmota'
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
variant:
|
variant:
|
||||||
- tasmota
|
|
||||||
- tasmota4M
|
|
||||||
- tasmota-minimal
|
|
||||||
- tasmota-display
|
|
||||||
- tasmota-ir
|
|
||||||
- tasmota-knx
|
|
||||||
- tasmota-lite
|
|
||||||
- tasmota-sensors
|
|
||||||
- tasmota-zbbridge
|
|
||||||
- tasmota-zigbee
|
|
||||||
- tasmota32
|
|
||||||
- tasmota32-zbbrdgpro
|
|
||||||
- tasmota32-webcam
|
|
||||||
- tasmota32-bluetooth
|
|
||||||
- tasmota32-nspanel
|
|
||||||
- tasmota32-display
|
|
||||||
- tasmota32-ir
|
|
||||||
- tasmota32-lvgl
|
|
||||||
- tasmota32c3
|
|
||||||
- tasmota32c3cdc
|
|
||||||
- tasmota32s2
|
|
||||||
- tasmota32s2cdc
|
|
||||||
- tasmota32s3
|
|
||||||
- tasmota32s3cdc
|
|
||||||
- tasmota32solo1
|
|
||||||
- tasmota32solo1-safeboot
|
- tasmota32solo1-safeboot
|
||||||
- tasmota32-safeboot
|
- tasmota32-safeboot
|
||||||
- tasmota32c3-safeboot
|
- tasmota32c3-safeboot
|
||||||
@ -68,12 +44,102 @@ jobs:
|
|||||||
pip install -U platformio
|
pip install -U platformio
|
||||||
- name: Run PlatformIO
|
- name: Run PlatformIO
|
||||||
run: platformio run -e ${{ matrix.variant }}
|
run: platformio run -e ${{ matrix.variant }}
|
||||||
- uses: actions/upload-artifact@v3
|
- name: Upload safeboot firmware artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: firmware_safeboot
|
||||||
|
path: ./build_output
|
||||||
|
|
||||||
|
base-images:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: github.repository == 'arendst/Tasmota'
|
||||||
|
continue-on-error: true
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
variant:
|
||||||
|
- tasmota
|
||||||
|
- tasmota4M
|
||||||
|
- tasmota-minimal
|
||||||
|
- tasmota-display
|
||||||
|
- tasmota-ir
|
||||||
|
- tasmota-knx
|
||||||
|
- tasmota-lite
|
||||||
|
- tasmota-sensors
|
||||||
|
- tasmota-zbbridge
|
||||||
|
- tasmota-zigbee
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
ref: development
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v4
|
||||||
|
with:
|
||||||
|
python-version: '3.x'
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
pip install wheel
|
||||||
|
pip install -U platformio
|
||||||
|
- name: Run PlatformIO
|
||||||
|
run: platformio run -e ${{ matrix.variant }}
|
||||||
|
- name: Upload firmware artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: firmware
|
||||||
|
path: ./build_output
|
||||||
|
|
||||||
|
base32-images:
|
||||||
|
needs: safeboot-images
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: github.repository == 'arendst/Tasmota'
|
||||||
|
continue-on-error: true
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
variant:
|
||||||
|
- tasmota32
|
||||||
|
- tasmota32-zbbrdgpro
|
||||||
|
- tasmota32-webcam
|
||||||
|
- tasmota32-bluetooth
|
||||||
|
- tasmota32-nspanel
|
||||||
|
- tasmota32-display
|
||||||
|
- tasmota32-ir
|
||||||
|
- tasmota32-lvgl
|
||||||
|
- tasmota32c3
|
||||||
|
- tasmota32c3cdc
|
||||||
|
- tasmota32s2
|
||||||
|
- tasmota32s2cdc
|
||||||
|
- tasmota32s3
|
||||||
|
- tasmota32s3cdc
|
||||||
|
- tasmota32solo1
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
ref: development
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v4
|
||||||
|
with:
|
||||||
|
python-version: '3.x'
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
pip install wheel
|
||||||
|
pip install -U platformio
|
||||||
|
- name: Download safeboot firmwares
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: firmware_safeboot
|
||||||
|
path: ./firmware
|
||||||
|
- name: Display downloaded files
|
||||||
|
run: |
|
||||||
|
ls -R ./firmware/
|
||||||
|
- name: Run PlatformIO
|
||||||
|
run: platformio run -e ${{ matrix.variant }}
|
||||||
|
- name: Upload firmware artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: firmware
|
name: firmware
|
||||||
path: ./build_output
|
path: ./build_output
|
||||||
|
|
||||||
language-images:
|
language-images:
|
||||||
|
needs: safeboot-images
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: github.repository == 'arendst/Tasmota'
|
if: github.repository == 'arendst/Tasmota'
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
@ -93,22 +159,37 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
pip install wheel
|
pip install wheel
|
||||||
pip install -U platformio
|
pip install -U platformio
|
||||||
|
- name: Download safeboot firmwares
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: firmware_safeboot
|
||||||
|
path: ./firmware
|
||||||
|
- name: Display downloaded files
|
||||||
|
run: |
|
||||||
|
ls -R ./firmware/
|
||||||
- name: Run PlatformIO
|
- name: Run PlatformIO
|
||||||
run: platformio run -e ${{ matrix.variant }}-${{ matrix.language }}
|
run: platformio run -e ${{ matrix.variant }}-${{ matrix.language }}
|
||||||
- uses: actions/upload-artifact@v3
|
- name: Upload language firmware artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: firmware
|
name: firmware
|
||||||
path: ./build_output
|
path: ./build_output
|
||||||
|
|
||||||
Upload:
|
Upload:
|
||||||
needs: [base-images, language-images]
|
needs: [base-images, base32-images, language-images]
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/download-artifact@v3
|
- name: Download firmware
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: firmware
|
name: firmware
|
||||||
path: ./mv_firmware
|
path: ./mv_firmware
|
||||||
|
- name: Downlaod safeboot firmware
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: firmware_safeboot
|
||||||
|
path: ./mv_firmware
|
||||||
- name: Display structure of downloaded files
|
- name: Display structure of downloaded files
|
||||||
run: ls -R
|
run: ls -R
|
||||||
working-directory: ./mv_firmware
|
working-directory: ./mv_firmware
|
||||||
@ -159,7 +240,6 @@ jobs:
|
|||||||
destination_branch: 'firmware'
|
destination_branch: 'firmware'
|
||||||
user_email: 'github-actions@github.com'
|
user_email: 'github-actions@github.com'
|
||||||
user_name: 'github-actions'
|
user_name: 'github-actions'
|
||||||
|
|
||||||
Start_final_copy:
|
Start_final_copy:
|
||||||
needs: Upload
|
needs: Upload
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
137
.github/workflows/Tasmota_build_master.yml
vendored
137
.github/workflows/Tasmota_build_master.yml
vendored
@ -1,11 +1,12 @@
|
|||||||
name: Build_firmware_master
|
name: Build_firmware_master
|
||||||
|
|
||||||
on:
|
on:
|
||||||
|
workflow_dispatch: # Manually start a workflow
|
||||||
push:
|
push:
|
||||||
branches: master
|
branches: master
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- '.github/**' # Ignore changes towards the .github directory
|
- '.github/**' # Ignore changes towards the .github directory
|
||||||
- '**.md' # Do no build if *.md files changes
|
- '**.md' # Do no build if *.md files changes
|
||||||
|
|
||||||
# Ensures that only one deploy task per branch/environment will run at a time.
|
# Ensures that only one deploy task per branch/environment will run at a time.
|
||||||
concurrency:
|
concurrency:
|
||||||
@ -13,38 +14,13 @@ concurrency:
|
|||||||
cancel-in-progress: true
|
cancel-in-progress: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
base-images:
|
safeboot-images:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: github.repository == 'arendst/Tasmota'
|
if: github.repository == 'arendst/Tasmota'
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
variant:
|
variant:
|
||||||
- tasmota
|
|
||||||
- tasmota4M
|
|
||||||
- tasmota-minimal
|
|
||||||
- tasmota-display
|
|
||||||
- tasmota-ir
|
|
||||||
- tasmota-knx
|
|
||||||
- tasmota-lite
|
|
||||||
- tasmota-sensors
|
|
||||||
- tasmota-zbbridge
|
|
||||||
- tasmota-zigbee
|
|
||||||
- tasmota32
|
|
||||||
- tasmota32-zbbrdgpro
|
|
||||||
- tasmota32-webcam
|
|
||||||
- tasmota32-bluetooth
|
|
||||||
- tasmota32-nspanel
|
|
||||||
- tasmota32-display
|
|
||||||
- tasmota32-ir
|
|
||||||
- tasmota32-lvgl
|
|
||||||
- tasmota32c3
|
|
||||||
- tasmota32c3cdc
|
|
||||||
- tasmota32s2
|
|
||||||
- tasmota32s2cdc
|
|
||||||
- tasmota32s3
|
|
||||||
- tasmota32s3cdc
|
|
||||||
- tasmota32solo1
|
|
||||||
- tasmota32solo1-safeboot
|
- tasmota32solo1-safeboot
|
||||||
- tasmota32-safeboot
|
- tasmota32-safeboot
|
||||||
- tasmota32c3-safeboot
|
- tasmota32c3-safeboot
|
||||||
@ -67,12 +43,102 @@ jobs:
|
|||||||
pip install -U platformio
|
pip install -U platformio
|
||||||
- name: Run PlatformIO
|
- name: Run PlatformIO
|
||||||
run: platformio run -e ${{ matrix.variant }}
|
run: platformio run -e ${{ matrix.variant }}
|
||||||
- uses: actions/upload-artifact@v3
|
- name: Upload safeboot firmware artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: firmware_safeboot
|
||||||
|
path: ./build_output
|
||||||
|
|
||||||
|
base-images:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: github.repository == 'arendst/Tasmota'
|
||||||
|
continue-on-error: true
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
variant:
|
||||||
|
- tasmota
|
||||||
|
- tasmota4M
|
||||||
|
- tasmota-minimal
|
||||||
|
- tasmota-display
|
||||||
|
- tasmota-ir
|
||||||
|
- tasmota-knx
|
||||||
|
- tasmota-lite
|
||||||
|
- tasmota-sensors
|
||||||
|
- tasmota-zbbridge
|
||||||
|
- tasmota-zigbee
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
ref: master
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v4
|
||||||
|
with:
|
||||||
|
python-version: '3.x'
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
pip install wheel
|
||||||
|
pip install -U platformio
|
||||||
|
- name: Run PlatformIO
|
||||||
|
run: platformio run -e ${{ matrix.variant }}
|
||||||
|
- name: Upload firmware artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: firmware
|
||||||
|
path: ./build_output
|
||||||
|
|
||||||
|
base32-images:
|
||||||
|
needs: safeboot-images
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: github.repository == 'arendst/Tasmota'
|
||||||
|
continue-on-error: true
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
variant:
|
||||||
|
- tasmota32
|
||||||
|
- tasmota32-zbbrdgpro
|
||||||
|
- tasmota32-webcam
|
||||||
|
- tasmota32-bluetooth
|
||||||
|
- tasmota32-nspanel
|
||||||
|
- tasmota32-display
|
||||||
|
- tasmota32-ir
|
||||||
|
- tasmota32-lvgl
|
||||||
|
- tasmota32c3
|
||||||
|
- tasmota32c3cdc
|
||||||
|
- tasmota32s2
|
||||||
|
- tasmota32s2cdc
|
||||||
|
- tasmota32s3
|
||||||
|
- tasmota32s3cdc
|
||||||
|
- tasmota32solo1
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
with:
|
||||||
|
ref: master
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v4
|
||||||
|
with:
|
||||||
|
python-version: '3.x'
|
||||||
|
- name: Install dependencies
|
||||||
|
run: |
|
||||||
|
pip install wheel
|
||||||
|
pip install -U platformio
|
||||||
|
- name: Download safeboot firmwares
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: firmware_safeboot
|
||||||
|
path: ./firmware
|
||||||
|
- name: Display downloaded files
|
||||||
|
run: |
|
||||||
|
ls -R ./firmware/
|
||||||
|
- name: Run PlatformIO
|
||||||
|
run: platformio run -e ${{ matrix.variant }}
|
||||||
|
- name: Upload firmware artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: firmware
|
name: firmware
|
||||||
path: ./build_output
|
path: ./build_output
|
||||||
|
|
||||||
language-images:
|
language-images:
|
||||||
|
needs: safeboot-images
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
if: github.repository == 'arendst/Tasmota'
|
if: github.repository == 'arendst/Tasmota'
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
@ -92,9 +158,18 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
pip install wheel
|
pip install wheel
|
||||||
pip install -U platformio
|
pip install -U platformio
|
||||||
|
- name: Download safeboot firmwares
|
||||||
|
uses: actions/download-artifact@v3
|
||||||
|
with:
|
||||||
|
name: firmware_safeboot
|
||||||
|
path: ./firmware
|
||||||
|
- name: Display downloaded files
|
||||||
|
run: |
|
||||||
|
ls -R ./firmware/
|
||||||
- name: Run PlatformIO
|
- name: Run PlatformIO
|
||||||
run: platformio run -e ${{ matrix.variant }}-${{ matrix.language }}
|
run: platformio run -e ${{ matrix.variant }}-${{ matrix.language }}
|
||||||
- uses: actions/upload-artifact@v3
|
- name: Upload language firmware artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: firmware
|
name: firmware
|
||||||
path: ./build_output
|
path: ./build_output
|
||||||
@ -112,7 +187,7 @@ jobs:
|
|||||||
- name: Display structure of downloaded files
|
- name: Display structure of downloaded files
|
||||||
run: ls -R ./mv_firmware/
|
run: ls -R ./mv_firmware/
|
||||||
- name: Release
|
- name: Release
|
||||||
uses: softprops/action-gh-release@v1
|
uses: jason2866/action-gh-release@v1.1
|
||||||
#if: startsWith(github.ref, 'refs/tags/')
|
#if: startsWith(github.ref, 'refs/tags/')
|
||||||
with:
|
with:
|
||||||
tag_name: ${{ github.run_number }}
|
tag_name: ${{ github.run_number }}
|
||||||
|
@ -33,15 +33,22 @@ import subprocess
|
|||||||
sys.path.append(join(platform.get_package_dir("tool-esptoolpy")))
|
sys.path.append(join(platform.get_package_dir("tool-esptoolpy")))
|
||||||
import esptool
|
import esptool
|
||||||
|
|
||||||
|
github_actions = os.getenv('GITHUB_ACTIONS')
|
||||||
extra_flags = ''.join([element.replace("-D", " ") for element in env.BoardConfig().get("build.extra_flags", "")])
|
extra_flags = ''.join([element.replace("-D", " ") for element in env.BoardConfig().get("build.extra_flags", "")])
|
||||||
build_flags = ''.join([element.replace("-D", " ") for element in env.GetProjectOption("build_flags")])
|
build_flags = ''.join([element.replace("-D", " ") for element in env.GetProjectOption("build_flags")])
|
||||||
|
|
||||||
if "CORE32SOLO1" in extra_flags or "FRAMEWORK_ARDUINO_SOLO1" in build_flags:
|
if "CORE32SOLO1" in extra_flags or "FRAMEWORK_ARDUINO_SOLO1" in build_flags:
|
||||||
FRAMEWORK_DIR = platform.get_package_dir("framework-arduino-solo1")
|
FRAMEWORK_DIR = platform.get_package_dir("framework-arduino-solo1")
|
||||||
|
if github_actions and os.path.exists("./firmware/firmware"):
|
||||||
|
shutil.copytree("./firmware/firmware", "/home/runner/.platformio/packages/framework-arduino-solo1/variants/tasmota")
|
||||||
elif "CORE32ITEAD" in extra_flags or "FRAMEWORK_ARDUINO_ITEAD" in build_flags:
|
elif "CORE32ITEAD" in extra_flags or "FRAMEWORK_ARDUINO_ITEAD" in build_flags:
|
||||||
FRAMEWORK_DIR = platform.get_package_dir("framework-arduino-ITEAD")
|
FRAMEWORK_DIR = platform.get_package_dir("framework-arduino-ITEAD")
|
||||||
|
if github_actions and os.path.exists("./firmware/firmware"):
|
||||||
|
shutil.copytree("./firmware/firmware", "/home/runner/.platformio/packages/framework-arduino-ITEAD/variants/tasmota")
|
||||||
else:
|
else:
|
||||||
FRAMEWORK_DIR = platform.get_package_dir("framework-arduinoespressif32")
|
FRAMEWORK_DIR = platform.get_package_dir("framework-arduinoespressif32")
|
||||||
|
if github_actions and os.path.exists("./firmware/firmware"):
|
||||||
|
shutil.copytree("./firmware/firmware", "/home/runner/.platformio/packages/framework-arduinoespressif32/variants/tasmota")
|
||||||
|
|
||||||
variants_dir = join(FRAMEWORK_DIR, "variants", "tasmota")
|
variants_dir = join(FRAMEWORK_DIR, "variants", "tasmota")
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user