hook.io icon indicating copy to clipboard operation
hook.io copied to clipboard

Error: image library/couchdb:latest not found

Open siuying opened this issue 9 years ago • 10 comments

Tried to clone the master and docker-compose pull, and get this error.

siuying avatar Dec 15 '15 04:12 siuying

@siuying -

The Dockerfile isn't fully supported right now.

I was trying to get Docker working for production but the current complexity of our stack was causing a bit of friction.

It would be super nice if we got the Dockerfile working for local development. I think that would really help in getting people to contribute to the project.

If you could make any changes to the Dockerfile to get it to work I'd be glad to merge. I have a few additional docker files I can check in as well as a docker-compose.yml if that would help.

Marak avatar Dec 15 '15 04:12 Marak

Yeah I'm just get started to get hook.io to work on my local machine. I'd fix the obvious issue first, and see if I can set it up locally.

siuying avatar Dec 15 '15 04:12 siuying

@siuying -

I added a few of the docker test files I was working with using docker-compose. I'm no expert in Docker. Any help would be appreciated.

We also have bash based installation scripts which should give you a good amount of information. It's a bit disorganized, but all the commands should be there.

https://github.com/bigcompany/hook.io/blob/master/scripts/install.sh https://github.com/bigcompany/hook.io/tree/master/scripts/install

Marak avatar Dec 15 '15 04:12 Marak

I'm no docker expert, but would you please have a look at #181? I have:

  • remove the worker image, we just need to use one image for both worker and server
  • setup couch (not yet complete, still need to setup authentication)
  • remove multiple worker, we can just use docker-compose to fire up multiple workers

Currently you can build and run it, but it crashes at

Error: Cannot find module 'hook.io-i18n'

siuying avatar Dec 15 '15 07:12 siuying

I added a line to install modules ...

RUN cd /src/modules && node install.js

but it fails with error:

 ---> Running in e53a08ba76d3
module.js:338
    throw err;
          ^
Error: Cannot find module '../lib/resources/modules'
    at Function.Module._resolveFilename (module.js:336:15)
    at Function.Module._load (module.js:278:25)
    at Module.require (module.js:365:17)
    at require (module.js:384:17)
    at Object.<anonymous> (/src/modules/install.js:6:9)
    at Module._compile (module.js:460:26)
    at Object.Module._extensions..js (module.js:478:10)
    at Module.load (module.js:355:32)
    at Function.Module._load (module.js:310:12)
    at Function.Module.runMain (module.js:501:10)
ERROR: Service 'worker' failed to build: The command '/bin/sh -c cd /src/modules && node install.js' returned a non-zero code: 1

I cant find '../lib/resources/modules'?

siuying avatar Dec 15 '15 07:12 siuying

@siuying -

I added the missing hook.io-i18n dependency to the package.json file

As for the /module/install.sh script, I think you can just ignore that for now ( comment it out ). That script is used for installing some common user-land npm modules for hook.io.

In a local testing setup, you shouldn't need those additional dependencies to get started.

Marak avatar Dec 15 '15 08:12 Marak

Now it crash at following:

hookio_1 | Using custom domains middleware [ 'hookio',
hookio_1 |   '0.0.0.0',
hookio_1 |   '192.168.59.103',
hookio_1 |   'localhost',
hookio_1 |   'hook.io',
hookio_1 |   'www.hook.io' ]
hookio_1 | _tls_common.js:108
hookio_1 |         c.context.setKey(options.key);
hookio_1 |                   ^
hookio_1 | Error: error:0906D06C:PEM routines:PEM_read_bio:no start line
hookio_1 |     at Error (native)
hookio_1 |     at Object.createSecureContext (_tls_common.js:108:19)
hookio_1 |     at Server (_tls_wrap.js:598:25)
hookio_1 |     at new Server (https.js:36:14)
hookio_1 |     at Object.exports.createServer (https.js:56:10)
hookio_1 |     at Server.<anonymous> (/src/node_modules/resource-http/lib/listen.js:266:31)
hookio_1 |     at Server.g (events.js:199:16)
hookio_1 |     at Server.emit (events.js:129:20)
hookio_1 |     at net.js:1171:12
hookio_1 |     at process._tickCallback (node.js:355:11)

This seems like the cert is not right. Can I configure such that it use no ssl when launch?

siuying avatar Dec 15 '15 11:12 siuying

Fixed this cert issue! Now it can be started.

siuying avatar Dec 15 '15 13:12 siuying

Nice! I'm really glad to see you got it started.

We'll probably want to add some test certificates or at least configure the app to not try to load the certs in local development mode.

Marak avatar Dec 16 '15 03:12 Marak

Docker file should be fully working now.

Closing.

Marak avatar Feb 28 '16 22:02 Marak