Skip to content

Instantly share code, notes, and snippets.

@mwlang
Created July 6, 2019 01:26
Show Gist options
  • Save mwlang/5f9faaabf973ce8ec7c9c1e823bd2d46 to your computer and use it in GitHub Desktop.
Save mwlang/5f9faaabf973ce8ec7c9c1e823bd2d46 to your computer and use it in GitHub Desktop.
docker-compose up --build
Creating network "maestro_default" with the default driver
Creating volume "maestro_data" with default driver
Creating volume "maestro_nodes" with default driver
Creating volume "maestro_shards" with default driver
Pulling db (postgres:11.3)...
11.3: Pulling from library/postgres
fc7181108d40: Pull complete
81cfa12d39e9: Pull complete
793d305ca761: Pull complete
41e3ced3a2aa: Pull complete
a300bc9d5405: Pull complete
3c6a5c3830ed: Pull complete
fb8c79b24338: Pull complete
fcda1144379f: Pull complete
476a22a819cc: Pull complete
78b36b49bb24: Pull complete
6a096a28591f: Pull complete
c0cb89b5217b: Pull complete
778f1469a309: Pull complete
7c4413fcad87: Pull complete
Building app
Step 1/8 : FROM crystallang/crystal:latest
---> 94db55f89e70
Step 2/8 : WORKDIR /app
---> Using cache
---> f59c4e15e9c1
Step 3/8 : COPY shard.* /app/
---> d96dab4b6504
Step 4/8 : RUN shards install
---> Running in e934922740d0
Fetching https://github.com/luckyframework/lucky.git
Fetching https://github.com/luckyframework/lucky_cli.git
Fetching https://github.com/mosop/teeplate.git
Fetching https://github.com/luckyframework/habitat.git
Fetching https://github.com/luckyframework/wordsmith.git
Fetching https://github.com/luckyframework/avram.git
Fetching https://github.com/kostya/blank.git
Fetching https://github.com/crystal-lang/crystal-db.git
Fetching https://github.com/will/crystal-pg.git
Fetching https://github.com/luckyframework/dexter.git
Fetching https://github.com/luckyframework/lucky_router.git
Fetching https://github.com/luckyframework/shell-table.cr.git
Fetching https://github.com/paulcsmith/cry.git
Fetching https://github.com/mosop/cli.git
Fetching https://github.com/mosop/optarg.git
Fetching https://github.com/mosop/callback.git
Fetching https://github.com/mosop/string_inflection.git
Fetching https://github.com/crystal-loot/exception_page.git
Fetching https://github.com/luckyframework/authentic.git
Fetching https://github.com/luckyframework/carbon.git
Fetching https://github.com/gdotdesign/cr-dotenv.git
Fetching https://github.com/luckyframework/lucky_flow.git
Fetching https://github.com/ysbaddaden/selenium-webdriver-crystal.git
Fetching https://github.com/stefanwille/crystal-redis.git
Fetching https://github.com/ysbaddaden/pool.git
Fetching https://github.com/mwlang/binance.git
Fetching https://github.com/crystal-community/cossack.git
Installing lucky (0.15.1)
Postinstall script/precompile_tasks
Installing lucky_cli (0.15.0)
Installing teeplate (0.7.0)
Installing habitat (0.4.3)
Installing wordsmith (0.2.0)
Installing avram (0.10.0)
Postinstall script/precompile_tasks
Installing blank (0.1.0)
Installing db (0.5.1)
Installing pg (0.16.1)
Installing dexter (0.1.1)
Installing lucky_router (0.2.2)
Installing shell-table (0.9.2 at refactor/setter)
Installing cry (0.4.0)
Installing cli (0.7.0)
Installing optarg (0.5.8)
Installing callback (0.6.3)
Installing string_inflection (0.2.1)
Installing exception_page (0.1.2)
Installing authentic (0.3.0)
Installing carbon (0.1.0)
Installing dotenv (0.2.0)
Installing lucky_flow (0.4.1)
Installing selenium (0.4.0 at a6d0e63ab7ddc6a20923bf4157bc6247c1fa2acc)
Installing redis (2.1.1)
Installing pool (0.2.3)
Installing binance (0.2.6 at HEAD)
Installing cossack (0.1.4)
Removing intermediate container e934922740d0
---> 976898d2b703
Step 5/8 : COPY . /app
---> 05098d2ba58b
Step 6/8 : RUN crystal build src/maestro.cr -o /app/bin/maestro --release
---> Running in 31936d5785ea
Removing intermediate container 31936d5785ea
---> 60025b786e52
Step 7/8 : RUN rm -rf /app/node_modules
---> Running in e6dd175d2a3d
Removing intermediate container e6dd175d2a3d
---> b6b161814410
Step 8/8 : CMD /app/bin/maestro
---> Running in 1b3b882a84e1
Removing intermediate container 1b3b882a84e1
---> 856363655bf0
Successfully built 856363655bf0
Successfully tagged maestro:latest
Creating maestro_db_1 ... done
Creating maestro_app_1 ... error
ERROR: for maestro_app_1 Cannot start service app: OCI runtime create failed: container_linux.go:344: starting container process caused "exec: \"/app/bin/maestro\": stat /app/bin/maestro: no such file or directory": unknown
ERROR: for app Cannot start service app: OCI runtime create failed: container_linux.go:344: starting container process caused "exec: \"/app/bin/maestro\": stat /app/bin/maestro: no such file or directory": unknown
ERROR: Encountered errors while bringing up the project.
09:21:33:maestro >> docker-compose up --build
Building app
Step 1/8 : FROM crystallang/crystal:latest
---> 94db55f89e70
Step 2/8 : WORKDIR /app
---> Using cache
---> f59c4e15e9c1
Step 3/8 : COPY shard.* /app/
---> Using cache
---> d96dab4b6504
Step 4/8 : RUN shards install
---> Using cache
---> 976898d2b703
Step 5/8 : COPY . /app
---> 563343b61f0b
Step 6/8 : RUN crystal build src/maestro.cr --release
---> Running in 3a8624598b6f
Removing intermediate container 3a8624598b6f
---> 9298f75dfecb
Step 7/8 : RUN rm -rf /app/node_modules
---> Running in 76ec1c3d10fc
Removing intermediate container 76ec1c3d10fc
---> afeb99b3ef0a
Step 8/8 : CMD maestro
---> Running in 89845ec1632e
Removing intermediate container 89845ec1632e
---> 2f3f80553060
Successfully built 2f3f80553060
Successfully tagged maestro:latest
maestro_db_1 is up-to-date
Recreating maestro_app_1 ... error
ERROR: for maestro_app_1 Cannot start service app: OCI runtime create failed: container_linux.go:344: starting container process caused "exec: \"/app/bin/maestro\": stat /app/bin/maestro: no such file or directory": unknown
ERROR: for app Cannot start service app: OCI runtime create failed: container_linux.go:344: starting container process caused "exec: \"/app/bin/maestro\": stat /app/bin/maestro: no such file or directory": unknown
ERROR: Encountered errors while bringing up the project.
version: '3'
services:
db:
image: postgres:11.3
environment:
- POSTGRES_DB=maestro
- POSTGRES_USER=lucky
- POSTGRES_PASSWORD=developer
ports:
- "5432:5432"
volumes:
- data:/var/lib/postgresql/data
app:
build: .
image: maestro
command: /app/bin/maestro
environment:
- DATABASE_URL=postgres://lucky:developer@db:5432/maestro
- DB_HOST=db
- DB_USERNAME=lucky
- DB_PASSWORD=developer
ports:
- "3000:3000"
links:
- db
volumes:
- .:/app
- nodes:/app/node_modules
- shards:/app/lib
depends_on:
- db
volumes:
data:
nodes:
shards:
FROM crystallang/crystal:latest
WORKDIR /app
COPY shard.* /app/
RUN shards install
COPY . /app
RUN crystal build src/maestro.cr -o /app/bin/maestro --release
RUN rm -rf /app/node_modules
CMD /app/bin/maestro
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment