Controle d'une LED au travers de Home Assistant
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

28 lines
1.1 KiB

3 years ago
3 years ago
3 years ago
3 years ago
  1. production:
  2. image: java:8
  3. variables:
  4. ESPURL: "http://arduino.esp8266.com/stable/package_esp8266com_index.json"
  5. MEMORY: "custom_FlashSize=nodemcuv2_4M3M"
  6. INSTBOARD: "esp8266:esp8266"
  7. BOARD: "${INSTBOARD}:nodemcuv2"
  8. before_script:
  9. - apt update >/dev/null
  10. - cd /
  11. - wget --quiet "https://www.arduino.cc/download.php?f=/arduino-nightly-linux64.tar.xz" -O "arduino-nightly-linux64.tar.xz"
  12. - tar axf "arduino-nightly-linux64.tar.xz"
  13. - /arduino-nightly/arduino --pref "boardsmanager.additional.urls=${ESPURL}"
  14. - /arduino-nightly/arduino --install-boards "${INSTBOARD}"
  15. script:
  16. - cd "${CI_PROJECT_DIR}/arduino"
  17. - cp "mqttled.example.h" "mqttled.h"
  18. - /arduino-nightly/arduino --install-library "FastLED"
  19. - /arduino-nightly/arduino --install-library "PubSubClient"
  20. - /arduino-nightly/arduino --pref "${MEMORY}" --board "${BOARD}" --verify "mqttled.ino"
  21. yaml:
  22. image: "python:alpine"
  23. before_script:
  24. - pip install "PyYAML"
  25. script:
  26. - cd "${CI_PROJECT_DIR}/home-assistant"
  27. - python -c "from yaml import load, Loader; load(open('ha_configuration.yml'), Loader=Loader)"