Files
lsky-pro-docker/000-default.conf.template
mole404 f3aa1c191c chore(image): 供应链加固 + Laravel 9.52.22 + 健康检查
F15:两个阶段的基镜像都钉 OCI digest(附取 digest 的方法)。F16:构建期两个下载源改为先落盘再校验(composer installer 用官方 installer.sig 的 sha384;install-php-extensions 钉 2.12.0 + 写死 sha256),验不过即构建失败。F19:laravel/framework 9.52.21→9.52.22(另 7 个 symfony 6.4.x 补丁级,共 8 个包,content-hash 未变)。F10:加 HEALTHCHECK。F12:.dockerignore 排除 node_modules/vendor/开发机 .env/编译产物(vendor 只排 src/vendor —— 用 **/vendor 会误伤 fontawesome 的字体文件,前端图标会全空)。
2026-09-30 06:18:56 +08:00

45 lines
1.9 KiB
ApacheConf

<VirtualHost *:${WEB_PORT}>
# The ServerName directive sets the request scheme, hostname and port that
# the server uses to identify itself. This is used when creating
# redirection URLs. In the context of virtual hosts, the ServerName
# specifies what hostname must appear in the request's Host: header to
# match this virtual host. For the default virtual host (this file) this
# value is not decisive as it is used as a last resort host regardless.
# However, you must set it for any further virtual host explicitly.
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html/public
# Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
# error, crit, alert, emerg.
# It is also possible to configure the loglevel for particular
# modules, e.g.
#LogLevel info ssl:warn
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
# For most configuration files from conf-available/, which are
# enabled or disabled at a global level, it is possible to
# include a line for only one particular virtual host. For example the
# following line enables the CGI configuration for this host only
# after it has been globally disabled with "a2disconf".
#Include conf-available/serve-cgi-bin.conf
</VirtualHost>
<VirtualHost *:${HTTPS_PORT}>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html/public
SSLEngine on
# F21:这两个文件**不在镜像里**,由 entrypoint.sh 首次启动时用 openssl 自签生成
# (幂等:已存在就跳过)。路径写死,因为模板只被 envsubst 渲染 ${WEB_PORT} / ${HTTPS_PORT}。
SSLCertificateFile "/etc/apache2/ssl/lsky-selfsigned.crt"
SSLCertificateKeyFile "/etc/apache2/ssl/lsky-selfsigned.key"
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
# vim: syntax=apache ts=4 sw=4 sts=4 sr noet