mirror of
https://github.com/turbot/steampipe.git
synced 2025-12-19 09:58:53 -05:00
Fix glibc errors in linux builds (#4692)
This commit is contained in:
@@ -94,16 +94,16 @@ jobs:
|
|||||||
- name: Pull & Extract - linux amd64
|
- name: Pull & Extract - linux amd64
|
||||||
run: |-
|
run: |-
|
||||||
EXTRACT_DIR=extracted-linux-amd64
|
EXTRACT_DIR=extracted-linux-amd64
|
||||||
# new link (linux-amd64.txz) - https://drive.google.com/file/d/1CetXFMZZRAtkVr4gCTlcJcOfIm0wyyYn/view?usp=drive_link
|
# new link (linux-amd64.txz) - https://drive.google.com/file/d/17XnB7ipjnnDzvjAVAMCjvePRVyOvyiC-/view?usp=drive_link
|
||||||
curl -L -o linux-amd64.txz "https://drive.google.com/uc?export=download&id=1CetXFMZZRAtkVr4gCTlcJcOfIm0wyyYn"
|
curl -L -o linux-amd64.txz "https://drive.google.com/uc?export=download&id=17XnB7ipjnnDzvjAVAMCjvePRVyOvyiC-"
|
||||||
mkdir $EXTRACT_DIR
|
mkdir $EXTRACT_DIR
|
||||||
tar -xf linux-amd64.txz --directory $EXTRACT_DIR
|
tar -xf linux-amd64.txz --directory $EXTRACT_DIR
|
||||||
|
|
||||||
- name: Pull & Extract - linux arm64
|
- name: Pull & Extract - linux arm64
|
||||||
run: |-
|
run: |-
|
||||||
EXTRACT_DIR=extracted-linux-arm64
|
EXTRACT_DIR=extracted-linux-arm64
|
||||||
# new link (linux-arm64.txz) - https://drive.google.com/file/d/1ce43gJu8HPAufcsZEk87uFPyT6fGEair/view?usp=drive_link
|
# new link (linux-arm64.txz) - https://drive.google.com/file/d/1dBKin4bgTbbBSk7fToLnkNxWhixGIbtt/view?usp=drive_link
|
||||||
curl -L -o linux-arm64.txz "https://drive.google.com/uc?export=download&id=1ce43gJu8HPAufcsZEk87uFPyT6fGEair"
|
curl -L -o linux-arm64.txz "https://drive.google.com/uc?export=download&id=1dBKin4bgTbbBSk7fToLnkNxWhixGIbtt"
|
||||||
mkdir $EXTRACT_DIR
|
mkdir $EXTRACT_DIR
|
||||||
tar -xf linux-arm64.txz --directory $EXTRACT_DIR
|
tar -xf linux-arm64.txz --directory $EXTRACT_DIR
|
||||||
|
|
||||||
|
|||||||
@@ -63,6 +63,52 @@ jobs:
|
|||||||
docker stop ubuntu-24-test
|
docker stop ubuntu-24-test
|
||||||
docker rm ubuntu-24-test
|
docker rm ubuntu-24-test
|
||||||
|
|
||||||
|
smoke_test_ubuntu_22:
|
||||||
|
name: Smoke test (Ubuntu 22, x86_64)
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
||||||
|
|
||||||
|
- name: Download Linux Release Artifact
|
||||||
|
run: |
|
||||||
|
mkdir -p ./artifacts
|
||||||
|
gh release download ${{ env.VERSION }} \
|
||||||
|
--pattern "*linux_amd64.tar.gz" \
|
||||||
|
--dir ./artifacts \
|
||||||
|
--repo ${{ github.repository }}
|
||||||
|
# Rename to expected format
|
||||||
|
mv ./artifacts/*linux_amd64.tar.gz ./artifacts/linux.tar.gz
|
||||||
|
env:
|
||||||
|
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@b5ca514318bd6ebac0fb2aedd5d36ec1b5c232a2 # v3.10.0
|
||||||
|
|
||||||
|
- name: Pull Ubuntu latest Image
|
||||||
|
run: docker pull ubuntu:latest
|
||||||
|
|
||||||
|
- name: Create and Start Ubuntu latest Container
|
||||||
|
run: |
|
||||||
|
docker run -d --name ubuntu-22-test -v ${{ github.workspace }}/artifacts:/artifacts -v ${{ github.workspace }}/scripts:/scripts ubuntu:22.04 tail -f /dev/null
|
||||||
|
|
||||||
|
- name: Get runner/container info
|
||||||
|
run: |
|
||||||
|
docker exec ubuntu-22-test /scripts/linux_container_info.sh
|
||||||
|
|
||||||
|
- name: Install dependencies, create user, and assign necessary permissions
|
||||||
|
run: |
|
||||||
|
docker exec ubuntu-22-test /scripts/prepare_ubuntu_container.sh
|
||||||
|
|
||||||
|
- name: Run smoke tests
|
||||||
|
run: |
|
||||||
|
docker exec -u steampipe ubuntu-22-test /scripts/smoke_test.sh
|
||||||
|
|
||||||
|
- name: Stop and Remove Container
|
||||||
|
run: |
|
||||||
|
docker stop ubuntu-22-test
|
||||||
|
docker rm ubuntu-22-test
|
||||||
|
|
||||||
smoke_test_centos_9:
|
smoke_test_centos_9:
|
||||||
name: Smoke test (CentOS Stream 9, x86_64)
|
name: Smoke test (CentOS Stream 9, x86_64)
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ const (
|
|||||||
|
|
||||||
// PostgresImageRef is the OCI Image ref for the database binaries
|
// PostgresImageRef is the OCI Image ref for the database binaries
|
||||||
PostgresImageRef = "ghcr.io/turbot/steampipe/db:14.19.0"
|
PostgresImageRef = "ghcr.io/turbot/steampipe/db:14.19.0"
|
||||||
PostgresImageDigest = "sha256:42fd8972700e40565799ee5f4dc6a66afa146e0994ef9103c944f2b5f5adc43a"
|
PostgresImageDigest = "sha256:84264ef41853178707bccb091f5450c22e835f8a98f9961592c75690321093d9"
|
||||||
|
|
||||||
FdwImageRef = "ghcr.io/turbot/steampipe/fdw:" + FdwVersion
|
FdwImageRef = "ghcr.io/turbot/steampipe/fdw:" + FdwVersion
|
||||||
FdwBinaryFileName = "steampipe_postgres_fdw.so"
|
FdwBinaryFileName = "steampipe_postgres_fdw.so"
|
||||||
|
|||||||
@@ -1,26 +1,27 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
# This is a script with set of commands to smoke test a steampipe build.
|
# This is a script with set of commands to smoke test a steampipe build.
|
||||||
# The plan is to gradually add more tests to this script.
|
# The plan is to gradually add more tests to this script.
|
||||||
|
set -e
|
||||||
|
|
||||||
/usr/local/bin/steampipe --version # check version
|
/usr/local/bin/steampipe --version # check version
|
||||||
/usr/local/bin/steampipe query "select 1 as installed" # verify installation
|
/usr/local/bin/steampipe query "select 1 as installed" # verify installation
|
||||||
|
|
||||||
/usr/local/bin/steampipe plugin install steampipe # verify plugin install
|
/usr/local/bin/steampipe plugin install net # verify plugin install
|
||||||
/usr/local/bin/steampipe plugin list # verify plugin listings
|
/usr/local/bin/steampipe plugin list # verify plugin listings
|
||||||
|
|
||||||
/usr/local/bin/steampipe query "select name from steampipe_registry_plugin limit 10;" # verify simple query
|
/usr/local/bin/steampipe query "select issuer, not_after as exp_date from net_certificate where domain = 'steampipe.io';" # verify simple query
|
||||||
|
|
||||||
/usr/local/bin/steampipe plugin uninstall steampipe # verify plugin uninstall
|
/usr/local/bin/steampipe plugin uninstall net # verify plugin uninstall
|
||||||
/usr/local/bin/steampipe plugin list # verify plugin listing after uninstalling
|
/usr/local/bin/steampipe plugin list # verify plugin listing after uninstalling
|
||||||
|
|
||||||
/usr/local/bin/steampipe plugin install steampipe # re-install for other tests
|
/usr/local/bin/steampipe plugin install net # re-install for other tests
|
||||||
# the file path is different for darwin and linux
|
# the file path is different for darwin and linux
|
||||||
if [ "$(uname -s)" = "Darwin" ]; then
|
if [ "$(uname -s)" = "Darwin" ]; then
|
||||||
/usr/local/bin/steampipe query "select name from steampipe_registry_plugin limit 1;" --export /Users/runner/query.sps # verify file export
|
/usr/local/bin/steampipe query "select issuer, not_after as exp_date from net_certificate where domain = 'steampipe.io';" --export /Users/runner/query.sps # verify file export
|
||||||
cat /Users/runner/query.sps | jq '.end_time' # verify file created is readable
|
jq '.end_time' /Users/runner/query.sps # verify file created is readable
|
||||||
else
|
else
|
||||||
/usr/local/bin/steampipe query "select name from steampipe_registry_plugin limit 1;" --export /home/steampipe/query.sps # verify file export
|
/usr/local/bin/steampipe query "select issuer, not_after as exp_date from net_certificate where domain = 'steampipe.io';" --export /home/steampipe/query.sps # verify file export
|
||||||
cat /home/steampipe/query.sps | jq '.end_time' # verify file created is readable
|
jq '.end_time' /home/steampipe/query.sps # verify file created is readable
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Ensure the log file path exists before trying to read it
|
# Ensure the log file path exists before trying to read it
|
||||||
@@ -30,11 +31,11 @@ if [ "$(uname -s)" = "Darwin" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Verify log level in logfile
|
# Verify log level in logfile
|
||||||
STEAMPIPE_LOG=info /usr/local/bin/steampipe query "select name from steampipe_registry_plugin limit 1;"
|
STEAMPIPE_LOG=info /usr/local/bin/steampipe query "select issuer, not_after as exp_date from net_certificate where domain = 'steampipe.io';"
|
||||||
|
|
||||||
# Check if log file exists before attempting to cat it
|
# Check if log file exists before attempting to cat it
|
||||||
if ls $LOG_PATH 1> /dev/null 2>&1; then
|
if ls $LOG_PATH 1> /dev/null 2>&1; then
|
||||||
bash -c "cat $LOG_PATH | grep '\[INFO\]'"
|
grep '\[INFO\]' $LOG_PATH
|
||||||
else
|
else
|
||||||
echo "Log file not found: $LOG_PATH"
|
echo "Log file not found: $LOG_PATH"
|
||||||
exit 1
|
exit 1
|
||||||
|
|||||||
Reference in New Issue
Block a user