How does spring boot resources static-locations exclude a directory?

Viewed 10

I am using spring boot resources static-locations to specify a directory as a web access directory

  resources:
    static-locations: file:./opt
  1. As the above configuration, all files in the opt directory can be accessed through the web, but if I want to exclude a subdirectory of opt so that it cannot be accessed through the web, how should I configure it?

  2. Does the configuration allow wildcard access?

resources:
    static-locations: file:./opt/**/down

I tested the wildcards above, but it doesn't work, but I do have this requirement, is there any way? Thanks in advance

0 Answers
Related