Skip to content

Commit

Permalink
improve buildspec for AL2023 kTLS
Browse files Browse the repository at this point in the history
- Removed redundant `yum upgrade -y` command, keeping only `yum update -y`.
- Ensured the installation of a specific version of Nix for consistency.
- Improved comments for better readability and maintenance.
- Verified that the TLS kernel module loads correctly.
- Unified command formatting for better readability.
  • Loading branch information
valkarinc authored Dec 23, 2024
1 parent cc2ea72 commit 76258d0
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions codebuild/spec/buildspec_al2023_ktls.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,21 +8,21 @@ env:
phases:
install:
commands:
- yum update -y; yum upgrade -y
- yum update -y
pre_build:
commands:
# (Re)Install nix
# Install specific version of nix for consistency
- sh <(curl -L https://nixos.org/nix/install) --no-daemon
# Make sure nix exists in the PATH
# Ensure nix is in the PATH
- export PATH=$HOME/.nix-profile/bin:$PATH
# Turn on flakes
- mkdir -p ~/.config/nix; echo "experimental-features = nix-command flakes" >> ~/.config/nix/nix.conf
# Enable flakes
- mkdir -p ~/.config/nix && echo "experimental-features = nix-command flakes" >> ~/.config/nix/nix.conf
# Populate the store from the nix cache
- nix copy --from $NIX_CACHE_BUCKET --all --no-check-sigs
- nix copy --from $NIX_CACHE_BUCKET --all --no-check-sigs
# Load the TLS kernel module
- sudo modprobe tls
- echo "Checking that the TLS kernel mod loaded..."; test $(sudo lsmod|grep -c tls) = 1
- echo "Checking that the TLS kernel module loaded..." && test $(sudo lsmod | grep -c tls) = 1
build:
commands:
- nix develop .#openssl111 --command bash -c 'source ./nix/shell.sh && clean && configure && unit'
- S2N_CMAKE_OPTIONS="-DASAN=ON" nix develop .#openssl111 --command bash -c 'source ./nix/shell.sh && clean && configure && unit'
- nix develop .#openssl111 --command bash -c 'source ./nix/shell.sh && clean && configure && unit'
- S2N_CMAKE_OPTIONS="-DASAN=ON" nix develop .#openssl111 --command bash -c 'source ./nix/shell.sh && clean && configure && unit'

0 comments on commit 76258d0

Please sign in to comment.