-1

I'm doing a class project, I have to follow some steps and there's one that is not working. Here's the problem.

I have to use:

docker-compose exec workspace bash

To open a directory and be able to write there:

 /var/www$ composer install

In Docker everything seems to be okay installed and configured.

The problem is that docker-compose exec workspace bash is not working. I wrote that in the console and nothing happens or opens VISUALLY. Image below:

Nothing happens

But internally, there is something that executes, because when I try to close the window of the console this appears "Processes are running in session":

Error

What's wrong? ¿How can I open docker-componse workspace? Thank you in advance.

nbk
  • 45,398
  • 8
  • 30
  • 47
virxu
  • 23
  • 1
  • 4
  • 1
    your himework arready wa posted multple times and i thing nobody has an answer for this – nbk Oct 24 '21 at 11:02
  • Someone answered and it worked! – virxu Oct 24 '21 at 14:22
  • 1
    Please share any relevant code by editing your Question - [instead of a screenshot](https://meta.stackoverflow.com/questions/285551/why-not-upload-images-of-code-errors-when-asking-a-question). Fewer people are likely to reproduce your issue without having your code in a copyable form. – tjheslin1 Oct 24 '21 at 14:50

1 Answers1

1

One way to access a shell inside your workspace container is to directly exec ur composer inside the container with the command docker exec Try this:

docker ps 

Now find the container id of your workspace container

docker exec -it [container_ID] bash
~$ composer install
Melly
  • 21
  • 4