-
-
Notifications
You must be signed in to change notification settings - Fork 129
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
reduce configuration to minimal + run storybook inside docker
- Loading branch information
Showing
76 changed files
with
38,538 additions
and
2,461 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
#syntax=docker/dockerfile:1.4 | ||
|
||
|
||
# Versions | ||
FROM node:20-alpine AS node_upstream | ||
|
||
|
||
# Base stage for dev and build | ||
FROM node_upstream AS base | ||
|
||
# Check https://github.com/nodejs/docker-node/tree/b4117f9333da4138b03a546ec926ef50a31506c3#nodealpine to understand why libc6-compat might be needed. | ||
# hadolint ignore=DL3018 | ||
RUN apk add --no-cache libc6-compat | ||
|
||
WORKDIR /srv/app | ||
|
||
RUN corepack enable && \ | ||
corepack prepare --activate pnpm@latest && \ | ||
pnpm config -g set store-dir /.pnpm-store | ||
|
||
# Development image | ||
FROM base as dev | ||
|
||
EXPOSE 3000 | ||
ENV PORT 3000 | ||
ENV HOSTNAME localhost | ||
|
||
CMD ["sh", "-c", "pnpm install; pnpm storybook"] |
File renamed without changes.
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 |
---|---|---|
|
@@ -14,9 +14,13 @@ | |
# Run "composer dump-env prod" to compile .env files for production use (requires symfony/flex >=1.2). | ||
# https://symfony.com/doc/current/best_practices.html#use-environment-variables-for-infrastructure-configuration | ||
|
||
# API Platform distribution | ||
TRUSTED_PROXIES=127.0.0.0/8,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16 | ||
TRUSTED_HOSTS=^(localhost|php)$ | ||
|
||
###> symfony/framework-bundle ### | ||
APP_ENV=dev | ||
APP_SECRET=7aeabb40b0a766e29dec75f12f1e37c2 | ||
APP_SECRET=!ChangeMe! | ||
###< symfony/framework-bundle ### | ||
|
||
###> doctrine/doctrine-bundle ### | ||
|
@@ -26,9 +30,19 @@ APP_SECRET=7aeabb40b0a766e29dec75f12f1e37c2 | |
# DATABASE_URL="sqlite:///%kernel.project_dir%/var/data.db" | ||
# DATABASE_URL="mysql://app:[email protected]:3306/app?serverVersion=8.0.32&charset=utf8mb4" | ||
# DATABASE_URL="mysql://app:[email protected]:3306/app?serverVersion=10.11.2-MariaDB&charset=utf8mb4" | ||
DATABASE_URL="postgresql://app:!ChangeMe!@127.0.0.1:5432/app?serverVersion=15&charset=utf8" | ||
DATABASE_URL="postgresql://app:!ChangeMe!@database:5432/app?serverVersion=15&charset=utf8" | ||
###< doctrine/doctrine-bundle ### | ||
|
||
###> nelmio/cors-bundle ### | ||
CORS_ALLOW_ORIGIN='^https?://(localhost|127\.0\.0\.1)(:[0-9]+)?$' | ||
###< nelmio/cors-bundle ### | ||
|
||
###> symfony/mercure-bundle ### | ||
# See https://symfony.com/doc/current/mercure.html#configuration | ||
# The URL of the Mercure hub, used by the app to publish updates (can be a local URL) | ||
MERCURE_URL=http://php/.well-known/mercure | ||
# The public URL of the Mercure hub, used by the browser to connect | ||
MERCURE_PUBLIC_URL=https://localhost/.well-known/mercure | ||
# The secret used to sign the JWTs | ||
MERCURE_JWT_SECRET="!ChangeThisMercureHubJWTSecretKey!" | ||
###< symfony/mercure-bundle ### |
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,9 @@ | ||
# define your env variables for the test env here | ||
KERNEL_CLASS='App\Kernel' | ||
APP_SECRET='$ecretf0rt3st' | ||
SYMFONY_DEPRECATIONS_HELPER=999999 | ||
PANTHER_APP_ENV=panther | ||
PANTHER_ERROR_SCREENSHOT_DIR=./var/error-screenshots | ||
|
||
# API Platform distribution | ||
TRUSTED_HOSTS=^example\.com|localhost$ |
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 @@ | ||
/docker/db/data | ||
|
||
###> symfony/framework-bundle ### | ||
/.env.local | ||
/.env.local.php | ||
/.env.*.local | ||
/config/secrets/prod/prod.decrypt.private.php | ||
/public/bundles/ | ||
/var/ | ||
/vendor/ | ||
###< symfony/framework-bundle ### | ||
|
||
###> friendsofphp/php-cs-fixer ### | ||
/.php-cs-fixer.php | ||
/.php-cs-fixer.cache | ||
###< friendsofphp/php-cs-fixer ### | ||
|
||
###> symfony/phpunit-bridge ### | ||
.phpunit.result.cache | ||
/phpunit.xml | ||
###< symfony/phpunit-bridge ### |
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,13 @@ | ||
<?php | ||
|
||
$finder = (new PhpCsFixer\Finder()) | ||
->in(__DIR__) | ||
->exclude('var') | ||
; | ||
|
||
return (new PhpCsFixer\Config()) | ||
->setRules([ | ||
'@Symfony' => true, | ||
]) | ||
->setFinder($finder) | ||
; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# API | ||
|
||
The API will be here. | ||
|
||
Refer to the [Getting Started Guide](https://api-platform.com/docs/distribution) for more information. |
File renamed without changes.
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,98 @@ | ||
{ | ||
"type": "project", | ||
"license": "MIT", | ||
"require": { | ||
"php": ">=8.2", | ||
"ext-ctype": "*", | ||
"ext-iconv": "*", | ||
"api-platform/core": "^3.2", | ||
"doctrine/doctrine-bundle": "^2.7", | ||
"doctrine/doctrine-migrations-bundle": "^3.2", | ||
"doctrine/orm": "^3.0", | ||
"nelmio/cors-bundle": "^2.2", | ||
"phpstan/phpdoc-parser": "^1.16", | ||
"runtime/frankenphp-symfony": "^0.2", | ||
"symfony/asset": "6.4.*", | ||
"symfony/console": "6.4.*", | ||
"symfony/dotenv": "6.4.*", | ||
"symfony/expression-language": "6.4.*", | ||
"symfony/flex": "^2.2", | ||
"symfony/framework-bundle": "6.4.*", | ||
"symfony/mercure-bundle": "^0.3.5", | ||
"symfony/monolog-bundle": "^3.8", | ||
"symfony/property-access": "6.4.*", | ||
"symfony/property-info": "6.4.*", | ||
"symfony/runtime": "6.4.*", | ||
"symfony/security-bundle": "6.4.*", | ||
"symfony/serializer": "6.4.*", | ||
"symfony/twig-bundle": "6.4.*", | ||
"symfony/validator": "6.4.*", | ||
"symfony/yaml": "6.4.*" | ||
}, | ||
"require-dev": { | ||
"api-platform/schema-generator": "^5.0", | ||
"symfony/browser-kit": "6.4.*", | ||
"symfony/css-selector": "6.4.*", | ||
"symfony/debug-bundle": "6.4.*", | ||
"symfony/maker-bundle": "^1.44", | ||
"symfony/phpunit-bridge": "6.4.*", | ||
"symfony/stopwatch": "6.4.*", | ||
"symfony/var-dumper": "6.4.*", | ||
"symfony/web-profiler-bundle": "6.4.*" | ||
}, | ||
"config": { | ||
"optimize-autoloader": true, | ||
"preferred-install": { | ||
"*": "dist" | ||
}, | ||
"sort-packages": true, | ||
"allow-plugins": { | ||
"symfony/flex": true, | ||
"symfony/runtime": true | ||
} | ||
}, | ||
"autoload": { | ||
"psr-4": { | ||
"App\\": "src/" | ||
} | ||
}, | ||
"autoload-dev": { | ||
"psr-4": { | ||
"App\\Tests\\": "tests/" | ||
} | ||
}, | ||
"replace": { | ||
"paragonie/random_compat": "2.*", | ||
"symfony/polyfill-ctype": "*", | ||
"symfony/polyfill-iconv": "*", | ||
"symfony/polyfill-intl-grapheme": "*", | ||
"symfony/polyfill-intl-normalizer": "*", | ||
"symfony/polyfill-mbstring": "*", | ||
"symfony/polyfill-php82": "*", | ||
"symfony/polyfill-php81": "*", | ||
"symfony/polyfill-php80": "*", | ||
"symfony/polyfill-php72": "*" | ||
}, | ||
"scripts": { | ||
"auto-scripts": { | ||
"cache:clear": "symfony-cmd", | ||
"assets:install %PUBLIC_DIR%": "symfony-cmd" | ||
}, | ||
"post-install-cmd": [ | ||
"@auto-scripts" | ||
], | ||
"post-update-cmd": [ | ||
"@auto-scripts" | ||
] | ||
}, | ||
"conflict": { | ||
"symfony/symfony": "*" | ||
}, | ||
"extra": { | ||
"symfony": { | ||
"allow-contrib": false, | ||
"require": "6.4.*", | ||
"docker": false | ||
} | ||
} | ||
} |
Oops, something went wrong.