Skip to content

Commit f0fe6b8

Browse files
authored
ci: Update configuration to optimise ci duration
2 parents bba73e3 + 620c30a commit f0fe6b8

9 files changed

Lines changed: 53 additions & 32 deletions

.github/workflows/esphome_compilation.yml

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -26,34 +26,35 @@ jobs:
2626
run: |
2727
echo "wifi_ssid: \"myWifiSsid\"" > secrets.yaml
2828
echo "wifi_password: \"myWifiPassword\"" >> secrets.yaml
29-
echo "solar_router_ota_password: \"mySolarRouterOtaPassword\"" >> secrets.yaml
29+
echo "ota_password: \"mySolarRouterOtaPassword\"" >> secrets.yaml
3030
echo "api_encryption_key: \"8q4u9dNBGMcsPemx+Q+WzLTU+mLXHAgPsrTpGjyV1hs=\"" >> secrets.yaml
3131
echo "hotspot_password: \"myHotspotPassword\"" >> secrets.yaml
3232
echo "proxy_api_encryption_key: \"8q4u9dNBGMcsPemx+Q+WzLTU+mLXHAgPsrTpGjyV1hs=\"" >> secrets.yaml
3333
3434
- name: Compile esp32-proxy-client.yaml
3535
continue-on-error: true
36-
run: esphome compile esp32-proxy-client.yaml
36+
run: tools/convert_to_local_source_for_ci.sh esp32-proxy-client.yaml && esphome compile work_in_progress.yaml
3737
id: conf1
3838

39-
- name: Compile esp32-standalone.yaml
39+
- name: Compile wt32-eth01-solar-water-heater.yaml
4040
continue-on-error: true
41-
run: esphome compile esp32-standalone.yaml
41+
run: tools/convert_to_local_source_for_ci.sh wt32-eth01-solar-water-heater.yaml && esphome compile work_in_progress.yaml
4242
id: conf2
4343

44-
- name: Compile esp8266-proof-of-concept.yaml
44+
- name: Compile esp8266-standalone_on_off.yaml
4545
continue-on-error: true
46-
run: esphome compile esp8266-proof-of-concept.yaml
46+
run: tools/convert_to_local_source_for_ci.sh esp8266-standalone_on_off.yaml && esphome compile work_in_progress.yaml
4747
id: conf3
4848

4949
- name: Compile esp8285-power-meter-proxy.yaml
5050
continue-on-error: true
51-
run: esphome compile esp8285-power-meter-proxy.yaml
51+
run: tools/convert_to_local_source_for_ci.sh esp8285-power-meter-proxy.yaml && esphome compile work_in_progress.yaml
5252
id: conf4
5353

5454
- name: Check for compile errors
5555
run: |
5656
if [ ${{ steps.conf1.outcome }} == 'failure' ] || [ ${{ steps.conf2.outcome }} == 'failure' || ${{ steps.conf3.outcome }} == 'failure' ] || [ ${{ steps.conf4.outcome }} == 'failure']; then
5757
echo "One or more compilations failed"
5858
exit 1
59-
fi
59+
fi
60+

docs/compile_coverage.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
## wt32-eth01-solar-water-heater
2+
* common.yaml
3+
* power_meter_fronius.yaml
4+
* regulator_triac.yaml
5+
* engine.yaml
6+
* energy_counter_theorical.yaml
7+
* temperature_limiter_DS18B20.yaml
8+
9+
## esp8285-power-meter-proxy
10+
* power_meter_shelly_em.yaml
11+
12+
## esp8266-standalone_on_off
13+
* power_meter_home_assistant.yaml
14+
* engine_on_off.yaml
15+
* regulator_mecanical_relay.yaml
16+
* temperature_limiter_home_assistant.yaml
17+
18+
## esp32-proxy-client
19+
* power_meter_proxy_client.yaml
20+
* engine.yaml
21+
* regulator_solid_state_relay.yaml

esp32-proxy-client.yaml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -68,17 +68,13 @@ substitutions:
6868
yellow_led_pin: GPIO18
6969

