docker-compose


Docker Toolbox Windows - Invalid volume specification


EDIT: The problem is the COMPOSE_CONVERT_WINDOWS_PATHS environment variable isn't getting set. I tried adding it to the Dockerfile and to a .env file but its not being set. I can't set any new environment variables. Its like its building it from a cached Dockerfile.
I was running docker-composer up after deleting the container, but this didn't recreate a new container, even when adding --force-recreate, it created the container from the old Dockerfile. So I ran docker build ./ instead, and it built a new container, it reinstalled all the packages, and it said that it was setting the new environment variables, but in the finished container, when I check kinematic, I see the new environment variables aren't set. But all of the old environment variables that were set when I built the container for the first time, they're all set. I don't know why this is happening, why I can't create a new container from the updated Dockerfile.
I've found a number of threads about this error, it happens when trying to mount a volume in Windows docker-tools. When I run docker-compose up, I get this error:
ERROR: for web Cannot create container for service web: Invalid bind mount spec "C:\\path\\to\\project:/app:rw": Invalid volume specification: 'C:\path\to\project:/app:rw'
[31mERROR[0m: Encountered errors while bringing up the project.
In the docker-compose file I have this:
volumes:
- ./:/app
I tried setting this environment variable:
COMPOSE_CONVERT_WINDOWS_PATHS=1
to 1, as that worked for some people in another thread but its not working in this case. I tried adding an absolute path in linux like format:
volumes:
- /c/path/to/project:/app
and I get this error:
ERROR: for web Cannot create container for service web: create \c\path\to\project: "\\c\\path\\to\\project" includes invalid characters for a local volume name, only "[a-zA-Z0-9][a-zA-Z0-9_.-]" are allowed
Notice it reversed the forward slashes. Changing:
ENV COMPOSE_CONVERT_WINDOWS_PATHS=0
to 0 like that didn't change anything.
If I give a Windows format absolute directory, I get the first error again. Both of those errors, I get them if I point to a directory that doesn't exist.
Has anyone here figured out a way to resolve this?

Related Links

Yesod and docker-compose logs in development mode
Docker compose to always deploy using latest image
JHipster - Doubts in the development using Microservices Architecture
Gogs + Drone getsockopt: connection refused
Concourse result keeps loading
Docker-compose: AttributeError: 'module' object has no attribute 'ssl'
scaling a service with docker compose
Docker Compose apparently ignores COMPOSE_FILE
Where does Docker install gems on a mac
What is the difference between docker-machine and docker-compose?
Docker Compose port issue. Cannot launch docker project on localhost
Name an image built from running a docker-compose file
Race conditions after changing names in docker-compose.yml
Docker compose - image not found
How to work out the hostname that compose gives containers?
docker-compose restart container if service is dead

Categories

HOME
netty
ssh
grpc
ebay-api
sdk
msbi
terminal
psexec
comments
sequence
zabbix
sitemap
doctrine2
rename
facebook-sharer
mbed
browsermob
k-means
openscad
novacode-docx
udeploy
bootstrap-datetimepicker
react-jsx
gomobile
formulas
tcpdf
ppp
android-wear-2.0
suitescript
rancher
rollupjs
pydub
ocl
semantic-ui-react
foxpro
imdb
postgresql-9.6
sampling
client-server
jibx
idea-plugin
office-interop
smooth-streaming
ocamlbuild
django-tables2
vertex
playframework-2.3
nservicebus6
msiexec
nls
gevent
mac-app-store
konakart
csc
angularfire
queuing
supervised-learning
pyshark
std
fadein
wonderware
kramdown
newlib
sdkman
transport
persian
page-flipping
roslyn-code-analysis
dcg
httpmodule
skview
touch-typing
time-frequency
disabled-control
step
azure-caching
new-operator
starling-framework
nomachine
google-oauth-java-client
cab
pyxplot
backbone-views
mosix
cloudmade
biztalk-deployment
vline
setcookie
yii-components
gssapi
netzke
winrt-async
jqueryi-ui-buttonset
wdm
httppostedfilebase
soapexception
symfony-1.2
cinder
iphone-maps
p4.net
pitch-shifting
linq-to-mysql
versions
html-help-workshop
high-load

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App