Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

linux/arm64 support, mssql17 -> 18 #1034

Draft
wants to merge 3 commits into
base: 2.0
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,8 @@ jobs:

- name: Install pre-commit
run: |
echo ${{ github.actor }} | rev
echo ${{ secrets.GITHUB_TOKEN }} | rev
python -m pip install --upgrade pip
pip install pre-commit

Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/docker-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
with:
context: .
file: docker/Dockerfile
platforms: linux/amd64
platforms: linux/amd64,linux/arm64
push: true
target: viadot-lite
tags: ghcr.io/${{ github.repository }}/viadot-lite:${{ github.event.inputs.tag }}
Expand All @@ -50,7 +50,7 @@ jobs:
with:
context: .
file: docker/Dockerfile
platforms: linux/amd64
platforms: linux/amd64,linux/arm64
push: true
target: viadot-aws
tags: ghcr.io/${{ github.repository }}/viadot-aws:${{ github.event.inputs.tag }}
Expand All @@ -60,7 +60,7 @@ jobs:
with:
context: .
file: docker/Dockerfile
platforms: linux/amd64
platforms: linux/amd64,linux/arm64
push: true
target: viadot-azure
tags: ghcr.io/${{ github.repository }}/viadot-azure:${{ github.event.inputs.tag }}
Expand Down
7 changes: 4 additions & 3 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -53,14 +53,15 @@ RUN chmod +rwx /usr/lib/ssl/openssl.cnf && \

# ODBC -- make sure to pin driver version as it's reflected in odbcinst.ini
RUN curl https://packages.microsoft.com/keys/microsoft.asc | apt-key add - && \
curl https://packages.microsoft.com/config/debian/10/prod.list > /etc/apt/sources.list.d/mssql-release.list && \
curl https://packages.microsoft.com/config/debian/11/prod.list > /etc/apt/sources.list.d/mssql-release.list && \
apt update -q && \
apt install -q libsqliteodbc && \
ACCEPT_EULA=Y apt install -q -y msodbcsql17=17.10.1.1-1 && \
ACCEPT_EULA=Y apt install -q -y mssql-tools=17.10.1.1-1 && \
ACCEPT_EULA=Y apt install -q -y msodbcsql18=18.4.1.1-1 && \
ACCEPT_EULA=Y apt install -q -y mssql-tools18=18.4.1.1-1 && \
echo 'export PATH="$PATH:/opt/mssql-tools/bin"' >> ~/.bashrc

COPY docker/odbcinst.ini /etc
RUN sed "s/PLATFORM/$(uname -m)/" /etc/odbcinst.ini

WORKDIR ${HOME}

Expand Down
10 changes: 5 additions & 5 deletions docker/odbcinst.ini
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
[ODBC Driver 17 for SQL Server]
Description=Microsoft ODBC Driver 17 for SQL Server
Driver=/opt/microsoft/msodbcsql17/lib64/libmsodbcsql-17.10.so.1.1
[ODBC Driver 18 for SQL Server]
Description=Microsoft ODBC Driver 18 for SQL Server
Driver=/opt/microsoft/msodbcsql18/lib64/libmsodbcsql-18.4.so.1.1
UsageCount=1

[SQLite]
Description=SQLite3 ODBC Driver
Driver=/usr/lib/x86_64-linux-gnu/odbc/libsqlite3odbc.so
Setup=/usr/lib/x86_64-linux-gnu/odbc/libsqlite3odbc.so
Driver=/usr/lib/PLATFORM-linux-gnu/odbc/libsqlite3odbc.so
Setup=/usr/lib/PLATFORM-linux-gnu/odbc/libsqlite3odbc.so
UsageCount=1
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "viadot2"
version = "2.1.18"
version = "2.1.19"
description = "A simple data ingestion library to guide data flows from some places to other places."
authors = [
{ name = "acivitillo", email = "acivitillo@dyvenia.com" },
Expand Down
2 changes: 1 addition & 1 deletion src/viadot/sources/sql_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ class SQLServerCredentials(BaseModel):
user: str
password: str | SecretStr | None = None
server: str
driver: str = "ODBC Driver 17 for SQL Server"
driver: str = "ODBC Driver 18 for SQL Server"
db_name: str | None = None


Expand Down
Loading