Skip to content

Commit a2db7f8

Browse files
committed
Initial
0 parents  commit a2db7f8

File tree

112 files changed

+9698
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

112 files changed

+9698
-0
lines changed

Diff for: .browserslistrc

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
defaults

Diff for: .devcontainer/Dockerfile

+44
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
# [Choice] Ruby version: 2, 2.7, 2.6, 2.5
2+
ARG VARIANT=2
3+
FROM mcr.microsoft.com/vscode/devcontainers/ruby:${VARIANT}
4+
5+
# Install Rails
6+
RUN gem install rails webdrivers
7+
8+
ARG NODE_VERSION="lts/*"
9+
RUN su vscode -c "source /usr/local/share/nvm/nvm.sh && nvm install ${NODE_VERSION} 2>&1"
10+
11+
# [Optional] Uncomment this section to install additional OS packages.
12+
# RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
13+
# && apt-get -y install --no-install-recommends <your-package-list-here>
14+
15+
# [Optional] Uncomment this line to install additional gems.
16+
# RUN gem install <your-gem-names-here>
17+
18+
# [Optional] Uncomment this line to install global node packages.
19+
# RUN su vscode -c "source /usr/local/share/nvm/nvm.sh && npm install -g <your-package-here>" 2>&1
20+
21+
# Install the railway cli
22+
RUN curl -sSL https://raw.githubusercontent.com/railwayapp/cli/master/install.sh | sudo sh
23+
24+
# Install bicep tooling
25+
RUN curl -Lo bicep https://github.com/Azure/bicep/releases/latest/download/bicep-linux-x64 \
26+
&& chmod +x ./bicep \
27+
&& sudo mv ./bicep /usr/local/bin/bicep
28+
29+
# Install Azure cli
30+
RUN curl -sL https://aka.ms/InstallAzureCLIDeb | sudo bash
31+
32+
# Install digital ocean cli
33+
RUN curl -sSLo doctl.tar.gz https://github.com/digitalocean/doctl/releases/download/v1.57.0/doctl-1.57.0-linux-amd64.tar.gz \
34+
&& tar xf doctl.tar.gz \
35+
&& sudo mv doctl /usr/local/bin
36+
37+
# Install GH cli
38+
RUN export DEBIAN_FRONTEND=noninteractive \
39+
&& sudo apt-get update \
40+
&& sudo apt -y install --no-install-recommends software-properties-common \
41+
&& sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-key C99B11DEB97541F0 \
42+
&& sudo apt-add-repository https://cli.github.com/packages \
43+
&& sudo apt-get update \
44+
&& sudo apt-get -y install --no-install-recommends gh

Diff for: .devcontainer/devcontainer.json

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"name": "Ruby on Rails (Community)",
3+
"dockerComposeFile": "docker-compose.yml",
4+
"service": "app",
5+
"workspaceFolder": "/workspace",
6+
// Set *default* container specific settings.json values on container create.
7+
"settings": {
8+
"terminal.integrated.shell.linux": "/bin/bash"
9+
},
10+
11+
// Add the IDs of extensions you want installed when the container is created.
12+
"extensions": [
13+
"rebornix.Ruby"
14+
],
15+
16+
// Use 'forwardPorts' to make a list of ports inside the container available locally.
17+
// "forwardPorts": [],
18+
19+
// Use 'postCreateCommand' to run commands after the container is created.
20+
"postCreateCommand": "bundle install",
21+
22+
// Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
23+
"remoteUser": "vscode"
24+
}

Diff for: .devcontainer/docker-compose.yml

+52
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
version: '3'
2+
3+
services:
4+
app:
5+
build:
6+
context: .
7+
dockerfile: Dockerfile
8+
args:
9+
# [Choice] Node.js version: 14, 12, 10
10+
VARIANT: 2
11+
# On Linux, you may need to update USER_UID and USER_GID below if not your local UID is not 1000.
12+
# USER_UID: 1000
13+
# USER_GID: 1000
14+
15+
volumes:
16+
- ..:/workspace:cached
17+
18+
environment:
19+
DATABASE_URL: postgresql://postgres:postgres@localhost:5432/postgres
20+
21+
# Overrides default command so things don't shut down after the process ends.
22+
command: sleep infinity
23+
24+
# Runs app on the same network as the database container, allows "forwardPorts" in devcontainer.json function.
25+
network_mode: service:db
26+
27+
# Uncomment the next line to use a non-root user for all processes.
28+
# user: node
29+
30+
# Use "forwardPorts" in **devcontainer.json** to forward an app port locally.
31+
# (Adding the "ports" property to this file will not forward from a Codespace.)
32+
33+
db:
34+
image: postgres:latest
35+
restart: unless-stopped
36+
volumes:
37+
- postgres-data:/var/lib/postgresql/data
38+
environment:
39+
POSTGRES_PASSWORD: postgres
40+
POSTGRES_USER: postgres
41+
POSTGRES_DB: postgres
42+
healthcheck:
43+
test: ["CMD-SHELL", "pg_isready -U postgres"]
44+
interval: 10s
45+
timeout: 5s
46+
retries: 5
47+
48+
# Add "forwardPorts": ["5432"] to **devcontainer.json** to forward PostgreSQL locally.
49+
# (Adding the "ports" property to this file will not forward from a Codespace.)
50+
51+
volumes:
52+
postgres-data:

