Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit dcb002b

Browse files
committed
fix(flake.nix): Install locales on linux host devShells
Change-Id: I22dba63d317b41749c807a55e15278006cdcecad Signed-off-by: Thomas Kosiewski <[email protected]>
1 parent 0008c13 commit dcb002b

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

dogfood/contents/Dockerfile.nix

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Build stage
2-
FROM nixos/nix:2.19.2 as nix
2+
FROM nixos/nix:2.19.2 AS nix
33

44
# enable --experimental-features 'nix-command flakes' globally
55
# nix does not enable these features by default these are required to run commands like
@@ -14,7 +14,7 @@ RUN nix profile install "/app#all" --priority 4 && \
1414
nix-collect-garbage -d
1515

1616
# Final image
17-
FROM codercom/enterprise-base:latest as final
17+
FROM codercom/enterprise-base:latest AS final
1818

1919
# Set the non-root user
2020
USER root

flake.nix

+6-3
Original file line numberDiff line numberDiff line change
@@ -61,17 +61,19 @@
6161
# google-chrome is not available on OSX and aarch64 linux
6262
(if pkgs.stdenv.hostPlatform.isDarwin || pkgs.stdenv.hostPlatform.isAarch64 then null else google-chrome)
6363
# strace is not available on OSX
64-
(if pkgs.stdenv.hostPlatform.isDarwin then null else strace)
64+
(lib.optional ( !pkgs.stdenv.isDarwin ) strace)
6565
bat
6666
cairo
6767
curl
6868
delve
6969
drpc.defaultPackage.${system}
70+
fzf
7071
gcc
7172
gdk
7273
getopt
7374
gh
7475
git
76+
(lib.optional stdenv.isLinux glibcLocales)
7577
gnumake
7678
gnused
7779
go_1_22
@@ -87,6 +89,7 @@
8789
mockgen
8890
nfpm
8991
nodejs
92+
neovim
9093
pnpm
9194
openssh
9295
openssl
@@ -98,8 +101,6 @@
98101
protobuf
99102
proto_gen_go_1_30
100103
ripgrep
101-
# This doesn't build on latest nixpkgs (July 10 2024)
102-
(pinnedPkgs.sapling)
103104
shellcheck
104105
(pinnedPkgs.shfmt)
105106
sqlc
@@ -165,6 +166,8 @@
165166
export PLAYWRIGHT_BROWSERS_PATH=${pkgs.playwright-driver.browsers}
166167
export PLAYWRIGHT_SKIP_VALIDATE_HOST_REQUIREMENTS=true
167168
'';
169+
170+
LOCALE_ARCHIVE = with pkgs; lib.optional stdenv.isLinux "${glibcLocales}/lib/locale/locale-archive";
168171
};
169172
packages = {
170173
proto_gen_go = proto_gen_go_1_30;

0 commit comments

Comments
 (0)