Livebook dependency caching - author notebooks remotely and upload dependencies along with the livebook code?

I’m deploying Livebook on devices that won’t always have access to the internet. Is there a way to author notebooks remotely and upload the dependencies along with the livebook code? Or a way to proxy internally to livebook the dependencies I know each runtime will pull. For example I know I’ll need the SQL Server dependencies and Merquery installed for every Livebook runtime.

As a work around I’ve attached the Livebook runtime to a deployment inside the same kubernetes environment that has the dependencies installed but it prevents running smart cells.

Thank you in advance!

1 Like

Mix.install is cached for the given set of dependencies, so if you run it once, you can use it in further notebook runs without internet access.

If the instance does not have internet access at any point, you could build a custom Docker image on top of the Livebook Docker image and as part of the Dockerfile build you would run the relevant Mix.installs, so they get cached at build time.

If I misunderstood the use case, let me know : )

1 Like

Worked like a charm! Thank you!