Skip to content

Commit

Permalink
Move code, for consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
MisterDA committed Mar 10, 2023
1 parent aa18262 commit 64b9d46
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
1 change: 1 addition & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
unreleased
----------

- Optimize and fix Linux package install (@MisterDA #153)
- Various LCU Updates (@mtelvers #144 #136 #135)
- Support mounts, networks, and security parameters in RUN
commands, add buildkit_syntax helper function.
Expand Down
14 changes: 7 additions & 7 deletions src-opam/linux.ml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,13 @@ module RPM = struct
let groupinstall fmt =
ksprintf (fun s -> run "yum groupinstall -y %s && yum clean all" s) fmt

let dev_packages ?extra () =
install
"sudo passwd bzip2 patch rsync nano gcc-c++ git tar curl xz libX11-devel \
which m4 diffutils findutils%s"
(match extra with None -> "" | Some x -> " " ^ x)
@@ groupinstall "\"Development Tools\""

let add_user ?uid ?gid ?(sudo = false) username =
let uid = match uid with Some u -> sprintf "-u %d " u | None -> "" in
let gid = match gid with Some g -> sprintf "-g %d " g | None -> "" in
Expand All @@ -60,13 +67,6 @@ module RPM = struct
@@ env [ ("HOME", home) ]
@@ workdir "%s" home @@ run "mkdir .ssh" @@ run "chmod 700 .ssh"

let dev_packages ?extra () =
install
"sudo passwd bzip2 patch rsync nano gcc-c++ git tar curl xz libX11-devel \
which m4 diffutils findutils%s"
(match extra with None -> "" | Some x -> " " ^ x)
@@ groupinstall "\"Development Tools\""

let install_system_ocaml = install "ocaml ocaml-camlp4-devel ocaml-ocamldoc"
end

Expand Down

0 comments on commit 64b9d46

Please sign in to comment.