1

I'm trying to remotely interact with a container instance in Azure. I've performed following steps:

  1. Loaded local image on local registry

    docker load -i ima.tar

  2. Loggin in to remote ACR

    docker login --username --password + login-server

  3. Tagged the image

    docker tag local-image:tag <login-server/repository-name:tag>

  4. Pushed imaged

    docker push <login-server/repository-name:tag>

If I try to run a command like this:

az container exec --resource-group myResourceGroup --name <name of cotainer group> --container-name <name of container app> --exec-command "/bin/bash"

I can successfully login to bash interactively. My Goal is to process local file to the a remote ACI using the ACR image, something like this:

docker run -t -i --entrypoint=./executables/run.sh -v "%cd%"\..:/opt/test remote_image:tag

Is it there a way to do so? How can I run ACI e remote push file via AZ CLI? Thx

1 Answer 1

1

For your purpose, I recommend you mount the Azure File Share to the ACI and then upload the files to the File Share. Finally, you can access the files in the File Share inside the ACI. Follow the steps here to mount the File Share.

Sign up to request clarification or add additional context in comments.

5 Comments

Thx for the info, but is it not possible to interact with remote ACI using local file exposure? (like an extry point?)
@user3925023 I'm afraid you can't. I see you run the docker command to mount the local volumes, but ACI doesn't support it. If you want to execute the script, you must upload the script to the ACI.
@user3925023 Any more updates on the question? Does it solve your problem?
I'm still figuring out how to automate data upload for testing, but for sure I'll keep you posted many thx
@user3925023 If it's helpful to you please accept it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.