diff --git a/.github/workflows/push-to-prod.yml b/.github/workflows/push-to-prod.yml index 05b33eae..4a76614e 100644 --- a/.github/workflows/push-to-prod.yml +++ b/.github/workflows/push-to-prod.yml @@ -7,77 +7,29 @@ on: - production jobs: - outdoor-868: + build-prod: runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + sbc: [raspi, rockpi] + frequency: [470, 868, 915] + variant: [indoor, outdoor] steps: - name: Checkout uses: actions/checkout@v2 + - name: Change i2c bus for RockPi + if: matrix.sbc == 'rockpi' + run: | + sed -i -E "s/\/dev\/i2c-1:\/dev\/i2c-1/\/dev\/i2c-7:\/dev\/i2c-7/g" docker-compose.yml + ROCKPI="-rockpi" + echo "ROCKPI=$ROCKPI" >> $GITHUB_ENV - name: Balena Deploy - uses: nebraltd/balena-cli-action@v12.51.1 + uses: nebraltd/balena-cli-action@v12.54.5 if: success() with: balena_api_token: ${{secrets.BALENA_API_TOKEN}} - balena_command: "deploy nebraltd/helium-outdoor-868 --logs --debug --nocache --build" - - indoor-868: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v2 - - name: Balena Deploy - uses: nebraltd/balena-cli-action@v12.51.1 - if: success() - with: - balena_api_token: ${{secrets.BALENA_API_TOKEN}} - balena_command: "deploy nebraltd/helium-indoor-868 --logs --debug --nocache --build" - - outdoor-915: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v2 - - name: Balena Deploy - uses: nebraltd/balena-cli-action@v12.51.1 - if: success() - with: - balena_api_token: ${{secrets.BALENA_API_TOKEN}} - balena_command: "deploy nebraltd/helium-outdoor-915 --logs --debug --nocache --build" - - indoor-915: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v2 - - name: Balena Deploy - uses: nebraltd/balena-cli-action@v12.51.1 - if: success() - with: - balena_api_token: ${{secrets.BALENA_API_TOKEN}} - balena_command: "deploy nebraltd/helium-indoor-915 --logs --debug --nocache --build" - - outdoor-470: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v2 - - name: Balena Deploy - uses: nebraltd/balena-cli-action@v12.51.1 - if: success() - with: - balena_api_token: ${{secrets.BALENA_API_TOKEN}} - balena_command: "deploy nebraltd/helium-outdoor-470 --logs --debug --nocache --build" - - indoor-470: - runs-on: ubuntu-latest - steps: - - name: Checkout - uses: actions/checkout@v2 - - name: Balena Deploy - uses: nebraltd/balena-cli-action@v12.51.1 - if: success() - with: - balena_api_token: ${{secrets.BALENA_API_TOKEN}} - balena_command: "deploy nebraltd/helium-indoor-470 --logs --debug --nocache --build" + balena_command: "deploy nebraltd/helium-${{ matrix.variant }}-${{ matrix.frequency }}${{ env.ROCKPI }} --logs --debug --nocache --build" open-fleet: runs-on: ubuntu-latest @@ -85,7 +37,7 @@ jobs: - name: Checkout uses: actions/checkout@v2 - name: Balena Deploy - uses: nebraltd/balena-cli-action@v12.51.1 + uses: nebraltd/balena-cli-action@v12.54.5 if: success() with: balena_api_token: ${{secrets.BALENA_API_TOKEN}} @@ -97,7 +49,7 @@ jobs: - name: Checkout uses: actions/checkout@v2 - name: Balena Deploy - uses: nebraltd/balena-cli-action@v12.51.1 + uses: nebraltd/balena-cli-action@v12.54.5 if: success() with: balena_api_token: ${{secrets.BALENA_API_TOKEN}} diff --git a/.github/workflows/push-to-testnet.yml b/.github/workflows/push-to-testnet.yml index 9fb81a41..8b88814a 100644 --- a/.github/workflows/push-to-testnet.yml +++ b/.github/workflows/push-to-testnet.yml @@ -9,12 +9,22 @@ on: jobs: testnet: runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + sbc: [raspi, rockpi] steps: - name: Checkout uses: actions/checkout@v2 + - name: Change i2c bus for RockPi + if: matrix.sbc == 'rockpi' + run: | + sed -i -E "s/\/dev\/i2c-1:\/dev\/i2c-1/\/dev\/i2c-7:\/dev\/i2c-7/g" docker-compose.yml + ROCKPI="-rockpi" + echo "ROCKPI=$ROCKPI" >> $GITHUB_ENV - name: Balena Deploy - uses: nebraltd/balena-cli-action@v12.51.1 + uses: nebraltd/balena-cli-action@v12.54.5 if: success() with: balena_api_token: ${{secrets.BALENA_API_TOKEN}} - balena_command: "deploy nebraltd/helium-testnet --logs --debug --nocache --build" + balena_command: "deploy nebraltd/helium-testnet${{ env.ROCKPI }} --logs --debug --nocache --build" diff --git a/docker-compose.yml b/docker-compose.yml index 70a375b6..6f34ea6b 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -3,12 +3,12 @@ version: '2' services: gateway-config: - image: nebraltd/hm-config:e0c6f88 + image: nebraltd/hm-config:8cc544f depends_on: - dbus-session - diagnostics environment: - - FIRMWARE_VERSION=2021.11.22.0-1 + - FIRMWARE_VERSION=2021.11.30.1 - DBUS_SYSTEM_BUS_ADDRESS=unix:path=/host/run/dbus/system_bus_socket - DBUS_SESSION_BUS_ADDRESS=unix:path=/session/dbus/session_bus_socket privileged: true @@ -34,7 +34,7 @@ services: - pktfwdr:/var/pktfwd helium-miner: - image: nebraltd/hm-miner:arm64-d760384 + image: nebraltd/hm-miner:arm64-3565d25 depends_on: - dbus-session - diagnostics @@ -50,16 +50,19 @@ services: - dbus:/session/dbus cap_add: - SYS_RAWIO - privileged: true + devices: + - /dev/i2c-1:/dev/i2c-1 restart: on-failure environment: - DBUS_SYSTEM_BUS_ADDRESS=unix:path=/session/dbus/session_bus_socket - RELEASE_BUMPER=foobar diagnostics: - image: nebraltd/hm-diag:b30bd8a + image: nebraltd/hm-diag:72f141f environment: - - FIRMWARE_VERSION=2021.11.22.0-1 + - FIRMWARE_VERSION=2021.11.30.1 + - DIAGNOSTICS_VERSION=72f141f + - DBUS_SYSTEM_BUS_ADDRESS=unix:path=/host/run/dbus/system_bus_socket volumes: - pktfwdr:/var/pktfwd - miner-storage:/var/data @@ -67,9 +70,13 @@ services: - "80:5000" cap_add: - SYS_RAWIO + devices: + - /dev/i2c-1:/dev/i2c-1 privileged: true labels: io.balena.features.sysfs: 1 + io.balena.features.procfs: 1 + io.balena.features.dbus: 1 upnp: image: nebraltd/hm-upnp:b575a2f @@ -85,7 +92,7 @@ services: - dbus:/session/dbus environment: - DBUS_ADDRESS=unix:path=/session/dbus/session_bus_socket - - FIRMWARE_VERSION=2021.11.22.0-1 + - FIRMWARE_VERSION=2021.11.30.1 volumes: miner-storage: