Reputation: 966
I’m looking to upgrade my app to run with docker-compose rather than using systemd unit files with docker. However my web app uses git so there is no .yml
file on my server. Every time I try to build a docker-compose image, my .yml
file can’t be found on the server. It returns:
ERROR:
Can't find a suitable configuration file in this directory or any
parent. Are you in the right directory?
Supported filenames: docker-compose.yml, docker-compose.yaml
How can I build a docker-compose image while using a git remote repo?
Upvotes: 1
Views: 357
Reputation: 1329522
You need to generate a docker-compose.yml
file (or copy it from an external referential) on your server.
That can be achieve through a post-receive (server-side) hook which can ensure, each time a new commit is pushed that:
docker-compose.yml
is still thereUpvotes: 1