canvas-lms
canvas-lms copied to clipboard
Unable to build dev docker image
Summary:
Docker Building process in ./script/docker_dev_setup.sh
will be terminated in PostgreSQL building process. I suspect the problem came from dory-dnsmasq
docker image which replace system's systemd-resolve.service
.
Steps to reproduce:
- A fresh Ubuntu 18.04 machine with Docker 18.06.1 CE (I'm using pre-build image from DigitalOcean)
- clone the source to machine
- cd into the source and run
./script/docker_dev_setup.sh
Expected behavior:
A successful build
Actual behavior:
Build stopped with message
ERROR: Service 'postgres' failed to build: Get https://registry-1.docker.io/v2/: dial tcp: lookup registry-1.docker.io on 127.0.0.53:53: read udp 127.0.0.1:60012->127.0.0.53:53: i/o timeout
Ping a host with DNS name will fail
user@docker-s-2vcpu-4gb-sfo2-02:~/canvas-lms$ ping www.google.com
ping: www.google.com: Temporary failure in name resolution
Additional notes:
N/A
I would also suspect dory-dnsmasq
as well. It may help to check if Dory is properly configured and running:
dory status
Also check out https://github.com/freedomben/dory
@tierra I just checked and as you said. dory
is the problem which resolve
isn't setup to use. I will try to set it up and report back.
root@docker-s-4vcpu-8gb-sfo2-01:~/canvas-lms# dory status
[*] Nginx proxy: Running as docker container dory_dinghy_http_proxy
[*] Dnsmasq: Running as docker container dory_dnsmasq
[*] Resolv is not configured
root@docker-s-4vcpu-8gb-sfo2-01:~/canvas-lms#
dory up
will fix the name resolve problem but it reoccur every time after executing the script again thus never have a successful build of Canvas. Either web
or webpack
docker image building process cause the problem.
I'm seeing an almost identical issue here during my development setup build:
Welcome! This script will guide you through the process of setting up a
Canvas development environment with docker and dinghy/dory.
When you git pull new changes, you can run ./scripts/docker_dev_update.sh
to bring everything up to date.
> It looks like you're using Linux. You'll need dory. Let's set that up.
> Starting dory...
> Looks like dory is already running. Moving on...
> Now we can set up Canvas!
> Copying Canvas docker configuration...
OK to run 'cp docker-compose/config/* config/'? [y/n] y
> Building docker images...
Building postgres
Step 1/4 : FROM postgres:9.5
ERROR: Service 'postgres' failed to build: Get https://registry-1.docker.io/v2/: net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers)
If I go to the https://registry-1.docker.io/v2/
URL in a web browser, I receive the following JSON error message:
{"errors":[{"code":"UNAUTHORIZED","message":"authentication required","detail":null}]}
Several solutions I found on StackOverflow reference setting up a Docker proxy to access the required resource and I didn't check if dory up
fixes it.
I have the same issue. I am trying to setup Canvas LMS (quickstart) on Ubuntu using the ./script/docker_dev_setup.sh
script. sudo dory up
did fix the issue mentioned above, but it still fails. Can you just provide the the proper environment required for ./script/docker_dev_setup.sh
to work without issues? can I not just run it on a DigitalOcean dropplet and expect it to work? What's the point of it then if it doesn't work? What machine/OS/env did you test this command on?
This is the current error I am getting...
@yehya "Out of memory" indicates that you don't have enough memory on the system to perform asset compilation (which we generally recommend at least 8GB for). Your hostname hints that you're running this on a machine with only 1GB, so that would certainly be your problem.
P.S. Please open new issues for unrelated errors.
Thanks for contributing to this issue. As it has been 2 years since the last activity, we are automatically closing the issue in 30 days. This is often because the request was already solved in some way and it just wasn't updated or it's no longer applicable. If that's not the case, please respond before the issue is closed, or post a message on the mailing list. We'll gladly take a look again!