starter
This commit is contained in:
41
devenv.nix
Normal file
41
devenv.nix
Normal file
@@ -0,0 +1,41 @@
|
||||
{ pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
# https://devenv.sh/packages/
|
||||
packages = with pkgs; [
|
||||
bash
|
||||
elixir-ls
|
||||
] ++ lib.optionals stdenv.isLinux [ inotify-tools libnotify ];
|
||||
|
||||
env = {
|
||||
ERL_AFLAGS = "-kernel shell_history enabled";
|
||||
MIX_REBAR3 = "${pkgs.rebar3.outPath}/bin/rebar3";
|
||||
};
|
||||
|
||||
enterShell = ''
|
||||
export MIX_HOME="$PWD/.nix-mix"
|
||||
export HEX_HOME="$PWD/.nix-hex"
|
||||
mkdir -p "$MIX_HOME"
|
||||
mkdir -p "$HEX_HOME"
|
||||
export ESBUILD_PATH=${pkgs.esbuild}/bin/esbuild
|
||||
[[ "$PATH" =~ "$MIX_HOME/bin" ]] || export PATH="$MIX_HOME/bin:$PATH"
|
||||
[[ "$PATH" =~ "$HEX_HOME/bin" ]] || export PATH="$HEX_HOME/bin:$PATH"
|
||||
'';
|
||||
|
||||
services.postgres = {
|
||||
enable = true;
|
||||
initialScript = ''
|
||||
CREATE USER postgres SUPERUSER;
|
||||
'';
|
||||
};
|
||||
|
||||
services.rabbitmq = {
|
||||
enable = true;
|
||||
managementPlugin = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
languages.elixir.enable = true;
|
||||
languages.erlang.enable = true;
|
||||
}
|
||||
Reference in New Issue
Block a user