Page MenuHomePhabricator

D7009.diff
No OneTemporary

D7009.diff

diff --git a/nix/mariadb-up-mac.nix b/nix/mariadb-up-mac.nix
--- a/nix/mariadb-up-mac.nix
+++ b/nix/mariadb-up-mac.nix
@@ -12,11 +12,15 @@
name = "mariadb-init";
text = ''
MARIADB_DIR=''${XDG_DATA_HOME:-$HOME/.local/share}/MariaDB
- # 'exec' allows for us to replace bash process with MariaDB
echo "View MariaDB logs: tail -f $MARIADB_DIR/logs" >&2
echo "Kill MariaDB server: pkill mariadbd" >&2
+ # Explicitly close fd3 to prevent `direnv` from hanging
+ # (https://linear.app/comm/issue/ENG-3254/remove-wait-logic-in-nix-develop)
+ exec 3>&-
+
+ # 'exec' allows for us to replace bash process with MariaDB
exec "${mariadb}/bin/mariadbd" \
--socket "$MARIADB_DIR"/mysql.sock \
--datadir "$MARIADB_DIR" \
diff --git a/nix/redis-up-mac.nix b/nix/redis-up-mac.nix
--- a/nix/redis-up-mac.nix
+++ b/nix/redis-up-mac.nix
@@ -15,7 +15,11 @@
echo "View Redis Logs: tail -f $REDIS_CACHE_DIR/logs" >&2
echo "Kill Redis server: pkill redis" >&2
- # 'exec' allows for us to replace bash process with MariaDB
+ # Explicitly close fd3 to prevent `direnv` from hanging
+ # (https://linear.app/comm/issue/ENG-3254/remove-wait-logic-in-nix-develop)
+ exec 3>&-
+
+ # 'exec' allows for us to replace bash process with Redis
exec ${redis}/bin/redis-server \
&> "$REDIS_CACHE_DIR"/logs
'';

File Metadata

Mime Type
text/plain
Expires
Thu, Nov 28, 4:36 PM (21 h, 53 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2594447
Default Alt Text
D7009.diff (1 KB)

Event Timeline