Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
86 changes: 85 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ project located [here](https://github.com/netbootxyz/docker-netbootxyz).
Uses the docker-netbootxyz repo for source files to avoid duplication of configs:

```bash
git clone https://github.com/netbootxyz/webapp
git clone https://github.com/Adambis1/webapp
cd webapp
git clone https://github.com/netbootxyz/docker-netbootxyz
docker build . -t netbootxyz-webapp
Expand Down Expand Up @@ -53,3 +53,87 @@ docker run -d \
--restart unless-stopped \
ghcr.io/netbootxyz/webapp-dev:latest
```


## Why this fork was created ?
I wanted to be able to hide the directory and its contents from the webapp so modified as i see fit.
It's not the greatest thing there but it works and it's all i need

Making it possible to hide directories from netbootxyz webapp with creating a file named 'disable-tracking-netbootxyz' in the folder, making it invisible in gui
In my case i have WinPE and extracted isos in WinPE folder
```
assets
├───asset-mirror
│ └───releases
│ └───download
├───debian-core-10
│ └───releases
│ └───download
├───debian-core-11
│ └───releases
│ └───download
├───debian-core-12
│ └───releases
│ └───download
├───debian-squash
│ └───releases
│ └───download
├───fedora-assets
│ └───releases
│ └───download
├───manjaro-squash
│ └───releases
│ └───download
├───ssh
├───ubuntu-squash
│ └───releases
│ └───download
└───WinPE <- want to hide this folder and its contents
├───disable-tracking-netbootxyz (create file)
├───configs
│ ├───Windows_10
│ └───Windows_11
├───iso
│ ├───Windows_10
│ │ │
│ │ [...]
│ └───Windows_11
│ │ │
│ │ [...]
├───x64
│ │
│ [...]
└───x86
[...]
```
Resulting with following folders visible to webapp
```
assets
├───asset-mirror
│ └───releases
│ └───download
├───debian-core-10
│ └───releases
│ └───download
├───debian-core-11
│ └───releases
│ └───download
├───debian-core-12
│ └───releases
│ └───download
├───debian-squash
│ └───releases
│ └───download
├───fedora-assets
│ └───releases
│ └───download
├───manjaro-squash
│ └───releases
│ └───download
├───ssh
└────ubuntu-squash
└───releases
└───download
```

4 changes: 3 additions & 1 deletion public/netbootxyz-web.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -401,6 +401,7 @@ socket.on('renderlocal', function(endpoints,localfiles,remotemenuversion){
var remotetable = $('#remoteassets').DataTable(tableoptions);
localtable.clear();
remotetable.clear();
disabled_folders = [];
$.each(endpoints.endpoints, function(index,value){
$.each(value.files, function( arrindex, file ) {
if (localfiles.includes(value.path + file)){
Expand All @@ -427,8 +428,9 @@ socket.on('renderlocal', function(endpoints,localfiles,remotemenuversion){
});
if (localfiles.length != 0){
var untrackedtable = $('#untrackedassets').DataTable(tableoptions);
(localfiles.filter(str => str.includes("disable-tracking-netbootxyz"))).forEach(element => {disabled_folders.push((element.substring(0,element.lastIndexOf("/")+1)))});
$.each(localfiles, function( arrindex, file ) {
if (!file.endsWith('.part2')) {
if (!file.endsWith('.part2') && disabled_folders.filter(str => str.includes(file.substring(0,str.length))).length==0 ) {
untrackedtable.row.add(
[
'/assets' + file,
Expand Down