自学内容网 自学内容网

SPRINGBOOT_HTTPS+UNIAPP完成小程序开发毕设模版

一、因为小程序发布到线上要求请求后端地址必须是HTTPS,所有后端SPRINGBOOT项目必须首先解决HTTPS的问题。

# server ip and port
host=localhost
swaggerIp=https://${host}:443
blackIp=https://${host}:443
server.port=443
server.ssl.key-store=classpath:www.wdfgdzx.top.pfx
server.ssl.key-store-password=q90n2e3d
server.ssl.keyStoreType=PKCS12
# mysql driver
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
# mysql host and user password
spring.datasource.url=jdbc:mysql://wdfgdzx.top:3306/black_zoom?serverTimezone=GMT%2b8&allowMultiQueries=true&useAffectedRows=true
spring.datasource.username=root
spring.datasource.password=xxx
#-------------------------------------------------------------------------------------------------------------------------------------------
# mysql settings
spring.datasource.hikari.connection-timeout=10000
spring.datasource.hikari.validation-timeout=3000
spring.datasource.hikari.idle-timeout=60000
spring.datasource.hikari.login-timeout=5
spring.datasource.hikari.max-lifetime=60000
spring.datasource.hikari.maximum-pool-size=10
spring.datasource.hikari.minimum-idle=5
spring.datasource.hikari.read-only=false
# find mapper path and position
mybatis.mapper-locations=classpath:mapper/*.xml
# mybatisPlus
mybatis-plus.configuration.log-impl=org.apache.ibatis.logging.stdout.StdOutImpl
# find legal path
spring.mvc.pathmatch.matching-strategy=ant_path_matcher
# upload file limit
spring.servlet.multipart.max-file-size=100MB
spring.servlet.multipart.max-request-size=100MB

配置如上,阿里云的证书放到resources目录下,就可以顺利在本地443端口启动HTTPS服务了。

二、UNIAPP开发与配置

这样就完成了小程序基本架构的开发与配置

三、除了UNIAPP的小程序我们还有统一的用户管理PC端系统


原文地址:https://blog.csdn.net/p6448777/article/details/142336672

免责声明:本站文章内容转载自网络资源,如本站内容侵犯了原著者的合法权益,可联系本站删除。更多内容请关注自学内容网(zxcms.com)!