This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Make sure you have this file in a folder along with your certs. | |
# Also, keep in mind that the filenames must follow the convention: | |
# - Certificate Authority Certificate must be named "ca.pem" | |
# - Client Certificate must be named "cert.pem" | |
# - Client Key must be named "key.pem" | |
# | |
# Run with `source env.sh` | |
export DOCKER_TLS_VERIFY=1 | |
export DOCKER_CERT_PATH="$(pwd)" | |
export DOCKER_HOST=tcp://your-host-name:2376 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
redis: | |
image: redis:alpine | |
ports: | |
- "6379" | |
networks: | |
- frontend | |
deploy: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
puts "Hello!" | |
puts "This is an application running on ruby #{RUBY_VERSION}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "2" | |
volumes: | |
log-data: | |
driver: local | |
services: | |
elasticsearch: | |
image: elasticsearch:5.0 | |
ports: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 1: Use node 6 as base: | |
FROM node:6-alpine | |
# 2: Download+Install PhantomJS, as the npm package 'phantomjs-prebuilt' won't work on alpine! | |
# See https://github.com/dustinblackman/phantomized | |
RUN set -ex \ | |
&& apk add --no-cache --virtual .build-deps ca-certificates openssl \ | |
&& wget -qO- "https://github.com/dustinblackman/phantomized/releases/download/2.1.1/dockerized-phantomjs.tar.gz" | tar xz -C / \ | |
&& npm install -g phantomjs \ | |
&& apk del .build-deps |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: "3.4" | |
volumes: | |
postgres-data: | |
services: | |
postgres: | |
image: postgres:10.3-alpine | |
volumes: | |
- postgres-data:/var/lib/postgresql/data |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# You can point the Sentry Client to another (i.e. self-hosted) instance by setting this environment variable: | |
SENTRY_DSN: http://xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx@sentry.icalialabs.com/[your_sentry_project_id] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Generate a rails model: | |
rails g model my_model title:string body:text |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Other parts of the file omitted for clarity: | |
# I: Runtime Stage: ============================================================ | |
FROM ruby:2.6.1-alpine AS runtime | |
WORKDIR /usr/src | |
ENV HOME=/usr/src PATH=/usr/src/bin:$PATH | |
RUN apk add --no-cache ca-certificates less libpq nodejs npm openssl su-exec tzdata |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# This file is located at `bin/rails` | |
# Load the 'switch_user_and_exec' routine: | |
require_relative '../config/switch_user_and_exec' | |
begin | |
load File.expand_path('../spring', __FILE__) | |
rescue LoadError => e |