美文网首页
application.yml文件配置

application.yml文件配置

作者: S拒绝拖延 | 来源:发表于2019-06-28 09:10 被阅读0次
server:
    port: 8080
    tomcat:
      uri-encoding: UTF-8
spring:
    http:
      encoding:
        charset: UTF-8
        enabled: true
        force: true
    freemarker:
        template-loader-path:
        - /templates/
        - file:./templates/
        cache: false
        settings:
            classic_compatible: true #处理空值
            template_update_delay: 0
            datetime_format: yyyy-MM-dd HH:mm
            number_format: 0.##

    datasource:
        url: jdbc:mysql://localhost:3306/mblog?useSSL=false&characterEncoding=utf8
        username: test
        password: 123456
    jpa:
        database: mysql
        show-sql: false
        hibernate:
            ddl-auto: update
        properties:
            hibernate.format_sql: true
            hibernate.naming.physical-strategy: org.hibernate.boot.model.naming.PhysicalNamingStrategyStandardImpl
            hibernate.cache.use_second_level_cache: false
            hibernate.search.default.directory_provider: filesystem
            hibernate.search.default.indexBase: ./indexes
        open-in-view: true

    servlet:
        multipart:
            max-file-size: 5MB

    mail:
        host: smtp.exmail.qq.com
        username: example@mtons.com
        password: {your password}
        port: 25
        properties:
            mail.smtp.auth: true
            mail.smtp.ssl.enable: true
            mail.smtp.starttls.enable: true
            mail.smtp.starttls.required: true

site.store.root: /data/mblog
# 存储模式, 可选值 absolute / relative
site.store.repo: relative

# 是否开启资源域名
site.store.domain: false
# ---------------------------------
# 资源域名, resource.domain = true 是有效
# 配置域名, 将域名的根目录指向 store.root 配置的地址
# ---------------------------------
site.store.host: http://localhost:8080/mblog

相关文章

网友评论

      本文标题:application.yml文件配置

      本文链接:https://www.haomeiwen.com/subject/ciijcctx.html