(simatec) v0.9.3
This commit is contained in:
parent
aaa64bf783
commit
f6832ee9fc
5 changed files with 44 additions and 19 deletions
|
@ -154,6 +154,10 @@ To leave the container on the console you have to execute 2x `exit`.
|
||||||
|
|
||||||
## Changelog
|
## Changelog
|
||||||
|
|
||||||
|
### 0.9.3 (01.06.2024)
|
||||||
|
* (simatec) Piler v1.4.5 updated
|
||||||
|
* (simatec) MariaDB v11.1.2 updated
|
||||||
|
|
||||||
### 0.9.2 (19.09.2023)
|
### 0.9.2 (19.09.2023)
|
||||||
* (simatec) Piler v1.4.4 updated
|
* (simatec) Piler v1.4.4 updated
|
||||||
|
|
||||||
|
@ -220,7 +224,7 @@ To leave the container on the console you have to execute 2x `exit`.
|
||||||
## License
|
## License
|
||||||
MIT License
|
MIT License
|
||||||
|
|
||||||
Copyright (c) 2022 - 2023 simatec
|
Copyright (c) 2022 - 2024 simatec
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
|
|
@ -1,35 +1,38 @@
|
||||||
FROM ubuntu:22.04
|
FROM ubuntu:24.04
|
||||||
|
|
||||||
ARG PACKAGE
|
ARG PACKAGE
|
||||||
|
ARG TARGETARCH
|
||||||
|
|
||||||
LABEL description="piler ubuntu jammy image" \
|
LABEL description="piler ubuntu noble image" \
|
||||||
maintainer="Janos SUTO, sj@acts.hu" \
|
maintainer="Janos SUTO, sj@acts.hu" \
|
||||||
package="${PACKAGE}"
|
package="${PACKAGE}"
|
||||||
|
|
||||||
ENV DEBIAN_FRONTEND="noninteractive" \
|
ENV DEBIAN_FRONTEND="noninteractive" \
|
||||||
DISTRO="jammy" \
|
DISTRO="noble" \
|
||||||
PILER_USER="piler" \
|
PILER_USER="piler" \
|
||||||
MYSQL_DATABASE="piler"
|
MYSQL_DATABASE="piler"
|
||||||
|
|
||||||
COPY ${PACKAGE} /
|
COPY ${PACKAGE}_${TARGETARCH}.deb /
|
||||||
|
|
||||||
|
# hadolint ignore=DL3008
|
||||||
RUN apt-get update && \
|
RUN apt-get update && \
|
||||||
apt-get -y --no-install-recommends install \
|
apt-get -y --no-install-recommends install \
|
||||||
wget openssl sysstat php8.1-cli php8.1-cgi php8.1-mysql php8.1-fpm php8.1-zip php8.1-ldap \
|
wget openssl sysstat php8.3-cli php8.3-cgi php8.3-mysql php8.3-fpm php8.3-zip php8.3-ldap \
|
||||||
php8.1-gd php8.1-curl php8.1-xml php8.1-memcached catdoc unrtf poppler-utils nginx tnef sudo libzip4 \
|
php8.3-gd php8.3-curl php8.3-xml php8.3-memcached catdoc unrtf poppler-utils nginx tnef sudo libzip4t64 \
|
||||||
libtre5 cron libmariadb-dev mariadb-client-core-10.6 python3 python3-mysqldb ca-certificates curl && \
|
libtre5 cron libmariadb-dev mariadb-client-core python3 python3-mysqldb ca-certificates curl rsyslog gnupg && \
|
||||||
wget https://repo.manticoresearch.com/manticore-repo.noarch.deb && \
|
wget https://repo.manticoresearch.com/manticore-repo.noarch.deb && \
|
||||||
dpkg -i manticore-repo.noarch.deb && \
|
dpkg -i manticore-repo.noarch.deb && \
|
||||||
rm -f manticore-repo.noarch.deb && \
|
rm -f manticore-repo.noarch.deb && \
|
||||||
apt-get update && \
|
apt-get update && \
|
||||||
apt-get install -y manticore manticore-columnar-lib && \
|
apt-get install -y --no-install-recommends manticore manticore-columnar-lib && \
|
||||||
apt-get clean && \
|
apt-get clean && \
|
||||||
rm -rf /var/lib/apt/lists/* && \
|
rm -rf /var/lib/apt/lists/* && \
|
||||||
sed -i '/session required pam_loginuid.so/c\#session required pam_loginuid.so' /etc/pam.d/cron && \
|
sed -i '/session required pam_loginuid.so/c\#session required pam_loginuid.so' /etc/pam.d/cron && \
|
||||||
dpkg -i ${PACKAGE} && \
|
dpkg -i ${PACKAGE}_${TARGETARCH}.deb && \
|
||||||
touch /etc/piler/MANTICORE && \
|
touch /etc/piler/MANTICORE && \
|
||||||
ln -sf /etc/piler/piler-nginx.conf /etc/nginx/sites-enabled && \
|
ln -sf /etc/piler/piler-nginx.conf /etc/nginx/sites-enabled && \
|
||||||
rm -f ${PACKAGE} /etc/nginx/sites-enabled/default /etc/piler/piler.key /etc/piler/piler.pem /etc/piler/config-site.php && \
|
echo "www-data ALL=NOPASSWD: /etc/init.d/rc.piler reload" > /etc/sudoers.d/piler && \
|
||||||
|
rm -f ${PACKAGE}_${TARGETARCH}.deb /etc/nginx/sites-enabled/default /etc/piler/piler.key /etc/piler/piler.pem /etc/piler/config-site.php && \
|
||||||
crontab -u $PILER_USER /usr/share/piler/piler.cron
|
crontab -u $PILER_USER /usr/share/piler/piler.cron
|
||||||
|
|
||||||
VOLUME ["/etc/piler","/var/piler/store","/var/piler/manticore","/var/piler/imap","/var/piler/stat","/var/spool/cron/crontabs"]
|
VOLUME ["/etc/piler","/var/piler/store","/var/piler/manticore","/var/piler/imap","/var/piler/stat","/var/spool/cron/crontabs"]
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
# Piler Package
|
# Piler Package
|
||||||
|
|
||||||
PILER_PACKAGE="piler_1.4.4-jammy-553ebb4f_amd64.deb"
|
PILER_PACKAGE="piler_1.4.5-jammy-c13432f_amd64.deb"
|
||||||
|
|
||||||
# Piler Version
|
# Piler Version
|
||||||
|
|
||||||
PILER_VERSION="1.4.4"
|
PILER_VERSION="1.4.5"
|
||||||
|
|
||||||
# MariaDB Version
|
# MariaDB Version
|
||||||
|
|
||||||
MARIA_DB_VERSION="10.6"
|
MARIA_DB_VERSION="11.1.2"
|
|
@ -13,6 +13,8 @@ PILER_NGINX_CONF="${CONFIG_DIR}/piler-nginx.conf"
|
||||||
SPHINX_CONF="${CONFIG_DIR}/manticore.conf"
|
SPHINX_CONF="${CONFIG_DIR}/manticore.conf"
|
||||||
CONFIG_SITE_PHP="${CONFIG_DIR}/config-site.php"
|
CONFIG_SITE_PHP="${CONFIG_DIR}/config-site.php"
|
||||||
PILER_MY_CNF="${CONFIG_DIR}/.my.cnf"
|
PILER_MY_CNF="${CONFIG_DIR}/.my.cnf"
|
||||||
|
RT="${RT:-0}"
|
||||||
|
MEMCACHED_HOSTNAME="${MEMCACHED_HOSTNAME:-memcached}"
|
||||||
|
|
||||||
|
|
||||||
error() {
|
error() {
|
||||||
|
@ -117,7 +119,7 @@ fix_configs() {
|
||||||
echo "\$config['DB_USERNAME'] = '$MYSQL_USER';"
|
echo "\$config['DB_USERNAME'] = '$MYSQL_USER';"
|
||||||
echo "\$config['DB_PASSWORD'] = '$MYSQL_PASSWORD';"
|
echo "\$config['DB_PASSWORD'] = '$MYSQL_PASSWORD';"
|
||||||
echo "\$config['ENABLE_MEMCACHED'] = 1;"
|
echo "\$config['ENABLE_MEMCACHED'] = 1;"
|
||||||
echo "\$memcached_server = ['memcached', 11211];"
|
echo "\$memcached_server = ['$MEMCACHED_HOSTNAME', 11211];"
|
||||||
} >> "$CONFIG_SITE_PHP"
|
} >> "$CONFIG_SITE_PHP"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -126,6 +128,21 @@ fix_configs() {
|
||||||
-e "s%MYSQL_USERNAME%${MYSQL_USER}%" \
|
-e "s%MYSQL_USERNAME%${MYSQL_USER}%" \
|
||||||
-e "s%MYSQL_PASSWORD%${MYSQL_PASSWORD}%" \
|
-e "s%MYSQL_PASSWORD%${MYSQL_PASSWORD}%" \
|
||||||
-i "$SPHINX_CONF"
|
-i "$SPHINX_CONF"
|
||||||
|
|
||||||
|
# Fixes for RT index
|
||||||
|
|
||||||
|
if [[ $RT -eq 1 ]]; then
|
||||||
|
sed -i "s/define('RT', 0)/define('RT', 1)/" "$SPHINX_CONF"
|
||||||
|
if ! grep "'RT'" "$CONFIG_SITE_PHP"; then
|
||||||
|
echo "\$config['RT'] = 1;" >> "$CONFIG_SITE_PHP"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if ! grep "'SPHINX_MAIN_INDEX'" "$CONFIG_SITE_PHP"; then
|
||||||
|
echo "\$config['SPHINX_MAIN_INDEX'] = 'piler1';" >> "$CONFIG_SITE_PHP"
|
||||||
|
fi
|
||||||
|
|
||||||
|
sed -i "s%rtindex=.*%rtindex=1%" "$PILER_CONF"
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -171,13 +188,14 @@ create_my_cnf_files() {
|
||||||
|
|
||||||
start_services() {
|
start_services() {
|
||||||
service cron start
|
service cron start
|
||||||
service php8.1-fpm start
|
service php8.3-fpm start
|
||||||
service nginx start
|
service nginx start
|
||||||
|
rsyslogd
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
start_piler() {
|
start_piler() {
|
||||||
if [[ ! -f "${VOLUME_DIR}/manticore/main1.spp" ]]; then
|
if [[ $RT -eq 0 && ! -f "${VOLUME_DIR}/manticore/main1.spp" ]]; then
|
||||||
log "main1.spp does not exist, creating index files"
|
log "main1.spp does not exist, creating index files"
|
||||||
su -c "indexer --all --config ${SPHINX_CONF}" "$PILER_USER"
|
su -c "indexer --all --config ${SPHINX_CONF}" "$PILER_USER"
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -67,8 +67,8 @@ MAILCOW_HOST="mail.example.com"
|
||||||
|
|
||||||
# Piler Version
|
# Piler Version
|
||||||
|
|
||||||
PILER_VERSION="1.4.4"
|
PILER_VERSION="1.4.5"
|
||||||
|
|
||||||
# MariaDB Version
|
# MariaDB Version
|
||||||
|
|
||||||
MARIA_DB_VERSION="10.6"
|
MARIA_DB_VERSION="11.1.2"
|
||||||
|
|
Loading…
Reference in a new issue