Skip to content

Instantly share code, notes, and snippets.

View potatoru's full-sized avatar
😴
zzz...

Alexander Morozov potatoru

😴
zzz...
View GitHub Profile
@BenjaminPoncet
BenjaminPoncet / ffmpeg-wrapper
Last active January 9, 2025 22:51
Synology VideoStation ffmpeg wrapper with DTS, EAC3 and TrueHD support. This project is no longer maintained: Please see the following projects: https://github.com/darknebular/Wrapper_VideoStation/ - https://github.com/AlexPresso/VideoStation-FFMPEG-Patcher
#!/bin/bash
rev="12"
_log(){
echo "$(date '+%Y-%m-%d %H:%M:%S') - ${streamid} - $1" >> /tmp/ffmpeg.log
}
_log_para(){
echo "$1" | fold -w 120 | sed "s/^.*$/$(date '+%Y-%m-%d %H:%M:%S') - ${streamid} - = &/" >> /tmp/ffmpeg.log
@drkdelaney
drkdelaney / .drive_global_blacklist.filter
Created December 2, 2019 20:16
A blacklist for Synology folders and files.
[Version]
major = 1
minor = 1
[Common]
@4ndv
4ndv / danted.conf
Last active May 24, 2018 16:47
Telegram danted.conf
# /etc/danted.conf
logoutput: syslog /var/log/sockd.log
internal: eth0 port = 1080
external: eth0
clientmethod: none
socksmethod: username
@ikawka
ikawka / restricted-ftp-user.sh
Last active February 3, 2025 23:21
Create an sftp user and restrict to specific folder.
#1. Create the sftp group
sudo groupadd sftpusers
#2. Comment out the default "Subsystems sftp" in the ssh config
sudo sed -i "s/Subsystem sftp \/usr\/lib\/openssh\/sftp-server/#Subsystem sftp \/usr\/lib\/openssh\/sftp-server/" /etc/ssh/sshd_config
#3. Modify the ssh config
sudo vi /etc/ssh/sshd_config
#Add the these lines to the end of the file
@ikus060
ikus060 / smx8fancontrol
Last active October 30, 2024 20:58
Python script to edit the X8DTL-iF Registry to control fan speed.
#!/usr/bin/env python
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
@amercier
amercier / synology-scheduled-tasks.md
Last active November 13, 2024 09:36
Turn leds on/off on Synology DiskStation

Synology scheduled tasks

Usage

Go to Control Panel / Task Scheduler and add the content of these scripts as root scripts.

Leds

@slogsdon
slogsdon / Ranking.php
Created September 15, 2012 03:42
Reddit Ranking Algorithms in PHP
<?php
/**
* Ranking Library
* contains alogrithms for story ranking
* Basically a PHP Implementation of reddits algorithms
*
* @author Lucas Nolte <[email protected]>
* @since 0.1
* @package Polska Wiadomosc
* @subpackage Libraries