Minimal example: transcode from MP3 to WMA:
ffmpeg -i input.mp3 output.wma
You can get the list of supported formats with:
ffmpeg -formats
You can get the list of installed codecs with:
#!/usr/bin/env python | |
""" Recursively walk the current working directory looking for broken | |
symlinks. If any broken symlinks are found print out a report and exit | |
with status 1. If none are found print out OK and exit with status 0. | |
""" | |
import sys,os | |
print "Checking for broken symlinks...", | |
links = [] |
# add as many as you need... | |
SetEnvIf CF-IPCountry SY RedirectSubdomain=syria | |
SetEnvIf CF-IPCountry AE RedirectSubdomain=uae | |
SetEnvIf CF-IPCountry EG RedirectSubdomain=egypt | |
# Only redirect if Host is not a subdomain | |
SetEnvIfNoCase Host ^.+\.example\.com$ !RedirectSubdomain | |
# Only redirect if cookie "noredirect" doesn't exist | |
SetEnvIfNoCase ^Cookie$ noredirect=true !RedirectSubdomain |
# ----------------------------------------------------------------- | |
# .gitignore for WordPress @salcode | |
# ver 20180808 | |
# | |
# From the root of your project run | |
# curl -O https://gist.githubusercontent.com/salcode/b515f520d3f8207ecd04/raw/.gitignore | |
# to download this file | |
# | |
# By default all files are ignored. You'll need to whitelist | |
# any mu-plugins, plugins, or themes you want to include in the repo. |
Wordpress is a very popular target for hackers. They normally get in with holes found in plugins, themes or in wordpress core.
An up-to-date installation (including plugins and themes) is crutial!
Hardening Wordpress is sadly not a part of the standard installation documentation, but they have a guide available in the "codex": http://codex.wordpress.org/Hardening_WordPress
Removing unused plugins and users, setting htpasswd and/or ip-whitelisting in //wp-admin// also should be considered.
add_action('admin_enqueue_scripts', 'ds_admin_theme_style'); | |
add_action('login_enqueue_scripts', 'ds_admin_theme_style'); | |
function ds_admin_theme_style() { | |
if (!current_user_can( 'manage_options' )) { | |
echo '<style>.update-nag, .updated, .error, .is-dismissible { display: none; }</style>'; | |
} | |
} |
Credit where credit's due, I mainly used these 3 resources to get this all working. There were several others but I don't exactly remember which is which. So at least here are the 3 main places that I used. | |
The vast majority of this came from this link, the others helped me make it work for Plex. | |
http://emby.media/community/index.php?/topic/30975-reverse-proxy-with-ssl-hostname-routing-and-embyopenvpn-port-sharing/ | |
https://gist.github.com/spikegrobstein/4384954 | |
https://forums.plex.tv/discussion/207725/ubuntu-14-04-4-lts-plex-incorrectly-handles-lower-case-headers#latest | |
The data flow here is: |
/etc/ufw/applications.d/plexmediaserver
[plexmediaserver]
title=Plex Media Server (Standard)
description=The Plex Media Server
ports=32400/tcp|3005/tcp|5353/udp|8324/tcp|32410:32414/udp
[plexmediaserver-dlna]
title=Plex Media Server (DLNA)
description=The Plex Media Server (additional DLNA capability only)
<?php | |
/* | |
Plugin Name: Disable REST API for anonymous users | |
*/ | |
/** | |
* Remove all endpoints except SAML / oEmbed for unauthenticated users | |
*/ | |
add_filter( 'rest_authentication_errors', function($result) { | |
if ( ! empty( $result ) ) { |