voiceip/oreka

ERROR: Dockerfile parse error line 66: Unknown flag: mount

Closed this issue · 5 comments

system: CentOS Linux release 7.7.1908 (Core)
docker version: Docker version 19.03.4, build 9013bf583a
docker-compose version: docker-compose version 1.25.0, build 0a186604
cd /root
git clone https://github.com/voiceip/oreka.git
git checkout -b docker origin/docker
cd /root/oreka/distribution/docker
docker-compose build

Report below an error:

tcpdump uses an image, skipping
softphone uses an image, skipping
Building orkaudio
ERROR: Dockerfile parse error line 66: Unknown flag: mount

why?How to solve it?

The docker files uses the buildkit format, you would need to enable experimental flag in docker and then run the following command

export DOCKER_BUILDKIT=1
docker-compose.....

Do let me know if you still face issue.

Reference : https://docs.docker.com/develop/develop-images/build_enhancements/

According to the above steps, this problem still exists.

[root]# docker version -f '{{.Server.Experimental}}'
true
[root]# export DOCKER_BUILDKIT=1
[root]# docker-compose build
tcpdump uses an image, skipping
softphone uses an image, skipping
Building orkaudio
ERROR: Dockerfile parse error line 66: Unknown flag: mount

Looks like docker-compose build doesn't yet work with build-kit based docker files. It throws the same error for me.

This sequence of commands works for me

export DOCKER_BUILDKIT=1
docker build -f Dockerfile.orkaudio -t orkaudio .
docker-compose run

This should run on your system.

Alternatively, if it still throws error, you can pull in prebuild image from docker hub

docker run --net=host -v /var/log/orkaudio:/var/log/orkaudio -it voiceip/orkaudio

Do let me know if either of the above steps works for you.

Thank you very much, follow these steps to start the container normally
export DOCKER_BUILDKIT=1
docker build -f Dockerfile.orkaudio -t orkaudio .
docker run -itd --net=host --restart=always --privileged=true --name orkaudio orkaudio

Hi @lxglove

Thank you for verifying this information, I have also updated this information in the readme.

Please reopen the issue, if you face any other problems.