[bitnami/wordpress] Release 6.1.1-debian-11-r48 (#24149)
Signed-off-by: Bitnami Containers <bitnami-bot@vmware.com>
This commit is contained in:
parent
41343afbdc
commit
22d7069bce
|
|
@ -3,10 +3,10 @@ FROM docker.io/bitnami/minideb:bullseye
|
|||
ARG TARGETARCH
|
||||
|
||||
LABEL org.opencontainers.image.base.name="docker.io/bitnami/minideb:bullseye" \
|
||||
org.opencontainers.image.created="2023-02-15T15:34:31Z" \
|
||||
org.opencontainers.image.created="2023-02-16T17:50:30Z" \
|
||||
org.opencontainers.image.description="Application packaged by VMware, Inc" \
|
||||
org.opencontainers.image.licenses="Apache-2.0" \
|
||||
org.opencontainers.image.ref.name="6.1.1-debian-11-r47" \
|
||||
org.opencontainers.image.ref.name="6.1.1-debian-11-r48" \
|
||||
org.opencontainers.image.title="wordpress" \
|
||||
org.opencontainers.image.vendor="VMware, Inc." \
|
||||
org.opencontainers.image.version="6.1.1"
|
||||
|
|
@ -23,12 +23,12 @@ RUN install_packages acl ca-certificates curl less libaudit1 libbrotli1 libbsd0
|
|||
RUN mkdir -p /tmp/bitnami/pkg/cache/ && cd /tmp/bitnami/pkg/cache/ && \
|
||||
COMPONENTS=( \
|
||||
"php-8.1.16-0-linux-${OS_ARCH}-debian-11" \
|
||||
"apache-2.4.55-4-linux-${OS_ARCH}-debian-11" \
|
||||
"apache-2.4.55-5-linux-${OS_ARCH}-debian-11" \
|
||||
"mysql-client-10.6.12-0-linux-${OS_ARCH}-debian-11" \
|
||||
"libphp-8.1.16-0-linux-${OS_ARCH}-debian-11" \
|
||||
"libphp-8.1.16-1-linux-${OS_ARCH}-debian-11" \
|
||||
"wordpress-6.1.1-27-linux-${OS_ARCH}-debian-11" \
|
||||
"render-template-1.0.5-0-linux-${OS_ARCH}-debian-11" \
|
||||
"gosu-1.16.0-1-linux-${OS_ARCH}-debian-11" \
|
||||
"gosu-1.16.0-2-linux-${OS_ARCH}-debian-11" \
|
||||
) && \
|
||||
for COMPONENT in "${COMPONENTS[@]}"; do \
|
||||
if [ ! -f "${COMPONENT}.tar.gz" ]; then \
|
||||
|
|
|
|||
|
|
@ -1,24 +1,24 @@
|
|||
{
|
||||
"apache": {
|
||||
"arch": "amd64",
|
||||
"digest": "6937b37eaae1a0053c097ae04509cf3ccc4d260dd5fe010572753c3e8b22470d",
|
||||
"digest": "a1afe61b7489ffb908895a02d0ce3b8771005a61489c35bef21101bb87b00a9d",
|
||||
"distro": "debian-11",
|
||||
"type": "NAMI",
|
||||
"version": "2.4.55-4"
|
||||
"version": "2.4.55-5"
|
||||
},
|
||||
"gosu": {
|
||||
"arch": "amd64",
|
||||
"digest": "9ab9654690d90d3c49ff66fb1eb286487e318adc899d036bc45922f6b176865b",
|
||||
"digest": "f6056076afb745fd7d9d87d20f71e7248d63330352cf5ae0be2130b7f44a8cfa",
|
||||
"distro": "debian-11",
|
||||
"type": "NAMI",
|
||||
"version": "1.16.0-1"
|
||||
"version": "1.16.0-2"
|
||||
},
|
||||
"libphp": {
|
||||
"arch": "amd64",
|
||||
"digest": "8d240182cda57e7a1ee29ced829e84c5b7867615e5d42f7f14eef53b4fb19bed",
|
||||
"digest": "40f8ff7fad078e7349445015793cfe59e47a6590880dd216e0f33739e681cf9d",
|
||||
"distro": "debian-11",
|
||||
"type": "NAMI",
|
||||
"version": "8.1.16-0"
|
||||
"version": "8.1.16-1"
|
||||
},
|
||||
"mysql-client": {
|
||||
"arch": "amd64",
|
||||
|
|
|
|||
|
|
@ -348,34 +348,7 @@ wordpress_initialize() {
|
|||
is_boolean_yes "$WORDPRESS_ENABLE_MULTISITE" && wp_execute site meta update "$default_site_id" fileupload_maxk "$WORDPRESS_MULTISITE_FILEUPLOAD_MAXK"
|
||||
# Enable friendly URLs / permalinks (using historic Bitnami defaults)
|
||||
wp_execute rewrite structure '/%year%/%monthnum%/%day%/%postname%/'
|
||||
if ! is_empty_value "$WORDPRESS_SMTP_HOST"; then
|
||||
info "Configuring SMTP settings"
|
||||
wp_execute option set mail_from "$WORDPRESS_SMTP_USER"
|
||||
wp_execute option set mail_from_name "${WORDPRESS_FIRST_NAME} ${WORDPRESS_LAST_NAME}"
|
||||
wp_execute option set mailer "smtp"
|
||||
wp_execute option set mail_set_return_path ""
|
||||
wp_execute option set smtp_host "$WORDPRESS_SMTP_HOST"
|
||||
wp_execute option set smtp_port "$WORDPRESS_SMTP_PORT_NUMBER"
|
||||
wp_execute option set smtp_ssl "$WORDPRESS_SMTP_PROTOCOL"
|
||||
wp_execute option set smtp_auth "true"
|
||||
wp_execute option set smtp_user "$WORDPRESS_SMTP_USER"
|
||||
wp_execute option set smtp_pass "$WORDPRESS_SMTP_PASSWORD"
|
||||
# Enable wp-mail-smtp plugin, which is required for SMTP to work
|
||||
info "Enabling wp-mail-smtp plugin"
|
||||
local -a install_smtp_plugin_args
|
||||
if is_boolean_yes "$WORDPRESS_ENABLE_MULTISITE"; then
|
||||
install_smtp_plugin_args=("--activate-network")
|
||||
else
|
||||
install_smtp_plugin_args=("--activate")
|
||||
fi
|
||||
wp_execute plugin install wp-mail-smtp "${install_smtp_plugin_args[@]}"
|
||||
# Delete default SMTP credentials created when enabling the plugin
|
||||
# If not deleted, the previously configured credentials will not be taken into account
|
||||
# and the user will be forced to re-launch the plugin wizard right after logging in the admin panel
|
||||
local wp_mail_options_to_delete
|
||||
read -r -a wp_mail_options_to_delete <<<"$(wp_execute_print_output option list --search='*wp_mail*' --field=option_name | tr '\n' ' ')"
|
||||
wp_execute option delete "${wp_mail_options_to_delete[@]}"
|
||||
fi
|
||||
! is_empty_value "$WORDPRESS_SMTP_HOST" && wordpress_configure_smtp
|
||||
else
|
||||
info "An already initialized WordPress database was provided, configuration will be skipped"
|
||||
wp_execute core update-db
|
||||
|
|
@ -668,6 +641,37 @@ EOF
|
|||
wordpress_conf_set "WP_SITEURL" "$wp_url_string" yes
|
||||
}
|
||||
|
||||
########################
|
||||
# Configure SMTP
|
||||
# Globals:
|
||||
# *
|
||||
# Arguments:
|
||||
# None
|
||||
# Returns:
|
||||
# None
|
||||
#########################
|
||||
wordpress_configure_smtp() {
|
||||
info "Enabling wp-mail-smtp plugin"
|
||||
local -a install_smtp_plugin_args
|
||||
if is_boolean_yes "$WORDPRESS_ENABLE_MULTISITE"; then
|
||||
install_smtp_plugin_args=("--activate-network")
|
||||
else
|
||||
install_smtp_plugin_args=("--activate")
|
||||
fi
|
||||
wp_execute plugin install wp-mail-smtp "${install_smtp_plugin_args[@]}"
|
||||
info "Configuring SMTP settings"
|
||||
wp_execute option patch update wp_mail_smtp mail from_email "$WORDPRESS_SMTP_USER"
|
||||
wp_execute option patch update wp_mail_smtp mail from_name "${WORDPRESS_FIRST_NAME} ${WORDPRESS_LAST_NAME}"
|
||||
wp_execute option patch update wp_mail_smtp mail mailer "smtp"
|
||||
wp_execute option patch insert wp_mail_smtp smtp host "$WORDPRESS_SMTP_HOST"
|
||||
wp_execute option patch insert wp_mail_smtp smtp port "$WORDPRESS_SMTP_PORT_NUMBER"
|
||||
wp_execute option patch insert wp_mail_smtp smtp encryption "$WORDPRESS_SMTP_PROTOCOL"
|
||||
wp_execute option patch insert wp_mail_smtp smtp user "$WORDPRESS_SMTP_USER"
|
||||
wp_execute option patch insert wp_mail_smtp smtp pass "$WORDPRESS_SMTP_PASSWORD"
|
||||
# Prevent WP Mail SMTP wizard to be launched after logging in the admin panel
|
||||
wp_execute option set wp_mail_smtp_activation_prevent_redirect 1
|
||||
}
|
||||
|
||||
########################
|
||||
# Apply web server configuration to host WordPress
|
||||
# Globals:
|
||||
|
|
|
|||
|
|
@ -6,6 +6,8 @@
|
|||
|
||||
[Overview of WordPress](http://www.wordpress.org)
|
||||
|
||||
|
||||
|
||||
## TL;DR
|
||||
|
||||
```console
|
||||
|
|
@ -90,7 +92,7 @@ docker network create wordpress-network
|
|||
#### Step 2: Create a volume for MariaDB persistence and create a MariaDB container
|
||||
|
||||
```console
|
||||
docker volume create --name mariadb_data
|
||||
$ docker volume create --name mariadb_data
|
||||
docker run -d --name mariadb \
|
||||
--env ALLOW_EMPTY_PASSWORD=yes \
|
||||
--env MARIADB_USER=bn_wordpress \
|
||||
|
|
@ -104,7 +106,7 @@ docker run -d --name mariadb \
|
|||
#### Step 3: Create volumes for WordPress persistence and launch the container
|
||||
|
||||
```console
|
||||
docker volume create --name wordpress_data
|
||||
$ docker volume create --name wordpress_data
|
||||
docker run -d --name wordpress \
|
||||
-p 8080:8080 -p 8443:8443 \
|
||||
--env ALLOW_EMPTY_PASSWORD=yes \
|
||||
|
|
@ -212,7 +214,7 @@ When you start the WordPress image, you can adjust the configuration of the inst
|
|||
- For manual execution add a `--env` option with each variable and value:
|
||||
|
||||
```console
|
||||
docker run -d --name wordpress -p 80:8080 -p 443:8443 \
|
||||
$ docker run -d --name wordpress -p 80:8080 -p 443:8443 \
|
||||
--env WORDPRESS_PASSWORD=my_password \
|
||||
--network wordpress-tier \
|
||||
--volume /path/to/wordpress-persistence:/bitnami \
|
||||
|
|
@ -245,7 +247,7 @@ Available environment variables:
|
|||
- `WORDPRESS_AUTO_UPDATE_LEVEL`: Level of auto-updates to allow for the WordPress core installation. Valid values: `major`, `minor`, `none`. Default: **none**
|
||||
- `WORDPRESS_ENABLE_REVERSE_PROXY`: Enable WordPress support for reverse proxy headers. Default: **no**
|
||||
|
||||
##### Salt and keys configuration
|
||||
#### Salt and keys configuration
|
||||
|
||||
Authentication unique keys and salts. Specify these values to prevent cookies from being invalidated when creating a new container or when using multiple containers to serve the same WordPress instance. By default these values are generated randomly:
|
||||
|
||||
|
|
@ -258,7 +260,7 @@ Authentication unique keys and salts. Specify these values to prevent cookies fr
|
|||
- `WORDPRESS_LOGGED_IN_SALT`: Set the value of the `LOGGED_IN_SALT` constant in `wp-config.php`
|
||||
- `WORDPRESS_NONCE_SALT`: Set the value of the `NONCE_SALT` constant in `wp-config.php`
|
||||
|
||||
##### Multisite configuration
|
||||
#### Multisite configuration
|
||||
|
||||
- `WORDPRESS_ENABLE_MULTISITE`: Enable WordPress Multisite configuration. Default: **no**
|
||||
- `WORDPRESS_MULTISITE_HOST`: WordPress hostname/address. Only used for Multisite installations. No defaults.
|
||||
|
|
@ -268,7 +270,7 @@ Authentication unique keys and salts. Specify these values to prevent cookies fr
|
|||
- `WORDPRESS_MULTISITE_ENABLE_NIP_IO_REDIRECTION`: Whether to enable IP address redirection to nip.io wildcard DNS when enabling WordPress Multisite. This is useful when running on an IP address with subdomain network type. Default: **no**
|
||||
- `WORDPRESS_MULTISITE_FILEUPLOAD_MAXK`: Maximum upload file size allowed for WordPress Multisite uploads, in kilobytes. Default: **81920**
|
||||
|
||||
##### Database connection configuration
|
||||
#### Database connection configuration
|
||||
|
||||
- `WORDPRESS_DATABASE_HOST`: Hostname for the MariaDB or MySQL server. Default: **mariadb**
|
||||
- `WORDPRESS_DATABASE_PORT_NUMBER`: Port used by the MariaDB or MySQL server. Default: **3306**
|
||||
|
|
@ -282,7 +284,7 @@ Authentication unique keys and salts. Specify these values to prevent cookies fr
|
|||
- `WORDPRESS_DATABASE_SSL_CA_FILE`: Path to the database server CA bundle file. No defaults
|
||||
- `ALLOW_EMPTY_PASSWORD`: It can be used to allow blank passwords. Default: **no**
|
||||
|
||||
##### Create a database for WordPress using mysql-client
|
||||
#### Create a database for WordPress using mysql-client
|
||||
|
||||
- `MYSQL_CLIENT_FLAVOR`: SQL database flavor. Valid values: `mariadb` or `mysql`. Default: **mariadb**
|
||||
- `MYSQL_CLIENT_DATABASE_HOST`: Hostname for the MariaDB or MySQL server. Default: **mariadb**
|
||||
|
|
@ -301,7 +303,7 @@ Authentication unique keys and salts. Specify these values to prevent cookies fr
|
|||
- `MYSQL_CLIENT_SSL_KEY_FILE`: Path to the SSL CA file for the new database. No defaults
|
||||
- `ALLOW_EMPTY_PASSWORD`: It can be used to allow blank passwords. Default: **no**
|
||||
|
||||
##### SMTP Configuration
|
||||
#### SMTP Configuration
|
||||
|
||||
To configure WordPress to send email using SMTP you can set the following environment variables:
|
||||
|
||||
|
|
@ -310,7 +312,7 @@ To configure WordPress to send email using SMTP you can set the following enviro
|
|||
- `WORDPRESS_SMTP_USER`: SMTP account user.
|
||||
- `WORDPRESS_SMTP_PASSWORD`: SMTP account password.
|
||||
|
||||
##### PHP configuration
|
||||
#### PHP configuration
|
||||
|
||||
- `PHP_ENABLE_OPCACHE`: Enable OPcache for PHP scripts. Default: **yes**
|
||||
- `PHP_EXPOSE_PHP`: Enables HTTP header with PHP version. No default.
|
||||
|
|
@ -346,7 +348,7 @@ This would be an example of SMTP configuration using a Gmail account:
|
|||
- For manual execution:
|
||||
|
||||
```console
|
||||
docker run -d --name wordpress -p 80:8080 -p 443:8443 \
|
||||
$ docker run -d --name wordpress -p 80:8080 -p 443:8443 \
|
||||
--env WORDPRESS_DATABASE_USER=bn_wordpress \
|
||||
--env WORDPRESS_DATABASE_NAME=bitnami_wordpress \
|
||||
--env WORDPRESS_SMTP_HOST=smtp.gmail.com \
|
||||
|
|
@ -381,7 +383,7 @@ The Bitnami WordPress container supports connecting the WordPress application to
|
|||
- For manual execution:
|
||||
|
||||
```console
|
||||
docker run -d --name wordpress\
|
||||
$ docker run -d --name wordpress\
|
||||
-p 8080:8080 -p 8443:8443 \
|
||||
--network wordpress-network \
|
||||
--env WORDPRESS_DATABASE_HOST=mariadb_host \
|
||||
|
|
@ -465,7 +467,7 @@ Restoring a backup is as simple as mounting the backup as volumes in the contain
|
|||
For the MariaDB database container:
|
||||
|
||||
```diff
|
||||
docker run -d --name mariadb \
|
||||
$ docker run -d --name mariadb \
|
||||
...
|
||||
- --volume /path/to/mariadb-persistence:/bitnami/mariadb \
|
||||
+ --volume /path/to/mariadb-backups/latest:/bitnami/mariadb \
|
||||
|
|
@ -475,7 +477,7 @@ For the MariaDB database container:
|
|||
For the WordPress container:
|
||||
|
||||
```diff
|
||||
docker run -d --name wordpress \
|
||||
$ docker run -d --name wordpress \
|
||||
...
|
||||
- --volume /path/to/wordpress-persistence:/bitnami/wordpress \
|
||||
+ --volume /path/to/wordpress-backups/latest:/bitnami/wordpress \
|
||||
|
|
|
|||
Loading…
Reference in New Issue