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

How are local files supposed to work? #22

Open
mhegreberg opened this issue Jan 16, 2024 · 0 comments
Open

How are local files supposed to work? #22

mhegreberg opened this issue Jan 16, 2024 · 0 comments

Comments

@mhegreberg
Copy link

I've got SHIR in a windows container, and I mounted the files it needs as a local volume. how do I make azure data factory see them?

it seems azure data factory requires a username/password, even for files local to the SHIR, so I modified the dockerfile to create a user, but it can't read anything. am I missing something?

dockerfile changes:

FROM mcr.microsoft.com/windows/servercore:ltsc2022
ARG INSTALL_JDK=false

# Download the latest self-hosted integration runtime installer into the SHIR folder
COPY SHIR C:/SHIR/

RUN ["powershell", "C:/SHIR/build.ps1"]

# Allow local folder Navigation
RUN ["powershell", "'C:/Program Files/Microsoft Integration Runtime/6.0/Shared/dmgcmd.exe -DisableLocalFolderPathValidation'"]

RUN mkdir "C:/data"

RUN net user dataUser '(PASSWORD_HERE)' /ADD

RUN ["icacls", "C:/data", "/grant", "dataUser:(OI)(CI)F"]

ENTRYPOINT ["powershell", "C:/SHIR/setup.ps1"]

ENV SHIR_WINDOWS_CONTAINER_ENV True

HEALTHCHECK --start-period=120s CMD ["powershell", "C:/SHIR/health-check.ps1"]

I then run the container with the following docker compose:

services:
  shir:
    image: shir
    build: "B:/docker/MSSHIR/Azure-Data-Factory-Integration-Runtime-in-Windows-Container-main"
    volumes:
      - type: bind
        source: "B:/data/"
        target: "C:/data"
    environment:
      AUTH_KEY: "(Auth_Key)"
      NODE_NAME: "shir"
      ENABLE_AE: true
      ENABLE_HA: true

is anyone else using local files this way? I'm pulling my hair out, this feels much easier with linux containers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant