Skip to content

Commit ae6c8ca

Browse files
committed
Add redis to dev server
1 parent 9d90740 commit ae6c8ca

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

dev/flake.nix

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,10 @@
3232
maxMemory = 100;
3333
port = 11212;
3434
};
35+
redisConfig = {
36+
maxMemory = memcachedConfig.maxMemory;
37+
port = 6379;
38+
};
3539
in
3640
inputs.flake-parts.lib.mkFlake { inherit inputs; } {
3741
systems = import inputs.systems;
@@ -91,6 +95,7 @@
9195
apcu
9296
imagick
9397
memcached
98+
redis
9499
]
95100
++ (if enableXDebug then [ xdebug ] else [ ])
96101
);
@@ -282,6 +287,13 @@
282287
package = php;
283288
phpOptions = phpOptions;
284289
};
290+
services.redis."redis1" = {
291+
enable = true;
292+
port = redisConfig.port;
293+
extraConfig = ''
294+
maxmemory ${toString redisConfig.maxMemory}mb
295+
'';
296+
};
285297
settings.processes."nginx1".depends_on."phpfpm1".condition = "process_healthy";
286298
settings.processes.test =
287299
let

0 commit comments

Comments
 (0)