Diff for: .gitattributes

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# See https://git-scm.com/docs/gitattributes for more about git attribute files.
2+
3+
# Mark the database schema as having been generated.
4+
db/schema.rb linguist-generated
5+
6+
# Mark the yarn lockfile as having been generated.
7+
yarn.lock linguist-generated
8+
9+
# Mark any vendored files as having been vendored.
10+
vendor/* linguist-vendored

Diff for: .gitignore

+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
# See https://help.github.com/articles/ignoring-files for more about ignoring files.
2+
#
3+
# If you find yourself ignoring temporary files generated by your text editor
4+
# or operating system, you probably want to add a global ignore instead:
5+
# git config --global core.excludesfile '~/.gitignore_global'
6+
7+
# Ignore bundler config.
8+
.bundle
9+
10+
# Ignore all logfiles and tempfiles.
11+
log/*
12+
tmp/*
13+
!log/.keep
14+
!tmp/.keep
15+
16+
# Ignore pidfiles, but keep the directory.
17+
tmp/pids/*
18+
!tmp/pids/
19+
!tmp/pids/.keep
20+
21+
# Ignore uploaded files in development.
22+
storage/*
23+
!storage/.keep
24+
25+
public/assets
26+
.byebug_history
27+
28+
# Ignore master key for decrypting credentials and more.
29+
config/master.key
30+
31+
public/packs
32+
public/packs-test
33+
node_modules
34+
yarn-error.log
35+
yarn-debug.log*
36+
.yarn-integrity

Diff for: .ruby-version

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2.7.2

Diff for: Gemfile

+56
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
source 'https://rubygems.org'
2+
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
3+
4+
ruby '2.7.2'
5+
6+
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
7+
gem 'rails', '~> 6.1.1'
8+
# Use postgresql as the database for Active Record
9+
gem 'pg', '~> 1.1'
10+
# Use Puma as the app server
11+
gem 'puma', '~> 5.0'
12+
# Use SCSS for stylesheets
13+
gem 'sass-rails', '>= 6'
14+
# Transpile app-like JavaScript. Read more: https://github.com/rails/webpacker
15+
gem 'webpacker', '~> 5.0'
16+
# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
17+
gem 'turbolinks', '~> 5'
18+
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
19+
gem 'jbuilder', '~> 2.7'
20+
# Use Redis adapter to run Action Cable in production
21+
# gem 'redis', '~> 4.0'
22+
# Use Active Model has_secure_password
23+
# gem 'bcrypt', '~> 3.1.7'
24+
25+
# Use Active Storage variant
26+
# gem 'image_processing', '~> 1.2'
27+
28+
# Reduces boot times through caching; required in config/boot.rb
29+
gem 'bootsnap', '>= 1.4.4', require: false
30+
31+
group :development, :test do
32+
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
33+
gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
34+
end
35+
36+
group :development do
37+
# Access an interactive console on exception pages or by calling 'console' anywhere in the code.
38+
gem 'web-console', '>= 4.1.0'
39+
# Display performance information such as SQL time and flame graphs for each request in your browser.
40+
# Can be configured to work on production as well see: https://github.com/MiniProfiler/rack-mini-profiler/blob/master/README.md
41+
gem 'rack-mini-profiler', '~> 2.0'
42+
gem 'listen', '~> 3.3'
43+
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
44+
gem 'spring'
45+
end
46+
47+
group :test do
48+
# Adds support for Capybara system testing and selenium driver
49+
gem 'capybara', '>= 3.26'
50+
gem 'selenium-webdriver'
51+
# Easy installation and use of web drivers to run system tests with browsers
52+
gem 'webdrivers'
53+
end
54+
55+
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
56+
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]

0 commit comments

Comments
 (0)