File tree 2 files changed +16
-2
lines changed
2 files changed +16
-2
lines changed Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ MIX_APP_NAME=Träwelling
4
4
APP_ENV = local
5
5
APP_KEY =
6
6
APP_DEBUG = true
7
- APP_URL = http://localhost
7
+ APP_URL = http://localhost:8000
8
8
FORCE_HTTPS = false
9
9
10
10
L5_SWAGGER_CONST_HOST = http://localhost:8000/api/v1
Original file line number Diff line number Diff line change 22
22
...
23
23
} : {
24
24
devenv . shells . default = { config , ...} : {
25
+ # See https://github.com/cachix/devenv/issues/528#issuecomment-1556108767
26
+ containers = lib . mkForce { } ;
25
27
languages = {
26
28
php . enable = true ;
27
29
javascript . enable = true ;
49
51
php = "${ config . languages . php . package } /bin/php" ;
50
52
npm = "${ config . languages . javascript . package } /bin/npm" ;
51
53
mysql = config . services . mysql . package ;
54
+
55
+ envKeys = builtins . attrNames config . env ;
56
+ unsetEnv = builtins . concatStringsSep "\n " (
57
+ map ( key : "unset ${ key } " ) envKeys
58
+ ) ;
52
59
in {
53
60
setup-devenv . exec = ''
54
61
set -eo pipefail
83
90
${ php } artisan passport:install > /dev/null
84
91
'' ;
85
92
serve . exec = ''
86
- APP_URL=http://localhost:8000 ${ npm } run dev &
93
+ # Unset .env variables, so laravel reads the .env files by itself
94
+ ${ unsetEnv }
95
+ ${ npm } run dev &
87
96
${ php } artisan serve
88
97
'' ;
98
+ artisan . exec = ''
99
+ # Unset .env variables, so laravel reads the .env files by itself
100
+ ${ unsetEnv }
101
+ exec ${ php } artisan $@
102
+ '' ;
89
103
} ;
90
104
} ;
91
105
formatter = pkgs . alejandra ;
You can’t perform that action at this time.
0 commit comments