Cannot train model in docker on centOS; models folder not created (silent failure)
See original GitHub issueRasa version: using docker-full-latest
Operating system (windows, osx, …): CentOS Linux 7 (Core)
Issue: I’m trying to deploy my locally trained model to remote server using docker to run the pretrained model from local machine.
Error (including full traceback):
Command:
$ sudo docker run -v $(pwd):/app rasa/rasa init --no-prompt
Traceback:
Warning: Output is not to a terminal (fd=1).
Warning: Input is not to a terminal (fd=0).
Welcome to Rasa! 🤖
To get started quickly, an initial project will be created.
If you need some help, check out the documentation at https://rasa.com/docs/rasa.
Traceback (most recent call last):
File "/usr/local/lib/python3.6/distutils/file_util.py", line 41, in _copy_file_contents
fdst = open(dst, 'wb')
PermissionError: [Errno 13] Permission denied: './__init__.py'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/build/bin/rasa", line 11, in <module>
load_entry_point('rasa==1.5.0a1', 'console_scripts', 'rasa')()
File "/build/lib/python3.6/site-packages/rasa/__main__.py", line 76, in main
cmdline_arguments.func(cmdline_arguments)
File "/build/lib/python3.6/site-packages/rasa/cli/scaffold.py", line 195, in run
init_project(args, path)
File "/build/lib/python3.6/site-packages/rasa/cli/scaffold.py", line 111, in init_project
create_initial_project(path)
File "/build/lib/python3.6/site-packages/rasa/cli/scaffold.py", line 119, in create_initial_project
copy_tree(scaffold_path(), path)
File "/usr/local/lib/python3.6/distutils/dir_util.py", line 163, in copy_tree
dry_run=dry_run)
File "/usr/local/lib/python3.6/distutils/file_util.py", line 151, in copy_file
_copy_file_contents(src, dst)
File "/usr/local/lib/python3.6/distutils/file_util.py", line 44, in _copy_file_contents
"could not create '%s': %s" % (dst, e.strerror))
distutils.errors.DistutilsFileError: could not create './__init__.py': Permission denied
Thanks in advance!
Issue Analytics
- State:
- Created 4 years ago
- Comments:17 (7 by maintainers)
Top Results From Across the Web
Cannot execute RUN mkdir in a Dockerfile - Stack Overflow
The problem is that /var/www doesn't exist either, and mkdir isn't recursive by default -- it expects the immediate parent directory to exist....
Read more >Serving Machine Learning Models With Docker: 5 Mistakes ...
Mistake 5: Not monitoring model versions when serving ML models with Docker. One operational mistake data scientists make is not tracking changes or...
Read more >docker service create - Docker Documentation
docker service create: Creates a service as described by the specified parameters. ... An error is produced if the file or directory does...
Read more >GitLab Docker images
The directory ownership and permissions cannot be changed without remounting, and GitLab fails. Our recommendation is to switch to using the native Docker...
Read more >Using Your GPU in a Docker Container - Roboflow Blog
Follow this step-by-step guide to get started. ... Error: Docker does not find Nvidia drivers ... tensorflow cannot access GPU in Docker
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
replace
docker run -v $(pwd):/app rasa/rasa init --no-prompt
withdocker run -v myrasa:/app rasa/rasa init --no-prompt
,then it will create a dir at/www/server/docker/volumes
,it works.Hi everyone, for this command, that creates new files and directories, the user (
1001
) apparently does not have permission to create these files in the local directory.If you already have models, you don’t need to use
rasa init
to deploy a model. If you are creating a new one, you can use the-u
flag to let this one command act as root to create files.Plan to clear this up in the documentation 👍