revert(dev): フロントエンド・バックエンドを分離する開発モードを廃止 (#15284)

* Revert "chore: 開発モードでフロントエンドとバックエンドを独立して起動するようにする(再) (#12593)"

This reverts commit b0039f0946.

* revert dev command

* revert embed dev

* 消しすぎた

* filesをプロキシするように

* fix chromatic ci

* Revert "filesをプロキシするように"

This reverts commit 41be2548ce.

* fix: configのhostnameでサーバーを起動するように

* fix

* lint

* Update Changelog

* fix

---------

Co-authored-by: syuilo <4439005+syuilo@users.noreply.github.com>
This commit is contained in:
かっこかり
2025-01-25 20:58:39 +09:00
committed by GitHub
parent 0a41e36b6d
commit 35104d87d5
14 changed files with 23 additions and 383 deletions

View File

@@ -317,16 +317,19 @@ export class ClientServerService {
done();
});
} else {
const configUrl = new URL(this.config.url);
const urlOriginWithoutPort = configUrl.origin.replace(/:\d+$/, '');
const port = (process.env.VITE_PORT ?? '5173');
fastify.register(fastifyProxy, {
upstream: 'http://localhost:' + port,
upstream: urlOriginWithoutPort + ':' + port,
prefix: '/vite',
rewritePrefix: '/vite',
});
const embedPort = (process.env.EMBED_VITE_PORT ?? '5174');
fastify.register(fastifyProxy, {
upstream: 'http://localhost:' + embedPort,
upstream: urlOriginWithoutPort + ':' + embedPort,
prefix: '/embed_vite',
rewritePrefix: '/embed_vite',
});