Skip to content

Commit

Permalink
Docker x86 workaround for running soda-sql on arm based machines (sod…
Browse files Browse the repository at this point in the history
  • Loading branch information
m1n0 authored Dec 10, 2021
1 parent 5237e47 commit 6ba9300
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 0 deletions.
18 changes: 18 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
FROM python:3.7

RUN apt-get update && apt-get -y install gcc libsasl2-dev python-dev unixodbc-dev

RUN mkdir /app

WORKDIR /app

RUN pip install --upgrade pip

COPY . .

RUN pip install "$(cat dev-requirements.in | grep pip-tools)" && \
pip install -r dev-requirements.txt && \
pip install -r requirements.txt

ENTRYPOINT [ "soda" ]
CMD [ "scan" ]
9 changes: 9 additions & 0 deletions docker-compose-arm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# docker-compose.yml
version: "3.8"
services:
soda:
build:
context: .
platform: "linux/amd64"
volumes:
- .:/app
2 changes: 2 additions & 0 deletions scripts/build_for_arm_full.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/usr/bin/env bash
docker compose -f docker-compose-arm.yml -p soda-sql build soda
2 changes: 2 additions & 0 deletions scripts/run_scan_on_arm.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/usr/bin/env bash
docker compose -f docker-compose-arm.yml -p soda-sql run soda scan "$@"

0 comments on commit 6ba9300

Please sign in to comment.