| README.adoc | ●●●●● patch | view | raw | blame | history | |
| borgbutler-server/src/main/kotlin/de/micromata/borgbutler/server/rest/ArchivesRest.kt | ●●●●● patch | view | raw | blame | history |
README.adoc
@@ -162,4 +162,4 @@ === Browsing produces security warnings Due to security reasons, BorgButler is only available by the localhost's web browser. For docker installations the clients of the private net `172.17.0.*` are allowed. For enabling other client ip's, you may use option `-DallowedClientIps=192.168.78.` (docker: `docker run -e JAVA_OPTS="-DallowedeClientIps=192.168.78." -v ...` if your really now what you're doing!!! There is now https available at default!!! For enabling other client ip's, you may use option `-DallowedClientIps=192.168.78.` (docker: `docker run -e JAVA_OPTS="-DallowedClientIps=192.168.78.;192.168.79.5" -v ...` if your really now what you're doing!!! There is now https available at default!!! borgbutler-server/src/main/kotlin/de/micromata/borgbutler/server/rest/ArchivesRest.kt
@@ -9,6 +9,7 @@ import de.micromata.borgbutler.data.FileSystemFilter import de.micromata.borgbutler.json.JsonUtils import de.micromata.borgbutler.json.borg.BorgFilesystemItem import de.micromata.borgbutler.server.RunningMode import de.micromata.borgbutler.utils.DirUtils import mu.KotlinLogging import org.apache.commons.collections4.CollectionUtils @@ -149,7 +150,7 @@ return RestUtils.notFound() } if (openDownloads == true) openFileBrowser(File(restoreDir, item.getPath())) return ResponseEntity.ok("OK") return ResponseEntity.accepted().body("OK") } catch (ex: IOException) { log.error("No file extracted: " + ex.message, ex) return RestUtils.notFound() @@ -157,7 +158,7 @@ } private fun openFileBrowser(fileDirectory: File) { if (Desktop.isDesktopSupported() && Desktop.getDesktop().isSupported(Desktop.Action.BROWSE_FILE_DIR)) { if (RunningMode.desktopSupportsBrowse) { var file: File? = fileDirectory if (!fileDirectory.exists() || Files.isSymbolicLink(fileDirectory.toPath())) { // Open parent.