influx on intel #25
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [ master ] | |
| pull_request: | |
| branches: [ master ] | |
| jobs: | |
| linux: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Cache Conan | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.conan2 | |
| key: conan-${{ runner.os }}-${{ hashFiles('**/conanfile.py') }} | |
| restore-keys: | | |
| conan-${{ runner.os }}- | |
| - name: Install Conan | |
| run: | | |
| pip install conan | |
| - name: Configure Conan for C++20 | |
| run: | | |
| conan profile detect --force | |
| # Override to C++20 (not gnu20 to match CMAKE_CXX_EXTENSIONS=OFF) | |
| sed -i 's/compiler\.cppstd=.*/compiler.cppstd=20/' ~/.conan2/profiles/default || true | |
| echo "compiler.cppstd=20" >> ~/.conan2/profiles/default || true | |
| - name: Build project | |
| run: | | |
| chmod +x scripts/build.sh scripts/test.sh scripts/start-influxdb.sh scripts/stop-influxdb.sh | |
| ./scripts/build.sh Release | |
| - name: Start InfluxDB | |
| run: | | |
| ./scripts/start-influxdb.sh | |
| - name: Run tests | |
| run: | | |
| ./scripts/test.sh | |
| - name: Run demo | |
| run: | | |
| ./scripts/run-demo.sh | |
| - name: Stop InfluxDB | |
| if: always() | |
| run: | | |
| ./scripts/stop-influxdb.sh | |
| macos: | |
| runs-on: macos-15 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Cache Conan | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.conan2 | |
| key: conan-${{ runner.os }}-${{ hashFiles('**/conanfile.py') }} | |
| restore-keys: | | |
| conan-${{ runner.os }}- | |
| - name: Cache InfluxDB | |
| uses: actions/cache@v4 | |
| id: cache-influxdb | |
| with: | |
| path: | | |
| influxdb-1.8.10-1 | |
| influxdb-1.8.10_darwin_amd64.tar.gz | |
| key: influxdb-1.8.10-macos-${{ runner.os }} | |
| restore-keys: | | |
| influxdb-1.8.10-macos- | |
| - name: Install Conan | |
| run: | | |
| pip install conan | |
| - name: Configure Conan for C++20 | |
| run: | | |
| conan profile detect --force | |
| # Override to C++20 (not gnu20 to match CMAKE_CXX_EXTENSIONS=OFF) | |
| sed -i '' 's/compiler\.cppstd=.*/compiler.cppstd=20/' ~/.conan2/profiles/default || true | |
| echo "compiler.cppstd=20" >> ~/.conan2/profiles/default || true | |
| - name: Build project | |
| run: | | |
| chmod +x scripts/build.sh scripts/test.sh | |
| ./scripts/build.sh Release | |
| - name: Download InfluxDB (if not cached) | |
| if: steps.cache-influxdb.outputs.cache-hit != 'true' | |
| run: | | |
| INFLUXDB_VERSION=1.8.10 | |
| INFLUXDB_TAR=influxdb-${INFLUXDB_VERSION}_darwin_amd64.tar.gz | |
| INFLUXDB_URL=https://dl.influxdata.com/influxdb/releases/${INFLUXDB_TAR} | |
| echo "Downloading InfluxDB ${INFLUXDB_VERSION}..." | |
| curl -L -o "${INFLUXDB_TAR}" "${INFLUXDB_URL}" | |
| echo "Extracting InfluxDB..." | |
| tar -xzf "${INFLUXDB_TAR}" | |
| echo "Verifying InfluxDB binary..." | |
| if [ ! -f "influxdb-${INFLUXDB_VERSION}-1/usr/bin/influxd" ]; then | |
| echo "ERROR: InfluxDB binary not found at expected path: influxdb-${INFLUXDB_VERSION}-1/usr/bin/influxd" | |
| echo "Extracted contents:" | |
| ls -la influxdb-${INFLUXDB_VERSION}-1/ || true | |
| exit 1 | |
| fi | |
| ls -la influxdb-${INFLUXDB_VERSION}-1/usr/bin/influxd | |
| chmod +x influxdb-${INFLUXDB_VERSION}-1/usr/bin/influxd | |
| - name: Start InfluxDB | |
| run: | | |
| chmod +x scripts/start-influxdb-native.sh | |
| scripts/start-influxdb-native.sh | |
| - name: Run tests | |
| run: | | |
| ./scripts/test.sh | |
| - name: Run demo | |
| run: | | |
| ./scripts/run-demo.sh | |
| - name: Stop InfluxDB | |
| if: always() | |
| run: | | |
| echo "Stopping InfluxDB..." | |
| if [ -n "$INFLUXDB_PID" ]; then | |
| kill $INFLUXDB_PID 2>/dev/null || true | |
| fi | |
| # Fallback: try to find and kill any remaining influxd processes | |
| pkill -f "influxd.*influxdb.conf" 2>/dev/null || true | |
| macos-arm: | |
| runs-on: macos-latest | |
| # Note: Uses Apple Silicon runner with InfluxDB amd64 binary via Rosetta (similar to Windows approach) | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Cache Conan | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.conan2 | |
| key: conan-${{ runner.os }}-${{ hashFiles('**/conanfile.py') }} | |
| restore-keys: | | |
| conan-${{ runner.os }}- | |
| - name: Cache InfluxDB | |
| uses: actions/cache@v4 | |
| id: cache-influxdb | |
| with: | |
| path: | | |
| influxdb-1.8.10-1 | |
| influxdb-1.8.10_darwin_amd64.tar.gz | |
| key: influxdb-1.8.10-macos-arm-${{ runner.os }} | |
| restore-keys: | | |
| influxdb-1.8.10-macos-arm- | |
| - name: Install Conan | |
| run: | | |
| pip install conan | |
| - name: Configure Conan for C++20 | |
| run: | | |
| conan profile detect --force | |
| # Override to C++20 (not gnu20 to match CMAKE_CXX_EXTENSIONS=OFF) | |
| sed -i '' 's/compiler\.cppstd=.*/compiler.cppstd=20/' ~/.conan2/profiles/default || true | |
| echo "compiler.cppstd=20" >> ~/.conan2/profiles/default || true | |
| - name: Build project | |
| run: | | |
| chmod +x scripts/build.sh scripts/test.sh | |
| ./scripts/build.sh Release | |
| - name: Download InfluxDB (if not cached) | |
| if: steps.cache-influxdb.outputs.cache-hit != 'true' | |
| run: | | |
| INFLUXDB_VERSION=1.8.10 | |
| # Note: InfluxDB 1.8.10 only has amd64/x86_64 binaries, but will run on Apple Silicon via Rosetta | |
| INFLUXDB_TAR=influxdb-${INFLUXDB_VERSION}_darwin_amd64.tar.gz | |
| INFLUXDB_URL=https://dl.influxdata.com/influxdb/releases/${INFLUXDB_TAR} | |
| echo "Downloading InfluxDB ${INFLUXDB_VERSION} (amd64, runs on Apple Silicon via Rosetta)..." | |
| curl -L -o "${INFLUXDB_TAR}" "${INFLUXDB_URL}" | |
| echo "Extracting InfluxDB..." | |
| tar -xzf "${INFLUXDB_TAR}" | |
| echo "Verifying InfluxDB binary..." | |
| if [ ! -f "influxdb-${INFLUXDB_VERSION}-1/usr/bin/influxd" ]; then | |
| echo "ERROR: InfluxDB binary not found at expected path: influxdb-${INFLUXDB_VERSION}-1/usr/bin/influxd" | |
| echo "Extracted contents:" | |
| ls -la influxdb-${INFLUXDB_VERSION}-1/ || true | |
| exit 1 | |
| fi | |
| ls -la influxdb-${INFLUXDB_VERSION}-1/usr/bin/influxd | |
| chmod +x influxdb-${INFLUXDB_VERSION}-1/usr/bin/influxd | |
| - name: Start InfluxDB | |
| run: | | |
| chmod +x scripts/start-influxdb-native.sh | |
| scripts/start-influxdb-native.sh | |
| - name: Run tests | |
| run: | | |
| ./scripts/test.sh | |
| - name: Run demo | |
| run: | | |
| ./scripts/run-demo.sh | |
| - name: Stop InfluxDB | |
| if: always() | |
| run: | | |
| echo "Stopping InfluxDB..." | |
| if [ -n "$INFLUXDB_PID" ]; then | |
| kill $INFLUXDB_PID 2>/dev/null || true | |
| fi | |
| pkill -f influxd || true | |
| sleep 2 | |
| echo "InfluxDB stopped" | |
| windows: | |
| runs-on: windows-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Cache Conan | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.conan2 | |
| key: conan-${{ runner.os }}-${{ hashFiles('**/conanfile.py') }} | |
| restore-keys: | | |
| conan-${{ runner.os }}- | |
| - name: Cache InfluxDB | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| influxdb-1.8.10-1 | |
| influxdb-1.8.10_windows_amd64.zip | |
| key: influxdb-1.8.10-windows-${{ runner.os }} | |
| restore-keys: | | |
| influxdb-1.8.10-windows- | |
| - name: Install Conan | |
| run: | | |
| pip install conan | |
| - name: Configure Conan for C++20 | |
| shell: bash | |
| run: | | |
| conan profile detect --force | |
| # Override to C++20 for MSVC (uses simple "20" not "gnu20") | |
| sed -i 's/compiler\.cppstd=.*/compiler.cppstd=20/' ~/.conan2/profiles/default || true | |
| echo "compiler.cppstd=20" >> ~/.conan2/profiles/default || true | |
| - name: Build project | |
| run: | | |
| scripts\build.bat Release | |
| - name: Start InfluxDB | |
| run: | | |
| scripts\start-influxdb.bat | |
| - name: Run tests | |
| run: | | |
| scripts\test.bat | |
| - name: Run demo | |
| run: | | |
| scripts\run-demo.bat | |
| - name: Stop InfluxDB | |
| if: always() | |
| run: | | |
| scripts\stop-influxdb.bat |