小编Gan*_*rey的帖子

为什么 docker 容器以代码 0 退出?

我目前正在尝试使用 Botkit 框架创建一个 Messenger Bot!

由于我在不同的计算机上工作,我想使用 docker 来防止任何本地配置问题。

不幸的是,我是 botkit 和 docker 的新手。

文件结构

bot
??? README.md
??? docker
?   ??? botkit
?   ?   ??? Dockerfile
?   ??? node
?       ??? Dockerfile
??? docker-compose.yml
??? node_modules
??? package.json

4 directories, 5 files
Run Code Online (Sandbox Code Playgroud)

docker-compose.yml

version: "2"
services:
    node:
        build: ./docker/node
        volumes_from:
            - "app"
    botkit:
        build: ./docker/botkit
        links:
            - "node"
        volumes_from:
            - "app"
    app:
        image: "node:8"
        working_dir: /home/nook_bot
        environment:
            - NODE_ENV=production
        volumes:
            - .:/home/nook_bot
            - /home/nook_bot/node_modules
        command: "npm init --yes && npm …
Run Code Online (Sandbox Code Playgroud)

npm docker docker-compose botkit

6
推荐指数
2
解决办法
8915
查看次数

$near error - planner returned error: unable to find index for $geoNear query

I am having great trouble with this. I am building a little API to get the closest stored elements (in a mlab MongoDB) given specific coordinates.

\n\n

I want to get the closest elements from my DB using Mongo custom query tools like $near.

\n\n

You can find the original repo here!

\n\n

The Data

\n\n

The original data is a little .csv that I converted to geojson format.

\n\n

Here is a short version of that .csv:

\n\n …

geolocation mongoose mongodb geojson node.js

2
推荐指数
1
解决办法
7640
查看次数