Skip to content

Commit

Permalink
[Dev] Rework stack with domain name & other tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
ogizanagi committed Oct 30, 2023
1 parent 3a1c352 commit 57929a7
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 3 deletions.
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/webpack.config.js
18 changes: 16 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
.SILENT:
.PHONY: build

PORT_PREFIX = 429
PROJECT_DOMAIN = www.rix.ela.ooo

define manala_project_host
$(PROJECT_DOMAIN)$(if $(1),:$(PORT_PREFIX)$(shell printf "%02d" $(1)))
endef

-include .manala/Makefile

###########
Expand All @@ -25,12 +32,19 @@ serve:
npx concurrently "make serve.php" "make serve.assets" --names="Symfony,Webpack" --prefix=name --kill-others --kill-others-on-fail

## Dev - Start Symfony server
serve.php: export SYMFONY_PORT ?= $(PORT_PREFIX)80
serve.php:
symfony server:start --no-tls
$(call manala_message, Will be available at http://$(call manala_project_host):$(SYMFONY_PORT) )
-open http://www.rix.ela.ooo:$(SYMFONY_PORT)
symfony server:start --no-tls --port=$(SYMFONY_PORT)

## Dev - Start webpack dev server with HMR (Hot reload)
serve.assets: export WEBPACK_PORT ?= $(PORT_PREFIX)81
serve.assets:
npx encore dev-server --mode=development
npx encore dev-server \
--mode=development \
--port=$(WEBPACK_PORT) \
--host=$(PROJECT_DOMAIN)

## Dev - Watch assets
watch.assets:
Expand Down
2 changes: 1 addition & 1 deletion webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ Encore
options.liveReload = true;
options.watchFiles = [
'templates/**/*.twig',
'content/**/*.yaml',
'content/**/*.{yaml,md}',
];
})
;
Expand Down

0 comments on commit 57929a7

Please sign in to comment.