1.6.0-debian-10-r0 release

This commit is contained in:
Bitnami Bot 2020-07-29 23:41:32 +00:00
parent d8a2abbbd5
commit 9661ed4bf5
5 changed files with 144 additions and 125 deletions

View File

@ -10,7 +10,7 @@ COPY prebuildfs /
# Install required system packages and dependencies
RUN install_packages acl ca-certificates curl gzip libc6 libgcc1 libgomp1 libquadmath0 libstdc++6 libx11-6 procps tar
RUN . /opt/bitnami/scripts/libcomponent.sh && component_unpack "miniconda" "4.8.3-0" --checksum 9d12cb843cac787a11da82348a5b545248cab365ca3ad5fe1938d0c786812534
RUN . /opt/bitnami/scripts/libcomponent.sh && component_unpack "pytorch" "1.5.1-0" --checksum 103ce9a91aa4bb786cedd71ee25e3c6ffda1c454a8c3ce7b3494e677f0d23080
RUN . /opt/bitnami/scripts/libcomponent.sh && component_unpack "pytorch" "1.6.0-0" --checksum 33468d12d8c329a282b26576b1495c889817f3a29f970118edefe02da78cd16f
RUN . /opt/bitnami/scripts/libcomponent.sh && component_unpack "gosu" "1.12.0-1" --checksum 51cfb1b7fd7b05b8abd1df0278c698103a9b1a4964bdacd87ca1d5c01631d59c
RUN apt-get update && apt-get upgrade -y && \
rm -r /var/lib/apt/lists /var/cache/apt/archives
@ -19,7 +19,7 @@ RUN chmod g+rwX /opt/bitnami
COPY rootfs /
RUN /opt/bitnami/scripts/pytorch/postunpack.sh
ENV BITNAMI_APP_NAME="pytorch" \
BITNAMI_IMAGE_VERSION="1.5.1-debian-10-r31" \
BITNAMI_IMAGE_VERSION="1.6.0-debian-10-r0" \
LD_LIBRARY_PATH="/opt/bitnami/miniconda/lib/python3.7/site-packages/torch/lib/:/opt/bitnami/miniconda/lib/python3.7/site-packages/PIL/.libs/:$LD_LIBRARY_PATH" \
PATH="/opt/bitnami/miniconda/bin:/opt/bitnami/common/bin:$PATH"

View File

@ -0,0 +1 @@
{"gosu": {"arch": "amd64", "digest": "51cfb1b7fd7b05b8abd1df0278c698103a9b1a4964bdacd87ca1d5c01631d59c", "distro": "debian-10", "type": "NAMI", "version": "1.12.0-1"}, "miniconda": {"arch": "amd64", "digest": "9d12cb843cac787a11da82348a5b545248cab365ca3ad5fe1938d0c786812534", "distro": "debian-10", "type": "NAMI", "version": "4.8.3-0"}, "pytorch": {"arch": "amd64", "digest": "33468d12d8c329a282b26576b1495c889817f3a29f970118edefe02da78cd16f", "distro": "debian-10", "type": "NAMI", "version": "1.6.0-0"}}

View File

@ -62,8 +62,4 @@ component_unpack() {
fi
tar --directory "${directory}" --extract --gunzip --file "${base_name}.tar.gz" --no-same-owner --strip-components=2 "${base_name}/files/"
rm "${base_name}.tar.gz"
# Include metadata about the package
touch "${directory}/.bitnami_packages"
echo "$base_name" >> "${directory}/.bitnami_packages"
}

View File

