Hydrospheredata / mist

Serverless proxy for Spark cluster
http://hydrosphere.io/mist/
Apache License 2.0
326 stars 68 forks source link

access file on server #432

Closed thetuxedo closed 6 years ago

thetuxedo commented 6 years ago

mist: 1.0.0-RC8-2.2.0 (docker) environ: linux

I tried to create a function following hello_mist example. The first thing is to read a text file, then do sth in spark. So the param of the function is the path of the file, like "/tmp/a.json"

I launched docker image, package my code, deploy, and I mapped the volume of /tmp to /tmp so it could be accessed inside docker container as well.

Scala code is sth like scala.io.Source.fromFile()

But mist returns file not found exception.

Where should I put the file so that it could be accessed by Mist?

Thanks.

dos65 commented 6 years ago

It's impossible to do that with docker distributive by default - use mist from binaries. Also, we have a gitter for questions.