7070
packages:
71-
common:
72-
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
73-
file: solar_router/common.yaml
74-
refresh: 1d
7571
power_meter:
7672
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
7773
file: solar_router/power_meter_proxy_client.yaml
7874
refresh: 1d
7975
regulator:
8076
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
81-
file: solar_router/regulator_triac.yaml
77+
file: solar_router/regulator_solid_state_relay.yaml
8278
refresh: 1d
8379
solar_router:
8480
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/

esp32-standalone.yaml

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -75,10 +75,6 @@ substitutions:
7575
green_led_pin: GPIO19
7676
yellow_led_pin: GPIO18
7777

78-
# Temperature sensor
79-
temperature_sensor: "input_number.test_temperature"
80-
red_led_pin: GPIO4
81-
8278

8379
packages:
8480
common:
@@ -92,13 +88,9 @@ packages:
9288
regulator:
9389
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
9490
file: solar_router/regulator_triac.yaml
95-
# file: solar_router/regulator_relay.yaml
9691
refresh: 1d
9792
engine:
9893
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
9994
file: solar_router/engine.yaml
10095
refresh: 1d
101-
temperature_limiter:
102-
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
103-
file: solar_router/temperature_limiter_home_assistant.yaml
104-
refresh: 1d
96+

esp8266-standalone_on_off.yaml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,10 @@ substitutions:
5050
# Define GPIO pin connected to mecanical relay.
5151
regulator_gate_pin: GPIO0
5252

53+
# Temperature sensor
54+
temperature_sensor: "input_number.test_temperature"
55+
red_led_pin: GPIO4
56+
5357
packages:
5458
common:
5559
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
@@ -67,3 +71,7 @@ packages:
6771
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
6872
file: solar_router/engine_on_off.yaml
6973
refresh: 1d
74+
temperature_limiter:
75+
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
76+
file: solar_router/temperature_limiter_home_assistant.yaml
77+
refresh: 1d

esp8285-power-meter-proxy.yaml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,6 @@ substitutions:
5151
power_meter_activated_at_start: "1"
5252

5353
packages:
54-
common:
55-
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
56-
file: solar_router/common.yaml
57-
refresh: 1d
5854
power_meter:
5955
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
6056
file: solar_router/power_meter_shelly_em.yaml
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#!/bin/bash
2+
cat $1 | grep -v "url:.*" | sed "s/file: /<<: \!include / " | sed "s/ name: .*/ name: solarrouter/" | sed "s/ friendly_name: .*/ friendly_name: solarrouter/" | sed "s/ key: !secret .*/ key: !secret api_encryption_key/" | sed "s/ password: !secret .*/ password: !secret ota_password/" | grep -v "refresh:" > work_in_progress.yaml
Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
# ----------------------------------------------------------------------------------------------------
44

55
esphome:
6-
name: wt32-eth01-2
7-
friendly_name: wt32-eth01-2
6+
name: "solar-water-heater"
7+
friendly_name: "solar-water-heater"
88

99
esp32:
1010
board: wt32-eth01
@@ -23,12 +23,12 @@ logger:
2323
# Enable Home Assistant API
2424
api:
2525
encryption:
26-
key: !secret wt32_eth01_2_api_encryption_key
26+
key: !secret solar_water_heater_api_encryption_key
2727

2828
# Enable over-the-air updates
2929
ota:
3030
- platform: esphome
31-
password: !secret wt32_eth01_2_ota_password
31+
password: !secret solar_water_heater_ota_password
3232

3333
# WiFi connection
3434
# To activate WiFi :
@@ -79,7 +79,12 @@ substitutions:
7979
# Temperature sensor
8080
DS18B20_pin: GPIO02
8181
temperature_update_interval: 1s
82-
red_led_pin: GPIO4
82+
83+
# Safety limit LED
84+
red_led_pin: GPIO5
85+
86+
# Fan control
87+
fan_control_pin: GPIO4
8388

8489
packages:
8590
common:
@@ -102,7 +107,7 @@ packages:
102107
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
103108
file: solar_router/energy_counter_theorical.yaml
104109
refresh: 1d
105-
temperature_limmiter:
110+
temperature_limiter:
106111
url: https://github.com/XavierBerger/Solar-Router-for-ESPHome/
107112
file: solar_router/temperature_limiter_DS18B20.yaml
108113
refresh: 1d

0 commit comments

Comments
 (0)