@ -2,19 +2,35 @@
#
# Bitnami web server handler library
# shellcheck disable=SC1091
# shellcheck disable=SC1090,SC1091
# Load generic libraries
. /opt/bitnami/scripts/liblog.sh
# Load web server libraries
[[ -f "/opt/bitnami/scripts/libapache.sh" ]] && . /opt/bitnami/scripts/libapache.sh
[[ -f "/opt/bitnami/scripts/libnginx.sh" ]] && . /opt/bitnami/scripts/libnginx.sh
########################
# Execute a command (or list of commands) with the web server environment and library loaded
# Globals:
# *
# Arguments:
# None
# Returns:
# None
#########################
web_server_execute() {
local -r web_server="${1:?missing web server}"
shift
# Run program in sub-shell to avoid web server environment getting loaded when not necessary
(
. "/opt/bitnami/scripts/lib${web_server}.sh"
. "/opt/bitnami/scripts/${web_server}-env.sh"
"$@"
)
}
########################
# Prints the list of enabled web servers
# Globals:
# WEB_SERVER_TYPE
# None
# Arguments:
# None
# Returns:
@ -32,7 +48,7 @@ web_server_list() {
########################
# Prints the currently-enabled web server type (only one, in order of preference)
# Globals:
# WEB_SERVER_TYPE
# None
# Arguments:
# None
# Returns:
@ -47,7 +63,7 @@ web_server_type() {
########################
# Validate that a supported web server is configured
# Globals:
# WEB_SERVER_*
# None
# Arguments:
# None
# Returns:
@ -65,7 +81,7 @@ web_server_validate() {
if [[ -z "$(web_server_type)" || ! " ${supported_web_servers[*]} " == *" $(web_server_type) "* ]]; then
print_validation_error "Could not detect any supported web servers. It must be one of: ${supported_web_servers[*]}"
elif ! type -t "is_$(web_server_type)_running" >/dev/null; then
elif ! web_server_execute "$(web_server_type)" type -t "is_$(web_server_type)_running" >/dev/null; then
print_validation_error "Could not load the $(web_server_type) web server library from /opt/bitnami/scripts. Check that it exists and is readable."
fi
@ -170,53 +186,56 @@ web_server_reload() {
########################
ensure_web_server_app_configuration_exists() {
local app="${1:?missing app}"
local -a web_servers args
shift
local -a apache_args nginx_args web_servers args_var
apache_args=("$app")
nginx_args=("$app")
# Validate arguments
while [[ "$#" -gt 0 ]]; do
case "$1" in
# Common flags
--hosts \
| --type \
| --allow-remote-connections \
| --disabled \
| --enable-https \
| --http-port \
| --https-port \
| --document-root \
)
apache_args+=("$1" "${2:?missing value}")
nginx_args+=("$1" "${2:?missing value}")
shift
;;
# Specific Apache flags
--apache-additional-configuration \
| --apache-before-vhost-configuration \
| --apache-allow-override \
| --apache-extra-directory-configuration \
| --apache-move-htaccess \
)
apache_args+=("${1//apache-/}" "${2:?missing value}")
shift
;;
# Specific NGINX flags
--nginx-additional-configuration)
nginx_args+=("${1//nginx-/}" "${2:?missing value}")
shift
;;
*)
echo "Invalid command line flag $1" >&2
return 1
;;
esac
shift
done
read -r -a web_servers <<< "$(web_server_list)"
for web_server in "${web_servers[@]}"; do
args=("$app")
# Validate arguments
shift
while [[ "$#" -gt 0 ]]; do
case "$1" in
# Common flags
--hosts \
| --type \
| --allow-remote-connections \
| --disabled \
| --enable-https \
| --http-port \
| --https-port \
| --document-root \
)
args+=("$1" "${2:?missing value}")
shift
;;
# Specific Apache flags
--apache-additional-configuration \
| --apache-before-vhost-configuration \
| --apache-allow-override \
| --apache-extra-directory-configuration \
| --apache-move-htaccess \
)
[[ "$web_server" == "apache" ]] && args+=("${1//apache-/}" "${2:?missing value}")
shift
;;
# Specific NGINX flags
--nginx-additional-configuration)
[[ "$web_server" == "nginx" ]] && args+=("${1//nginx-/}" "${2:?missing value}")
shift
;;
*)
echo "Invalid command line flag $1" >&2
return 1
;;
esac
shift
done
"ensure_${web_server}_app_configuration_exists" "${args[@]}"
args_var="${web_server}_args[@]"
web_server_execute "$web_server" "ensure_${web_server}_app_configuration_exists" "${!args_var}"
done
}
@ -235,7 +254,7 @@ ensure_web_server_app_configuration_not_exists() {
local -a web_servers
read -r -a web_servers <<< "$(web_server_list)"
for web_server in "${web_servers[@]}"; do
"ensure_${web_server}_app_configuration_not_exists" "$app"
web_server_execute "$web_server" "ensure_${web_server}_app_configuration_not_exists" "$app"
done
}
@ -263,48 +282,51 @@ ensure_web_server_app_configuration_not_exists() {
########################
ensure_web_server_prefix_configuration_exists() {
local app="${1:?missing app}"
local -a web_servers args
shift
local -a apache_args nginx_args web_servers args_var
apache_args=("$app")
nginx_args=("$app")
# Validate arguments
while [[ "$#" -gt 0 ]]; do
case "$1" in
# Common flags
--allow-remote-connections \
| --document-root \
| --prefix \
| --type \
)
apache_args+=("$1" "${2:?missing value}")
nginx_args+=("$1" "${2:?missing value}")
shift
;;
# Specific Apache flags
--apache-additional-configuration \
| --apache-allow-override \
| --apache-extra-directory-configuration \
| --apache-move-htaccess \
)
apache_args+=("${1//apache-/}" "$2")
shift
;;
# Specific NGINX flags
--nginx-additional-configuration)
nginx_args+=("${1//nginx-/}" "$2")
shift
;;
*)
echo "Invalid command line flag $1" >&2
return 1
;;
esac
shift
done
read -r -a web_servers <<< "$(web_server_list)"
for web_server in "${web_servers[@]}"; do
args=("$app")
# Validate arguments
shift
while [[ "$#" -gt 0 ]]; do
case "$1" in
# Common flags
--allow-remote-connections \
| --document-root \
| --prefix \
| --type \
)
args+=("$1" "${2:?missing value}")
shift
;;
# Specific Apache flags
--apache-additional-configuration \
| --apache-allow-override \
| --apache-extra-directory-configuration \
| --apache-move-htaccess \
)
[[ "$web_server" == "apache" ]] && args+=("${1//apache-/}" "$2")
shift
;;
# Specific NGINX flags
--nginx-additional-configuration)
[[ "$web_server" == "nginx" ]] && args+=("${1//nginx-/}" "$2")
shift
;;
*)
echo "Invalid command line flag $1" >&2
return 1
;;
esac
shift
done
"ensure_${web_server}_prefix_configuration_exists" "${args[@]}"
args_var="${web_server}_args[@]"
web_server_execute "$web_server" "ensure_${web_server}_prefix_configuration_exists" "${!args_var}"
done
}
@ -325,32 +347,32 @@ ensure_web_server_prefix_configuration_exists() {
########################
web_server_update_app_configuration() {
local app="${1:?missing app}"
local -a web_servers args
shift
local -a args web_servers
args=("$app")
# Validate arguments
while [[ "$#" -gt 0 ]]; do
case "$1" in
# Common flags
--hosts \
| --enable-https \
| --http-port \
| --https-port \
)
args+=("$1" "${2:?missing value}")
shift
;;
*)
echo "Invalid command line flag $1" >&2
return 1
;;
esac
shift
done
read -r -a web_servers <<< "$(web_server_list)"
for web_server in "${web_servers[@]}"; do
args=("$app")
# Validate arguments
shift
while [[ "$#" -gt 0 ]]; do
case "$1" in
# Common flags
--hosts \
| --enable-https \
| --http-port \
| --https-port \
)
args+=("$1" "${2:?missing value}")
shift
;;
*)
echo "Invalid command line flag $1" >&2
return 1
;;
esac
shift
done
"${web_server}_update_app_configuration" "${args[@]}"
web_server_execute "$web_server" "${web_server}_update_app_configuration" "${args[@]}"
done
}

View File

@ -41,7 +41,7 @@ Non-root container images add an extra layer of security and are generally recom
Learn more about the Bitnami tagging policy and the difference between rolling tags and immutable tags [in our documentation page](https://docs.bitnami.com/tutorials/understand-rolling-tags-containers/).
* [`1-debian-10`, `1.5.1-debian-10-r31`, `1`, `1.5.1`, `latest` (1/debian-10/Dockerfile)](https://github.com/bitnami/bitnami-docker-pytorch/blob/1.5.1-debian-10-r31/1/debian-10/Dockerfile)
* [`1-debian-10`, `1.6.0-debian-10-r0`, `1`, `1.6.0`, `latest` (1/debian-10/Dockerfile)](https://github.com/bitnami/bitnami-docker-pytorch/blob/1.6.0-debian-10-r0/1/debian-10/Dockerfile)
Subscribe to project updates by watching the [bitnami/pytorch GitHub repo](https://github.com/bitnami/bitnami-docker-pytorch).