WIP: Dodaj wsparcie dla Dockera #128

Draft
d33tah wants to merge 44 commits from d33tah/rentgen:develop into develop
5 changed files with 13 additions and 28 deletions
Showing only changes of commit 1668d4e911 - Show all commits

View File

@ -47,10 +47,8 @@ FROM node:lts AS runtime
WORKDIR /app WORKDIR /app
# Copy built artifacts from builder # Copy built extension from builder
COPY --from=builder /app/web-ext-artifacts /app/web-ext-artifacts COPY --from=builder /app /app
COPY --from=builder /app/package.json /app/package-lock.json ./
COPY --from=builder /app/node_modules ./node_modules
# Install Firefox and Xvfb for headless execution (cached layer) # Install Firefox and Xvfb for headless execution (cached layer)
RUN apt-get update && apt-get install -y \ RUN apt-get update && apt-get install -y \

View File

@ -1,20 +0,0 @@
.PHONY: verify clean help
# Default target - run verification
verify:
@echo "Building and verifying Rentgen extension..."
docker compose up --force-recreate --build --abort-on-container-exit --exit-code-from rentgen_verify
@echo "✓ Verification completed successfully!"
# Clean up Docker resources
clean:
docker compose down --rmi local --volumes --remove-orphans
# Help target
help:
@echo "Rentgen Extension - Makefile"
@echo ""
@echo "Available targets:"
@echo " make verify - Build and verify extension (exits with error if verification fails)"
@echo " make clean - Clean up Docker resources"
@echo " make help - Show this help message"

View File

@ -1,7 +1,12 @@
services: services:
rentgen_check: rentgen_build:
build: . build: .
rentgen_check:
build:
context: .
target: code_quality
rentgen_run: rentgen_run:
build: build:
context: . context: .
@ -12,5 +17,5 @@ services:
rentgen_verify: rentgen_verify:
build: build:
context: . context: .
target: verify target: integration_test
restart: "no" restart: "no"

View File

@ -29,7 +29,7 @@
"content_scripts": [ "content_scripts": [
{ {
"matches": ["<all_urls>"], "matches": ["<all_urls>"],
"js": ["lib/test-content-script.js"], "js": ["lib/tests/test-content-script.js"],
"run_at": "document_end" "run_at": "document_end"
} }
], ],

View File

@ -19,7 +19,9 @@
"create-package:firefox": "web-ext build --overwrite-dest --artifacts-dir ../web-ext-artifacts", "create-package:firefox": "web-ext build --overwrite-dest --artifacts-dir ../web-ext-artifacts",
"create-package:chrome": "cd dist-chrome && 7z a -tzip ../web-ext-artifacts/rentgen-chrome-0.1.10.zip * && cd ..", "create-package:chrome": "cd dist-chrome && 7z a -tzip ../web-ext-artifacts/rentgen-chrome-0.1.10.zip * && cd ..",
"typecheck": "tsc --noEmit", "typecheck": "tsc --noEmit",
"lint": "web-ext lint" "lint": "web-ext lint",
"docker:verify": "docker compose up --force-recreate --build --abort-on-container-exit --exit-code-from rentgen_verify",
"docker:clean": "docker compose down --rmi local --volumes --remove-orphans"
}, },
"repository": { "repository": {
"type": "git", "type": "git",