-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* initial commit for Devcontainers * switch to devcontainers * update bundler * update dependencies * switch to vite rails * externalize solid queue for debugging * rubocop * adapt CI * switch cuprite to playwright * fix leave spec * fix playwright step
- Loading branch information
1 parent
af6483c
commit 86c75c4
Showing
47 changed files
with
997 additions
and
596 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,42 @@ | ||
{ | ||
"name": "nerdgeschoss", | ||
"dockerComposeFile": "docker-compose.yml", | ||
"service": "app", | ||
"workspaceFolder": "/workspaces/${localWorkspaceFolderBasename}", | ||
"postCreateCommand": "bin/setup", | ||
"remoteUser": "root", | ||
"customizations": { | ||
"vscode": { | ||
"extensions": [ | ||
"dbaeumer.vscode-eslint", | ||
"GitHub.copilot", | ||
"esbenp.prettier-vscode", | ||
"sianglim.slim", | ||
"Shopify.ruby-lsp", | ||
"EditorConfig.EditorConfig", | ||
"eamodio.gitlens", | ||
"GraphQL.vscode-graphql", | ||
"bierner.markdown-mermaid" | ||
], | ||
"settings": { | ||
"typescript.tsdk": "node_modules/typescript/lib", | ||
"rubyLsp.rubyVersionManager": "none", | ||
"[ruby]": { | ||
"editor.formatOnSave": true, | ||
"editor.defaultFormatter": "Shopify.ruby-lsp" | ||
} | ||
} | ||
} | ||
}, | ||
"features": { | ||
"ghcr.io/devcontainers/features/desktop-lite:1": {} | ||
}, | ||
"forwardPorts": [ | ||
6080 | ||
], | ||
"portsAttributes": { | ||
"6080": { | ||
"label": "playwright" | ||
} | ||
} | ||
} |
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,36 @@ | ||
version: '3' | ||
|
||
services: | ||
app: | ||
image: ghcr.io/nerdgeschoss/nerdgeschoss/development-environment:3.3-18 | ||
volumes: | ||
- ../..:/workspaces:cached | ||
- nerdgeschoss_app-node_modules:/workspaces/nerdgeschoss_app/node_modules | ||
|
||
# Overrides default command so things don't shut down after the process ends. | ||
command: sleep infinity | ||
|
||
# Runs app on the same network as the database container, allows "forwardPorts" in devcontainer.json function. | ||
network_mode: service:db | ||
|
||
environment: | ||
REDIS_URL: redis://redis:6379 | ||
TZ: Europe/Berlin | ||
|
||
db: | ||
image: postgres:15.1 | ||
restart: unless-stopped | ||
volumes: | ||
- postgres-data:/var/lib/postgresql/data | ||
environment: | ||
POSTGRES_HOST_AUTH_METHOD: trust | ||
redis: | ||
image: redis | ||
restart: unless-stopped | ||
volumes: | ||
- redis-data:/data | ||
|
||
volumes: | ||
postgres-data: | ||
redis-data: | ||
nerdgeschoss_app-node_modules: |
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 |
---|---|---|
|
@@ -4,14 +4,18 @@ on: [push] | |
|
||
env: | ||
RAILS_MASTER_KEY: ${{ secrets.RAILS_MASTER_KEY }} | ||
RAILS_ENV: test | ||
DATABASE_URL: postgres://postgres:[email protected]:5432/app | ||
RSPEC_RETRY_RETRY_COUNT: 3 | ||
SCREENSHOTS: '1' | ||
|
||
jobs: | ||
ruby: | ||
runs-on: ubuntu-20.04 | ||
|
||
services: | ||
postgres: | ||
image: postgres:12 | ||
image: postgres:15 | ||
env: | ||
POSTGRES_USER: postgres | ||
POSTGRES_PASSWORD: postgres | ||
|
@@ -25,7 +29,7 @@ jobs: | |
- uses: actions/checkout@v2 | ||
- uses: actions/setup-node@v2 | ||
with: | ||
node-version: '16.x' | ||
node-version: '18.x' | ||
cache: yarn | ||
- name: Install yarn | ||
run: yarn install | ||
|
@@ -39,25 +43,16 @@ jobs: | |
run: bundle exec i18n-tasks health | ||
- name: Check Model Annotations | ||
run: bundle exec annotate --models && bin/git_tracked_are_unmodified | ||
env: | ||
DATABASE_URL: postgres://postgres:[email protected]:5432/app | ||
RAILS_ENV: test | ||
- name: JS Lint | ||
run: yarn lint | ||
- name: Build Assets | ||
run: yarn build | ||
- name: Install Playwright Browsers | ||
run: npx --yes playwright install --with-deps chromium | ||
- name: Build | ||
run: bundle exec rails assets:precompile | ||
- name: Create PG Database | ||
run: bundle exec rake db:create db:migrate | ||
env: | ||
DATABASE_URL: postgres://postgres:[email protected]:5432/app | ||
RAILS_ENV: test | ||
- name: Build and test with Rake | ||
- name: Build and test with RSpec | ||
run: bundle exec rspec --format documentation | ||
env: | ||
DATABASE_URL: postgres://postgres:[email protected]:5432/app | ||
RAILS_ENV: test | ||
RSPEC_RETRY_RETRY_COUNT: 3 | ||
SCREENSHOTS: '1' | ||
- name: Upload Screenshots | ||
if: always() | ||
run: | | ||
|
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 |
---|---|---|
|
@@ -35,3 +35,5 @@ node_modules | |
.DS_Store | ||
|
||
*.env | ||
/public/vite-dev | ||
/public/vite-test |
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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
AllCops: | ||
TargetRubyVersion: 3.1 | ||
SuggestExtensions: false | ||
|
||
inherit_gem: | ||
shimmer: config/rubocop_base.yml | ||
|
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 |
---|---|---|
@@ -1 +1 @@ | ||
3.1.4 | ||
3.3.1 |
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 was deleted.
Oops, something went wrong.
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,21 @@ | ||
{ | ||
// See https://go.microsoft.com/fwlink/?LinkId=733558 | ||
// for the documentation about the tasks.json format | ||
"version": "2.0.0", | ||
"tasks": [ | ||
{ | ||
"label": "Sleepdelay", | ||
"type": "shell", | ||
"command": "sleep 4", | ||
"windows": { | ||
"command": "ping 127.0.0.1 -n 4 > nul" | ||
}, | ||
"group": "none", | ||
"presentation": { | ||
"reveal": "silent", | ||
"panel": "new", | ||
"close": true | ||
} | ||
} | ||
] | ||
} |
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
Oops, something went wrong.