-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Updated packer AMI building recipee (#17) * Update aws-ubuntu.pkr.hcl * initial commit * removed Docker related lines, moved installs to AMI creation * changed enroot runtime directory; removed .sqsh download * More updates * added enroot.conf; changed comments in post_install.bash * Moved enroot conf to packer Updated tests and installing script * Updated post_install.bash Co-authored-by: vfdev <[email protected]>
- Loading branch information
Showing
10 changed files
with
146 additions
and
41 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
#ENROOT_LIBRARY_PATH /usr/local/lib/enroot | ||
#ENROOT_SYSCONF_PATH /usr/local/etc/enroot | ||
ENROOT_RUNTIME_PATH ${ENROOT_RUNTIME_DIR:-/tmp/enroot_runtime/${UID}} | ||
#ENROOT_CONFIG_PATH ${XDG_CONFIG_HOME}/enroot | ||
ENROOT_CACHE_PATH ${ENROOT_CACHE_DIR:-/tmp/enroot_cache/${UID}} | ||
ENROOT_DATA_PATH ${ENROOT_DATA_DIR:-/tmp/enroot_data/${UID}} | ||
#ENROOT_TEMP_PATH ${TMPDIR:-/tmp} | ||
|
||
# Gzip program used to uncompress digest layers. | ||
#ENROOT_GZIP_PROGRAM gzip | ||
|
||
# Options passed to zstd to compress digest layers. | ||
#ENROOT_ZSTD_OPTIONS -1 | ||
|
||
# Options passed to mksquashfs to produce container images. | ||
#ENROOT_SQUASH_OPTIONS -comp lzo -noD | ||
|
||
# Make the container root filesystem writable by default. | ||
#ENROOT_ROOTFS_WRITABLE no | ||
|
||
# Remap the current user to root inside containers by default. | ||
#ENROOT_REMAP_ROOT no | ||
|
||
# Maximum number of processors to use for parallel tasks (0 means unlimited). | ||
#ENROOT_MAX_PROCESSORS $(nproc) | ||
|
||
# Maximum number of concurrent connections (0 means unlimited). | ||
#ENROOT_MAX_CONNECTIONS 10 | ||
|
||
# Maximum time in seconds to wait for connections establishment (0 means unlimited). | ||
#ENROOT_CONNECT_TIMEOUT 30 | ||
|
||
# Maximum time in seconds to wait for network operations to complete (0 means unlimited). | ||
#ENROOT_TRANSFER_TIMEOUT 0 | ||
|
||
# Number of times network operations should be retried. | ||
#ENROOT_TRANSFER_RETRIES 0 | ||
|
||
# Use a login shell to run the container initialization. | ||
#ENROOT_LOGIN_SHELL yes | ||
|
||
# Allow root to retain his superuser privileges inside containers. | ||
#ENROOT_ALLOW_SUPERUSER no | ||
|
||
# Use HTTP for outgoing requests instead of HTTPS (UNSECURE!). | ||
#ENROOT_ALLOW_HTTP no | ||
|
||
# Include user-specific configuration inside bundles by default. | ||
#ENROOT_BUNDLE_ALL no | ||
|
||
# Generate an embedded checksum inside bundles by default. | ||
#ENROOT_BUNDLE_CHECKSUM no | ||
|
||
# Mount the current user's home directory by default. | ||
#ENROOT_MOUNT_HOME no | ||
|
||
# Restrict /dev inside the container to a minimal set of devices. | ||
#ENROOT_RESTRICT_DEV no | ||
|
||
# Always use --force on command invocations. | ||
#ENROOT_FORCE_OVERRIDE no | ||
|
||
# SSL certificates settings: | ||
#SSL_CERT_DIR | ||
#SSL_CERT_FILE | ||
|
||
# Proxy settings: | ||
#all_proxy | ||
#no_proxy | ||
#http_proxy | ||
#https_proxy |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
script_folder="`dirname $0`" | ||
|
||
enroot_dir="./enroot" | ||
pyxis_dir="./pyxis" | ||
|
||
# Refs: | ||
# - https://github.com/NVIDIA/enroot/blob/v3.3.1/doc/installation.md | ||
# - https://github.com/NVIDIA/pyxis/wiki/Installation | ||
|
||
# Install enroot | ||
sudo apt-get update | ||
sudo apt-get install -y git gcc make libcap2-bin libtool automake zstd | ||
sudo apt-get install -y curl gawk jq squashfs-tools parallel | ||
|
||
# Setup Nvidia container runtime package | ||
curl -s -L https://nvidia.github.io/nvidia-container-runtime/gpgkey | sudo apt-key add - | ||
distribution=$(. /etc/os-release;echo $ID$VERSION_ID) | ||
curl -s -L https://nvidia.github.io/nvidia-container-runtime/$distribution/nvidia-container-runtime.list | sudo tee /etc/apt/sources.list.d/nvidia-container-runtime.list | ||
sudo apt-get update | ||
|
||
sudo apt-get install -y fuse-overlayfs libnvidia-container-tools pigz squashfuse | ||
git clone --recurse-submodules https://github.com/NVIDIA/enroot.git -b v3.3.1 $enroot_dir | ||
sudo make --directory=$enroot_dir install | ||
sudo make --directory=$enroot_dir setcap | ||
sudo rm -rf $enroot_dir | ||
sudo apt-get clean | ||
|
||
# Use our configuration: | ||
sudo cp $script_folder/enroot.conf /usr/local/etc/enroot/enroot.conf | ||
|
||
# Install pyxis | ||
if [ -f "/opt/slurm/include/slurm/slurm.h" ] ; then | ||
git clone https://github.com/NVIDIA/pyxis.git $pyxis_dir | ||
sudo ln -s /opt/slurm/include/slurm /usr/include/slurm | ||
sudo make --directory=$pyxis_dir install | ||
sudo rm -rf $pyxis_dir | ||
sudo apt-get clean | ||
fi | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters