Docker-Compose error after removing containers

Asked

Viewed 408 times

0

I went to delete some containers on Docker to bring them up again and Docker-Compose is not moving the images up anymore.

I’m getting the following error:

Building application Traceback (most recent call last):   

 File "site-packages/docker/utils/build.py", line 96, in create_archive PermissionError: 
  [Errno 13] Permission denied: '/home/richar/Área de Trabalho/projeto mensi2/projeto-mensis/mysql/data/ca-key.pem'

During handling of the above exception, another exception occurred:

File "bin/docker-compose", line 6, in <module>
File "compose/cli/main.py", line 71, in main
File "compose/cli/main.py", line 127, in perform_command
File "compose/cli/main.py", line 1085, in up
File "compose/cli/main.py", line 1081, in up
File "compose/project.py", line 527, in up
File "compose/service.py", line 360, in ensure_image_exists
File "compose/service.py", line 1084, in build
File "site-packages/docker/api/build.py", line 159, in build
File "site-packages/docker/utils/build.py", line 31, in tar
File "site-packages/docker/utils/build.py", line 100, in create_archive
OSError: Can not read file in context: /home/richar/Área de Trabalho/projeto mensi2/projeto-mensis/mysql/data/ca-key.pem
[5820] Failed to execute script docker-compose

I’m new to linux, how can I fix this?

1 answer

1


This is giving permission error in a Mysql file, probably because you are creating a database volume by setting a local folder,

You can delete Mysql folder, this will erase the database

sudo rm -R ./mysql/data

or change permission

sudo chmod 777 -R ./mysql

Try this in the project directory

  • Thanks Gabriel Sousa was this very thank you for saving.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.