This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- hosts: tpots | |
remote_user: root | |
gather_facts: yes | |
vars: | |
ansible_python_interpreter: /usr/bin/python3 | |
tpot_web_user: "user" | |
tpot_web_pw: "mypassword" | |
tasks: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$Keep = 3 | |
$Today = (Get-Date).DayOfWeek | |
# Cleanup if Monday | |
If ( $Today -eq "Monday" ) { | |
Write-Host "Running TSM cleanup." | |
& tsm maintenance cleanup | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Display a custom taxonomy dropdown in admin | |
* @author Mike Hemberger | |
* @link http://thestizmedia.com/custom-post-type-filter-admin-custom-taxonomy/ | |
*/ | |
add_action('restrict_manage_posts', 'tsm_filter_post_type_by_taxonomy'); | |
function tsm_filter_post_type_by_taxonomy() { | |
global $typenow; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$From = "spamextract@domain.com" | |
$To = "emailadmins@domain.com" | |
$SmtpServer = "mail.domain.com" | |
$HoldingMailbox = "expungedemails@domain.com" | |
$ErrorActionPreference = "Stop" | |
Write-Host "" | |
Write-Host "Office 365 Mail Extract" -ForegroundColor "Green" | |
Start-Sleep 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-Content ComputersToShutdownInOrder.txt | Foreach-Object { Stop-Computer $PSItem -Force; Do { Write-Host "$PSItem still pinging!"; Start-Sleep -s 1 } Until ( ( Test-Connection -Count 1 -Quiet $PSItem ) -eq $False ); Write-Host "$PSItem is down!" } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Get-PublicFolder -Recurse | Where-Object { $PSItem.ParentPath -eq "\" } | Get-PublicFolderClientPermission | Where-Object { $PSItem.AccessRights -contains "Owner" } | Export-CSV .\PF_Owners.csv -NoTypeInformation |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if ( ( $_GET["var1"] != '' ) || ( $_GET["var2"] != '' ) || ( $_GET["var3"] != '' ) ) { | |
if ( $_GET["var1"] != '' ) { | |
$meta_query[] = array( 'key' => 'meta_value1', 'value' => $_GET["var1"], 'compare' => '=' ); | |
} | |
if ( $_GET["var2"] != '' ) { | |
$meta_query[] = array( 'key' => 'meta_value2', 'value' => $_GET["var2"], 'compare' => '=' ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Download and install EPEL repository. | |
/usr/bin/wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm | |
/usr/bin/yum -y install epel-release-6*.rpm | |
# Fully update the system and install Ansible | |
/usr/bin/yum -y update | |
/usr/bin/yum -y install ansible |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diskpart | |
list vol | |
sel vol 2 | |
attributes volume clear hidden readonly nodefaultdriveletter shadowcopy | |
sel vol 3 | |
attributes volume clear hidden readonly nodefaultdriveletter shadowcopy | |
exit | |
recovery\startrep.exe |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>autoremove</key> | |
<false/> | |
<key>catalogs</key> | |
<array> | |
<string>production</string> | |
</array> |
NewerOlder