xref: /third_party/mesa3d/.gitlab-ci/bare-metal/poe-on
  • Home
  • History
  • Annotate Annotate
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
  • only in /third_party/mesa3d/.gitlab-ci/bare-metal/
1bf215546Sopenharmony_ci#!/bin/bash
2bf215546Sopenharmony_ci
3bf215546Sopenharmony_ciif [ -z "$BM_POE_INTERFACE" ]; then
4bf215546Sopenharmony_ci    echo "Must supply the PoE Interface to power up"
5bf215546Sopenharmony_ci    exit 1
6bf215546Sopenharmony_cifi
7bf215546Sopenharmony_ci
8bf215546Sopenharmony_ciif [ -z "$BM_POE_ADDRESS" ]; then
9bf215546Sopenharmony_ci    echo "Must supply the PoE Switch host"
10bf215546Sopenharmony_ci    exit 1
11bf215546Sopenharmony_cifi
12bf215546Sopenharmony_ci
13bf215546Sopenharmony_ciSNMP_KEY="SNMPv2-SMI::mib-2.105.1.1.1.3.1.`expr 48 + $BM_POE_INTERFACE`"
14bf215546Sopenharmony_ciSNMP_ON="i 1"
15bf215546Sopenharmony_ciSNMP_OFF="i 2"
16bf215546Sopenharmony_ci
17bf215546Sopenharmony_ciflock /var/run/poe.lock -c "snmpset -v2c -r 3 -t 30 -cmesaci $BM_POE_ADDRESS $SNMP_KEY $SNMP_OFF"
18bf215546Sopenharmony_cisleep 3s
19bf215546Sopenharmony_ciflock /var/run/poe.lock -c "snmpset -v2c -r 3 -t 30 -cmesaci $BM_POE_ADDRESS $SNMP_KEY $SNMP_ON"
20

Indexes created Thu Nov 07 10:32:03 CST 2024