-
Notifications
You must be signed in to change notification settings - Fork 10
Tutorials
1.Please add Caddy and NSSM to your enviroment variables shown here
- Open an administrative powershell
- Type commmand below to register a service
nssm install Caddy
- Now it will show NSSM GUI
- Configure like below
Path= Your Caddy.exe (IE C:\Tools\Caddy\caddy.exe
)
Startup Directory= Your Root Caddy folder (IE C:/Tools/Caddy
)
Arguments= this will be the command your run to start caddy in the background
(IE run --config Caddyfile
)
When done it should look like this
-
Now Select Install Service
-
Start the service in the administrative powershell by running
nssm start caddy
(so if you name it something else in the nssm install myappname it will be nssm install sonarr to setup in nssm gui and nssm start sonarr to auto start the service)
- You can check to see if its running succesful by typing
nssm status Caddy
- To restart it
nssm restart Caddy
- To stop the service
nssm stop Caddy
NOTE YOU WILL NEED A LOCAL WINDOWS USER THIS WILL NOT WORK WITH A EMAIL LOGIN TO WINDOWS HERES A TUTORIAL IF YOU WANT
How to Change Windows Email to Local User
- Go to this PC and right click the drive you want and select Properties
- Go to the sharing tab and click share
- Then click on advanced sharing
- Name the Share whatever you would like it to be
-
Click on permission and add a couple of users to this share
-
Add Network Service, Local Service, Guests
- To do this click Add and select the advanced on the bottom
- Click Find Now
- Select the 3 accounts from step 6 and add them to your permissions
- Then Click Ok
- Then Click Allow all on the 3 added account permissions
- Test to see if it works grab another windows PC or on your phone through a Samba client and type your internal ip of your samba share pc
my internal ip of my pc is 192.168.1.111
so i type into my folder search bar \\192.168.1.111
if you see your share your all set.
- Login in as Adminstrator
- Click on Apps
- Enable External Storage and SMB Connection Test
- Go into your docker-desktop and click on your nextcloud container and select the three dots where your nextcloud instance is shown and select terminal
- Run the Following commands in terminal
apt update
apt upgrade
apt install nano
apt install smbclient
apt install smbclient libsmbclient-dev
-
Click on Administrative Settings
-
Under Adminstration select smb test
-
Type like below
Hostname: 192.168.1.111 (THIS WILL BE YOUR INTERNAL PC's IP) User: DemonWarrior (THIS WILL BE YOUR WINDOWS LOCAL USER) Workgroup: Workgroup Password: @@@@@@@ (THIS WILL BE YOUR WINDOWS LOCAL USER PASSWORD) Share: Jellyfin-Media (THIS WILL BE WHAT YOU NAMED YOUR SAMBA SHARE IN STEP 4 OF CREATING YOUR SAMBA SHARE)
- Once you have succesfully loaded your Samba Test go to Adminstration ---> External Storage
Copy the settings from your Samba test to your external storage it should read.
MAKE SURE YOU DOWNLOAD THE RC (RELIABLE CHANNEL) MSI RUN THE GUI MSI Installer MariaDB
- Create a Directory in your C:\ for Tools IE. C:\Tools
- Create two subdirectories in Tools 2.1 NSSM 2.2 php
- Extract php-7.xx insides to another directory
- Extract NSSM.exe from \nssm-2.24\win64 to
C:\Tools\NSSM
ie. C:\Tools\php
Add it to the enviroment variable paths
- Search Advanced System Settings
- Select Enviroment Variables
- Select System Variables Path by double clicking
- Add a New Path and type
C:\Tools\php
- Add another new path this time for NSSM
C:\Tools\NSSM
- Select OK
- Select OK again
- Then Select OK to cloe the systemp properties box
- Close all Powershells and Terminal Windows So these settings Save
Uncomment These Settings IE. Removing # from before each line You can Search in Your Text Editor by Clicking CTRL+ F
*PHP.ini Settings*
Navigate to the “increase memory_limit” line in the file and change the value from 128M to 512MB.
The next step is to uncomment the following lines by removing ‘;’ before the lines. For example the “;extionsion_dir=ext” should become “extionsion_dir = ext”.
Similarly uncomment the following lines by removing ‘;’ from the beginning of the line.
extension=bz2
extension=curl
extension=ffi
extension=fileinfo
extension=gd2
extension=gettext
extension=gmp
extension=intl
extension=mbstring
extension=exif
extension=mysqli
extension=odbc
extension=openssl
extension=pdo_mysql
extension=pdo_odbc
extension=pdo_sqlite
-
Open up an Administrative Powershell.
-
type inside that powershell
NSSM install PHP
-
Add to Path
3.1
C:\Tools\php\php-cgi.exe
Add to Startup Dirctory
3.2
C:\Tools\php
Add to Argument
3.3
-b 127.0.0.1:9000
-
Click Save
-
Start the Service
nssm Start php
RUN THE GUI MSI Installer
1.TUTORIAL (FOLLOW STEPS 1-4)
- TYPE MARIADB INSIDE YOUR SEARCH BAR
- TYPE THE PASSWORD YOU CREATED in your installation 4.THEN Edit To Your liking
CREATE DATABASE wordpress;
use wordpress;
CREATE USER 'user'@'localhost' IDENTIFIED BY 'pass12345678?';
GRANT ALL ON *.* TO 'user'@'localhost';
flush privileges;
- If you cant remember your password for your MYSQL User Use this command*
DROP USER 'devilsdesigns'@'localhost';
Then re-enter this below
use wordpress;
CREATE USER 'user'@'localhost' IDENTIFIED BY 'pass12345678?';
GRANT ALL ON *.* TO 'user'@'localhost';
flush privileges;
Caddyfile Download
Running Caddy inside the Caddy.exe Directory
-
cd C:\Caddy\Directory
ie. cd C:\Tools\Caddy -
Running Caddy Manually
-
./caddy run --config Caddy
-
Accept both permissions if a windows Pops up
Downloads
-
Download Cloudflare DDNS from github and extract it to a directory of your choice ie.
C:\Tools\CloudflareDDNS
-
Open https://dash.cloudflare.com/ and select your domain
-
Click DNS on the side bar
- Click add a Record
- Go to https://ipchicken.com/ and copy your external ip into the A NAME ie.
- Click Save
- Go to Overview in the right Hand Menu
- Scroll Down till you see get API Token and click it
- Click Create a Token
- Scroll down and select Custom Token
- Name the Token, Give it Zone, Zone, Read and then click add more and add Zone, DNS, Edit Like so
-
Then Click Create Token
-
Create Copy your token somewhere safe
-
type in powershell
cd C:\Tools\CloudflareDDNS
-
Run this command after you edit the code to match yours
./cloudflare-ddns --token your-cloudflare-api-key --domain home.yourdomain.com
ie. ./cloudflare-ddns --token apkGKJHDkansjhcbsdjhc --domain home.demonwarriortech.com
- it should get a log like this
time="2023-01-28T17:54:39-06:00" level=info msg="updated record" content=123.123.123.123 name=home.ittechnut.com
PS C:\tools\cloudflareddns>
- Search Run in Windows
-
Type
shell:startup
and enter it will open a folder with your startup apps. These are all the apps that start when windows Starts -
Right Click anywhere in empty space in your folder and click new ---> Text Documents and name it CloudFlareDDNS.bat (Make sure You do Not save it as a .txt)
- Now open the text document and paste
C:\Tools\CloudFlareDDNS\cloudflare-ddns --token your-cloudflare-api-token--domain home.yourdomain.com
pause
ie.
C:\Tools\CloudFlareDDNS\cloudflare-ddns --token apkGKJHDkansjhcbsdjhc --domain home.demonwarriortech.com
pause
-
Click Save or CTRL+S
-
Run it and it should now be autorunning your background
-
If your having issues writing a cert try clearing your caddy certificates
-
Go to
C:\Users\YOUR-USERNAME\AppData\Roaming\Caddy
remove all files inside the Caddy directory and retry
IF ITS NOT LOADING
- Go to Control Panel
- Search Firewall and Select Windows Defender Firewall
- Select Advanced Settings
- Click Inbouns Rules
- Click New Rule
- Check Port
- Add TCP Ports 9000 (IF YOU HAVENT ADDED CADDY PORT YET DO SO AS WELL FOR 443, 80, 2019)
- Leave Default Click Next
- Leave Default Click Next
- Name the rule whatever you want
- Go to https://portchecker.co/ and see if your port 443 and 80 are open.
- If they are not you need to make sure your router connected to your modem has those ports portforwarded for your computer hosting caddy.
Check out Our Discord if you need more help! https://discord.gg/DtHUvGrp
Requirements
- Check to See if Virtualization is enabled in your bios
- Open Task Manager and See if Virtualization is running
-
If it is on continue to step 3. If it is not you need to enable it in bios.
2.1 Heres a good Tutorial for all Motherboard Manufacturers.
- Turn Windows Features On
-
Turn on
4.1 Hyper-V 4.2 Virtual Machine Platform 4.3 Windows Hypervisor Platform 4.4 Windows Subsystem Linux
- Reboot Your PC
- Once Rebooted You can install your VM.
- Go to MS Store and Search Ubuntu and select an install you want I WOULD RECOMMEND THE LATEST UBUNTU CURRENTLY ITS 22.04
-
Once installed open the Ubuntu 22.04 from the MS Store
-
Setting it up make a name (IT HAS TO BE ALL LOWER CASE)
- Set a Password
- Now Check What WSL Version in powershell your using
wsl --list --verbose
YOU NEED TO BE WSL2
- Install WSL2 Update by running the Installer
- Now Set the Default Kernel to WSL2 in powershell
wsl --set-default-version 2
- Once that is done if it still has not updated to 2 run this command
wsl --update
- If your on Windows 10 and cannot enable or install WSL2 Use this installer
- If running the
wsl --set-default-version 2
then try to apply it directly to your linux. So if my install running thewsl --list --verbose
it says the name add that in the code ie. Ubunut-22.04
wsl --set-version Ubuntu-22.04 2
- Download Docker-Desktop
- Click through the Installer
- Once installed Run the Docker-Desktop (NOT IT MAY TAKE SOME TIME TO FIRST START DEPENDING ON YOUR HARDWARE)
- Navigate to
C:\Users\DESKTOP-USERNAME
- Edit .wslconfig in any text editor
add these line to it. This will limit it to 4GB you can set any number from 2GB-64GB
[wsl2]
memory=4GB
- Restart Docker and it should update to the correct limit.
- If docker-desktop doesnt start after 10 Minutes ie. Showing the green background with the whale. Do these steps to fix it.
- You need to Fully remove Docker-Desktop RESTART COMPUTER
- Then re-install Docker Desktop
If you are having issues with when you reboot and it not saving your containers or completely corrupting All you need to do is
- You need to Fully remove Docker-Desktop RESTART COMPUTER
- Then re-install Docker Desktop
This should fix the issue.
- Make a directory inside C:\Tools called Nextcloud
- You need to make 3 files inside your Nextcloud Directory. You can get the code that needs to go in these files from here. https://github.com/DevilsDesigns/Youtube-Docs/wiki/Docker-Compose-Examples#nextcloud
- docker-compose.yml
- supervisord.conf
- nextcloud.ini
- Dockerfile it will look like this when done
- We need to run our initial setup of nextcloud to do this we need to edit our docker-compose as seen in the video on youtube
- Once we have edited this we have to wait for initial configurations and once it says loaded we can connect to localhost:9111
- Set your Administrative Username for the Admin Account. Set your password for the admin account.
- set your data directory to wherever you want your images/videos to be placed.
- Set your mysql and database user and database password.
- Set your DB from localhost to db:3306
- Once all the categories are filled out click install. (NOTE): Installation may take upwards of 15-20 minutes.
- Once installed we need to go to Apps and install Memories
- Now that Memories is installed we need to activate the go-vod in the compose for our nvidia GPU
- It Should look like below once we uncomment the go-vod section
version: '2'
services:
db:
image: mariadb:10.6
restart: always
command: --transaction-isolation=READ-COMMITTED --log-bin=binlog --binlog-format=ROW
volumes:
- C:\Tools\Nextcloud\db:/var/lib/mysql
environment:
- MYSQL_ROOT_PASSWORD=SQLROOTPASSWORD
- MYSQL_PASSWORD=MYSQLPASSOWRD
- MYSQL_DATABASE=nextcloud
- MYSQL_USER=nextcloud
app:
image: nextcloud:latest
restart: always
ports:
- 9111:80
links:
- db
volumes:
- J:/Nextcloud:/data
- J:/Nextcloud:/var/www/html
environment:
- MYSQL_DPASSWORD=MYSQLPASSWORD
- MYSQL_DATABASE=nextcloud
- MYSQL_USER=nextcloud
- MYSQL_HOST=db
#ONLY REMOVE THE # FOR HWA IF YOU HAVE A GPU AND WANT TO USE MEMORIES APP INSIDE NEXTCLOUD
go-vod:
image: radialapps/go-vod
restart: always
depends_on:
- app
# devices:
# - /dev/dri:/dev/dri # VA-API (omit for NVENC)
environment:
- NEXTCLOUD_HOST=https://NEXTCLOUD.DOMAIN.COM
- NEXTCLOUD_ALLOW_INSECURE=1 # (self-signed certs or no HTTPS)
volumes:
#this is where you want your files stored on nextcloud
- J:/Nextcloud:/data
#this is where your configs and all nextcloud system files are stored
- J:/Nextcloud:/var/www/html
#only enable if you have a nvidia 1xxx or later and want to use it to transcode
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [gpu]
- Now we can run
docker compose up -d --force-recreate --remove-orphans
to recreate the container and remove old resources - We need to go into Adminstrative Settings ---> Memories ---> Binary Path and add in the connection address this
go-vod:47788
like so
- Now we can see if the hwa is working. So we need to go to Admin Settings on nextcloud ---> memories --> make the transcoding section look like below
- Now that thats done. We need to test so input a video inside nextcloud photos or any directory and try to play it. You should see two options when you select the gear icon
if you see this it is working correctly. Congrats!
You can also check docker desktop go-vod container and see if the logs say something alike to this
2023-12-19 00:12:38 2023/12/19 06:12:38 33w0pebs2le0-480p: /usr/local/bin/ffmpeg -loglevel warning -hwaccel cuda -i /var/www/html/data/__groupfolders/2/20231216_160438.mp4 -copyts -fflags +genpts -vf "format=nv12|cuda,hwupload,scale_cuda=force_original_aspect_ratio=decrease:passthrough=0:w=854:h=854" -map "0:v:0" "-c:v" h264_nvenc -preset p6 -tune ll -rc vbr -rc-lookahead 30 -cq 42 -temporal-aq 1 -map "0:a:0?" "-c:a" aac -ac 1 -start_number 0 -avoid_negative_ts disabled -f hls -hls_flags split_by_time -hls_time 3 -hls_segment_type mpegts -hls_segment_filename /tmp/go-vod/33w0pebs2le0-1296945068/480p-%06d.ts -force_key_frames "expr:gte(t,n_forced*3)" -
2023-12-19 00:12:40 2023/12/19 06:12:40 33w0pebs2le0-480p: recv 480p-000000.ts
2023-12-19 00:12:41 2023/12/19 06:12:41 33w0pebs2le0-480p: recv 480p-000001.ts
2023-12-19 00:12:42 2023/12/19 06:12:42 33w0pebs2le0-480p: recv 480p-000002.ts
2023-12-19 00:12:43 2023/12/19 06:12:43 ffmpeg-error: More than 1000 frames duplicated
2023-12-19 00:12:44 2023/12/19 06:12:44 33w0pebs2le0-480p: recv 480p-000003.ts
2023-12-19 00:12:45 2023/12/19 06:12:45 33w0pebs2le0-480p: recv 480p-000004.ts
2023-12-19 00:12:45 2023/12/19 06:12:45 33w0pebs2le0-480p: goal satisfied: 4
2023-12-19 00:12:46 2023/12/19 06:12:46 33w0pebs2le0-480p: resuming transcoding
2023-12-19 00:12:48 2023/12/19 06:12:48 33w0pebs2le0-480p: recv 480p-000005.ts
2023-12-19 00:12:49 2023/12/19 06:12:49 33w0pebs2le0-480p: recv 480p-000006.ts
2023-12-19 00:12:50 2023/12/19 06:12:50 33w0pebs2le0-480p: recv 480p-000007.ts
2023-12-19 00:12:51 2023/12/19 06:12:51 33w0pebs2le0-480p: recv 480p-000008.ts
2023-12-19 00:12:51 2023/12/19 06:12:51 33w0pebs2le0-480p: goal satisfied: 8
** We will now build our custom repo for with ffmpeg previews and facial recognition**
- Open Terminal/Powershell and run inside C:\Tools\Nextcloud
docker build . -t nextcloud-apache-ffmpeg
- It should start building the custom repo
- Once done we need to edit our docker-compose.yml to use that repo so edit it like so.
version: '2'
services:
db:
image: mariadb:10.6
restart: always
command: --transaction-isolation=READ-COMMITTED --log-bin=binlog --binlog-format=ROW
volumes:
- C:\Tools\Nextcloud\db:/var/lib/mysql
environment:
- MYSQL_ROOT_PASSWORD=SQLROOTPASSWORD
- MYSQL_PASSWORD=MYSQLPASSOWRD
- MYSQL_DATABASE=nextcloud
- MYSQL_USER=nextcloud
app:
image: nextcloud-apache-ffmpeg
restart: always
ports:
- 9111:80
links:
- db
volumes:
- J:/Nextcloud:/data
- J:/Nextcloud:/var/www/html
environment:
- MYSQL_DPASSWORD=MYSQLPASSWORD
- MYSQL_DATABASE=nextcloud
- MYSQL_USER=nextcloud
- MYSQL_HOST=db
#ONLY REMOVE THE # FOR HWA IF YOU HAVE A GPU AND WANT TO USE MEMORIES APP INSIDE NEXTCLOUD
go-vod:
image: radialapps/go-vod
restart: always
depends_on:
- app
# devices:
# - /dev/dri:/dev/dri # VA-API (omit for NVENC)
environment:
- NEXTCLOUD_HOST=https://NEXTCLOUD.DOMAIN.COM
- NEXTCLOUD_ALLOW_INSECURE=1 # (self-signed certs or no HTTPS)
volumes:
#this is where you want your files stored on nextcloud
- J:/Nextcloud:/data
#this is where your configs and all nextcloud system files are stored
- J:/Nextcloud:/var/www/html
#only enable if you have a nvidia 1xxx or later and want to use it to transcode
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [gpu]```
We are only changing this line for others who changed mysql password and other things From
app:
image: nextcloud:latest
to
app:
image: nextcloud-apache-ffmpeg
- Once this is done we can rebuild and docker-compose again by typing
docker compose up -d --force-recreate --remove-orphans
- This time we should now have ffmpeg and facial recognition now ready.
- So go into the Admin Settings and go to Memories then this
- to find ffmpeg location go to docker find your nextcloud app and click on the 3 dots next to our app and select terminal like so
- type 2 commands to give us our ffmpeg and ffprobe binary's
whereis ffmpeg
whereis ffprobe
- Copy the path into those empty ffmpeg paths box and ffprobe path box.
- Once you click out of the box it should update.
- Now we need 2 more apps from the app store. So we go to Adminstrative Panel --> Apps ---> Recognize Adminstrative Panel ---> Apps ---> Preview Generator
- Once this is done we need to enable recognize inside the Adminstrative Settings ---> Recognize and enable the slider
Taiscale firewall and opening exit node commands
Reference: https://tailscale.com/kb/1019/subnets/?tab=linux
EXIT Node/Subnet Enable Command
sudo tailscale up --advertise-routes=192.168.1.0/24 --accept-routes --advertise-exit-node
Allowing ipv4 through exit node
echo 'net.ipv4.ip_forward = 1' | sudo tee -a /etc/sysctl.d/99-tailscale.conf
echo 'net.ipv6.conf.all.forwarding = 1' | sudo tee -a /etc/sysctl.d/99-tailscale.conf
sudo sysctl -p /etc/sysctl.d/99-tailscale.conf
I would Recommend You Install Windows Terminal its a good way to have all your VM's, Powershell, and CMD's all in one place