mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-11 23:17:33 +00:00
debug and pipeline dev containers
This commit is contained in:
@@ -14,3 +14,5 @@ RUN apt-get update && \
|
|||||||
libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth xvfb && \
|
libgtk2.0-0 libgtk-3-0 libgbm-dev libnotify-dev libnss3 libxss1 libasound2 libxtst6 xauth xvfb && \
|
||||||
apt-get clean && \
|
apt-get clean && \
|
||||||
corepack enable && COREPACK_ENABLE_DOWNLOAD_PROMPT=0 corepack prepare pnpm@9.1.2 --activate
|
corepack enable && COREPACK_ENABLE_DOWNLOAD_PROMPT=0 corepack prepare pnpm@9.1.2 --activate
|
||||||
|
|
||||||
|
USER node
|
@@ -17,8 +17,7 @@
|
|||||||
4200,
|
4200,
|
||||||
8080
|
8080
|
||||||
],
|
],
|
||||||
"remoteUser": "node",
|
"onCreateCommand": "pnpm install -g sass@1.64.1",
|
||||||
"onCreateCommand": "pnpm install -g sass@1.64.1 && pnpm install --frozen-lockfile --recursive",
|
|
||||||
"customizations": {
|
"customizations": {
|
||||||
"jetbrains": {
|
"jetbrains": {
|
||||||
"settings": {
|
"settings": {
|
||||||
|
@@ -2,13 +2,12 @@ services:
|
|||||||
|
|
||||||
devcontainer:
|
devcontainer:
|
||||||
container_name: devcontainer
|
container_name: devcontainer
|
||||||
user: node
|
|
||||||
build:
|
build:
|
||||||
context: .
|
context: .
|
||||||
volumes:
|
volumes:
|
||||||
- ../../:/workspaces:cached
|
- ../../:/workspaces:cached
|
||||||
- /tmp/.X11-unix:/tmp/.X11-unix:cached
|
- /tmp/.X11-unix:/tmp/.X11-unix:cached
|
||||||
- ~/.cache:/home/vscode/.cache:delegated
|
- home-dot-cache:/home/node/.cache:delegated
|
||||||
command: sleep infinity
|
command: sleep infinity
|
||||||
working_dir: /workspaces
|
working_dir: /workspaces
|
||||||
environment:
|
environment:
|
||||||
@@ -47,6 +46,7 @@ services:
|
|||||||
env_file: ../../apps/login/apps/login/.env.test
|
env_file: ../../apps/login/apps/login/.env.test
|
||||||
network_mode: service:devcontainer
|
network_mode: service:devcontainer
|
||||||
environment:
|
environment:
|
||||||
|
NODE_ENV: test
|
||||||
PORT: 3001
|
PORT: 3001
|
||||||
depends_on:
|
depends_on:
|
||||||
mock-zitadel:
|
mock-zitadel:
|
||||||
@@ -219,3 +219,4 @@ services:
|
|||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
postgres-data:
|
postgres-data:
|
||||||
|
home-dot-cache:
|
||||||
|
@@ -1,17 +1,16 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://raw.githubusercontent.com/devcontainers/spec/refs/heads/main/schemas/devContainer.schema.json",
|
"$schema": "https://raw.githubusercontent.com/devcontainers/spec/refs/heads/main/schemas/devContainer.schema.json",
|
||||||
"name": "debug-login-integration",
|
"name": "login-integration-debug",
|
||||||
"dockerComposeFile": [
|
"dockerComposeFile": [
|
||||||
"../base/docker-compose.yml",
|
"../base/docker-compose.yml",
|
||||||
"docker-compose.yml"
|
"docker-compose.yml"
|
||||||
],
|
],
|
||||||
"service": "debug-login-integration",
|
"service": "login-integration-debug",
|
||||||
"runServices": ["debug-login-integration"],
|
"runServices": ["login-integration-debug"],
|
||||||
"workspaceFolder": "/workspaces",
|
"workspaceFolder": "/workspaces",
|
||||||
"forwardPorts": [3001],
|
"forwardPorts": [3001],
|
||||||
"remoteUser": "node",
|
|
||||||
"onCreateCommand": "pnpm install --frozen-lockfile --recursive",
|
"onCreateCommand": "pnpm install --frozen-lockfile --recursive",
|
||||||
"postAttachCommand": "pnpm turbo daemon clean || pnpm turbo @zitadel/login#dev",
|
"postAttachCommand": "pnpm turbo daemon clean; pnpm turbo @zitadel/login#dev test:integration:login:debug",
|
||||||
"customizations": {
|
"customizations": {
|
||||||
"jetbrains": {
|
"jetbrains": {
|
||||||
"settings": {
|
"settings": {
|
@@ -1,12 +1,9 @@
|
|||||||
services:
|
services:
|
||||||
debug-login-integration:
|
login-integration-debug:
|
||||||
extends:
|
extends:
|
||||||
file: ../base/docker-compose.yml
|
file: ../base/docker-compose.yml
|
||||||
service: devcontainer
|
service: devcontainer
|
||||||
container_name: debug-login-integration
|
container_name: login-integration-debug
|
||||||
environment:
|
|
||||||
NODE_ENV: 'test'
|
|
||||||
PORT: 3001
|
|
||||||
depends_on:
|
depends_on:
|
||||||
mock-zitadel:
|
mock-zitadel:
|
||||||
condition: service_started
|
condition: service_started
|
19
.devcontainer/login-integration/devcontainer.json
Normal file
19
.devcontainer/login-integration/devcontainer.json
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
{
|
||||||
|
"$schema": "https://raw.githubusercontent.com/devcontainers/spec/refs/heads/main/schemas/devContainer.schema.json",
|
||||||
|
"name": "login-integration",
|
||||||
|
"dockerComposeFile": [
|
||||||
|
"../base/docker-compose.yml"
|
||||||
|
],
|
||||||
|
"service": "devcontainer",
|
||||||
|
"runServices": ["login-integration"],
|
||||||
|
"workspaceFolder": "/workspaces",
|
||||||
|
"forwardPorts": [3001],
|
||||||
|
"onCreateCommand": "pnpm install --frozen-lockfile --recursive && pnpm turbo test:integration:login",
|
||||||
|
"customizations": {
|
||||||
|
"jetbrains": {
|
||||||
|
"settings": {
|
||||||
|
"com.intellij:app:HttpConfigurable.use_proxy_pac": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@@ -1,17 +1,16 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://raw.githubusercontent.com/devcontainers/spec/refs/heads/main/schemas/devContainer.schema.json",
|
"$schema": "https://raw.githubusercontent.com/devcontainers/spec/refs/heads/main/schemas/devContainer.schema.json",
|
||||||
"name": "debug-turbo-lint-unit",
|
"name": "turbo-lint-unit-debug",
|
||||||
"dockerComposeFile": [
|
"dockerComposeFile": [
|
||||||
"../base/docker-compose.yml",
|
"../base/docker-compose.yml",
|
||||||
"docker-compose.yml"
|
"docker-compose.yml"
|
||||||
],
|
],
|
||||||
"service": "debug-turbo-lint-unit",
|
"service": "turbo-lint-unit-debug",
|
||||||
"runServices": ["debug-turbo-lint-unit"],
|
"runServices": ["turbo-lint-unit-debug"],
|
||||||
"workspaceFolder": "/workspaces",
|
"workspaceFolder": "/workspaces",
|
||||||
"forwardPorts": [3001],
|
"forwardPorts": [3001],
|
||||||
"remoteUser": "node",
|
|
||||||
"onCreateCommand": "pnpm install --frozen-lockfile --recursive",
|
"onCreateCommand": "pnpm install --frozen-lockfile --recursive",
|
||||||
"postAttachCommand": "pnpm turbo daemon clean || pnpm turbo watch lint test:unit",
|
"postAttachCommand": "pnpm turbo daemon clean; pnpm turbo watch lint test:unit",
|
||||||
"customizations": {
|
"customizations": {
|
||||||
"jetbrains": {
|
"jetbrains": {
|
||||||
"settings": {
|
"settings": {
|
@@ -1,6 +1,6 @@
|
|||||||
services:
|
services:
|
||||||
debug-turbo-lint-unit:
|
turbo-lint-unit-debug:
|
||||||
extends:
|
extends:
|
||||||
file: ../base/docker-compose.yml
|
file: ../base/docker-compose.yml
|
||||||
service: devcontainer
|
service: devcontainer
|
||||||
container_name: debug-turbo-lint-unit
|
container_name: turbo-lint-unit-debug
|
18
.devcontainer/turbo-lint-unit/devcontainer.json
Normal file
18
.devcontainer/turbo-lint-unit/devcontainer.json
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
"$schema": "https://raw.githubusercontent.com/devcontainers/spec/refs/heads/main/schemas/devContainer.schema.json",
|
||||||
|
"name": "turbo-lint-unit",
|
||||||
|
"dockerComposeFile": [
|
||||||
|
"../base/docker-compose.yml"
|
||||||
|
],
|
||||||
|
"service": "devcontainer",
|
||||||
|
"runServices": ["devcontainer"],
|
||||||
|
"workspaceFolder": "/workspaces",
|
||||||
|
"onCreateCommand": "pnpm install --frozen-lockfile --recursive && pnpm turbo lint test:unit",
|
||||||
|
"customizations": {
|
||||||
|
"jetbrains": {
|
||||||
|
"settings": {
|
||||||
|
"com.intellij:app:HttpConfigurable.use_proxy_pac": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@@ -2,7 +2,8 @@
|
|||||||
"name": "login-test-integration",
|
"name": "login-test-integration",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test:integration": "DISPLAY='' dotenv -e ../../apps/login/.env.test cypress"
|
"test:integration:login": "cypress run",
|
||||||
|
"test:integration:login:debug": "cypress open"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/node": "^22.14.1",
|
"@types/node": "^22.14.1",
|
||||||
|
@@ -4,9 +4,7 @@
|
|||||||
"name": "zitadel-monorepo",
|
"name": "zitadel-monorepo",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"changeset": "changeset",
|
"changeset": "changeset",
|
||||||
"devcontainer": "devcontainer",
|
"devcontainer": "devcontainer"
|
||||||
"test:integration": "cd apps/login/packages/integration && pnpm test:integration",
|
|
||||||
"test:acceptance": "cd apps/login/packages/acceptance && pnpm test:acceptance"
|
|
||||||
},
|
},
|
||||||
"pnpm": {
|
"pnpm": {
|
||||||
"overrides": {
|
"overrides": {
|
||||||
|
@@ -14,6 +14,7 @@
|
|||||||
"NEXT_PUBLIC_BASE_PATH",
|
"NEXT_PUBLIC_BASE_PATH",
|
||||||
"CUSTOM_REQUEST_HEADERS",
|
"CUSTOM_REQUEST_HEADERS",
|
||||||
"NODE_ENV",
|
"NODE_ENV",
|
||||||
|
"PORT",
|
||||||
"INKEEP_API_KEY",
|
"INKEEP_API_KEY",
|
||||||
"DISPLAY",
|
"DISPLAY",
|
||||||
"CYPRESS_DISPLAY"
|
"CYPRESS_DISPLAY"
|
||||||
@@ -27,14 +28,15 @@
|
|||||||
"with": [
|
"with": [
|
||||||
"lint",
|
"lint",
|
||||||
"test:unit",
|
"test:unit",
|
||||||
"test:integration",
|
"test:integration:login",
|
||||||
"test:acceptance",
|
"test:acceptance",
|
||||||
"test:e2e"
|
"test:e2e"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"start": {},
|
"start": {},
|
||||||
"test:unit": {},
|
"test:unit": {},
|
||||||
"test:integration": {},
|
"test:integration:login": {},
|
||||||
|
"test:integration:login:debug": {},
|
||||||
"test:acceptance": {},
|
"test:acceptance": {},
|
||||||
"test:e2e": {},
|
"test:e2e": {},
|
||||||
"lint": {},
|
"lint": {},
|
||||||
|
Reference in New Issue
Block a user