| 1 |
--- |
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
version: 0.2 |
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
env: |
| 23 |
shell: bash |
| 24 |
variables: |
| 25 |
NIX_CACHE_BUCKET: "s3://s2n-tls-nixcachebucket-x86-64?region=us-west-2" |
| 26 |
NIX_INSTALLER: "https://nixos.org/nix/install" |
| 27 |
S2N_KTLS_TESTING_EXPECTED: 1 |
| 28 |
S2N_KTLS_KEYUPDATE_TESTING_EXPECTED: 1 |
| 29 |
phases: |
| 30 |
pre_build: |
| 31 |
commands: |
| 32 |
- if [[ $(date +%u) -eq 0 ]]; then nix store gc;fi |
| 33 |
|
| 34 |
- mkdir -p ~/.config/nix |
| 35 |
- echo "extra-substituters = $NIX_CACHE_BUCKET" >> ~/.config/nix/nix.conf |
| 36 |
- echo "extra-trusted-substituters = $NIX_CACHE_BUCKET" >> ~/.config/nix/nix.conf |
| 37 |
- echo "require-sigs = false" >> ~/.config/nix/nix.conf |
| 38 |
|
| 39 |
- sudo modprobe tls |
| 40 |
- echo "Checking that the TLS kernel mod loaded..."; test $(sudo lsmod|grep -c tls) = 1 |
| 41 |
build: |
| 42 |
commands: |
| 43 |
- nix develop .#awslc --command bash -c 'source ./nix/shell.sh && clean && configure && unit' |
| 44 |
- S2N_CMAKE_OPTIONS="-DASAN=ON" nix develop .#awslc --command bash -c 'source ./nix/shell.sh && clean && configure && unit' |
| 45 |
post_build: |
| 46 |
commands: |
| 47 |
- nix copy --to $NIX_CACHE_BUCKET .#cache-awslc |
| 48 |
|