Skip to content

Commit

Permalink
Fix build issues causing installation failures on linux arm64. Closes #…
Browse files Browse the repository at this point in the history
  • Loading branch information
pskrbasu authored May 19, 2023
1 parent 6c1743e commit 252959e
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
9 changes: 7 additions & 2 deletions .github/workflows/buildimage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ env:
CORE_REPO: us-docker.pkg.dev/steampipe/steampipe
ORG: turbot
CONFIG_SCHEMA_VERSION: "2020-11-18"
VERSION: ${{ github.event.inputs.version }}
VERSION: ${{ github.event.ref }}

jobs:
build-osx:
Expand Down Expand Up @@ -277,6 +277,11 @@ jobs:
AWS_DEFAULT_REGION: 'ap-south-1'
PRIVATE_KEY: ${{ secrets.AWS_PRIVATE_KEY }}
run: |
# echo $ref
ref=${{ github.event.ref }}
# echo tag
tag=$(echo "$ref" | sed 's/.*\///')
# get public IP of the linux machine
ip=$(dig +short myip.opendns.com @resolver1.opendns.com)
Expand Down Expand Up @@ -310,7 +315,7 @@ jobs:
echo "$PRIVATE_KEY" > private_key && chmod 600 private_key
# ssh into the instance and run the script to build the binary
ssh -o StrictHostKeyChecking=accept-new -i private_key ubuntu@$public_ip 'bash -s' < script_to_build.sh $VERSION
ssh -o StrictHostKeyChecking=accept-new -i private_key ubuntu@$public_ip 'bash -s' < script_to_build.sh $tag
# use scp to fetch the built binary out of the instance
scp -i private_key ubuntu@$public_ip:/home/ubuntu/steampipe-postgres-fdw/build-Linux/steampipe_postgres_fdw.so .
Expand Down
11 changes: 10 additions & 1 deletion script_to_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,17 @@ git fetch
exit_if_failed
echo ""

echo "git pull origin main"
git checkout main
git pull origin main
exit_if_failed
echo ""

echo "git checkout <tag>"
git checkout $1
input=$1
echo $input
git checkout $input
git branch --list
exit_if_failed
echo ""

Expand Down

0 comments on commit 252959e

Please sign in to comment.