-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #247 from robzolkos/add-devcontainer
Add basic devcontainer
- Loading branch information
Showing
6 changed files
with
89 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
FROM ruby:3.3.0-slim-bullseye | ||
|
||
RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \ | ||
&& apt-get -y install --no-install-recommends \ | ||
apt-utils \ | ||
build-essential \ | ||
curl \ | ||
git \ | ||
imagemagick \ | ||
iproute2 \ | ||
libpq-dev \ | ||
openssh-client \ | ||
postgresql-client \ | ||
vim | ||
|
||
RUN gem install bundler | ||
RUN gem install foreman | ||
|
||
WORKDIR /workspace |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"name": "Maybe", | ||
"dockerComposeFile": "docker-compose.yml", | ||
"service": "app", | ||
"workspaceFolder": "/workspace", | ||
"containerEnv": { | ||
"GITHUB_TOKEN": "${localEnv:GITHUB_TOKEN}", | ||
"GITHUB_USER": "${localEnv:GITHUB_USER}" | ||
}, | ||
"remoteEnv": { | ||
"PATH": "/workspace/bin:${containerEnv:PATH}" | ||
}, | ||
"postCreateCommand": "bundle install" | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
version: "3" | ||
|
||
services: | ||
app: | ||
build: | ||
context: .. | ||
dockerfile: .devcontainer/Dockerfile | ||
|
||
volumes: | ||
- ..:/workspace:cached | ||
- bundle_cache:/bundle | ||
|
||
ports: | ||
- "3000:3000" | ||
|
||
command: sleep infinity | ||
|
||
environment: | ||
DB_HOST: db | ||
HOST: "0.0.0.0" | ||
|
||
depends_on: | ||
- db | ||
- redis | ||
|
||
redis: | ||
image: redis:latest | ||
ports: | ||
- "6379:6379" | ||
|
||
db: | ||
image: postgres:latest | ||
restart: unless-stopped | ||
volumes: | ||
- postgres-data:/var/lib/postgresql/data | ||
environment: | ||
POSTGRES_USER: postgres | ||
POSTGRES_DB: postgres | ||
POSTGRES_PASSWORD: postgres | ||
ports: | ||
- "5432:5432" | ||
|
||
volumes: | ||
postgres-data: | ||
bundle_cache: |
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
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
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