This file contains hidden or 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 -ex | |
# Build a new Centos8 install on EBS volume in a chroot | |
# Run from RHEL8 or CentOS8 instance - eg: ami-0c322300a1dd5dc79 in us-east-1 (RHEL 8 official image) | |
# Script expects a second EBS volume, I add them as /dev/sdf in the console | |
# When the script completes, turn the second EBS volume into your new AMI through the console. | |
# Adjust the section below to match the device names you're using. Defaults are for an m5.large | |
# m5 series requires the updated device names |
This file contains hidden or 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
{-# LANGUAGE ViewPatterns, LambdaCase, FlexibleContexts #-} | |
module Main where | |
import Control.Applicative | |
import System.Environment | |
import System.Exit | |
import System.IO | |
import System.Process | |
import Data.List (nub, sort) |
This file contains hidden or 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 | |
PROGNAME=$(basename $0) | |
OUTFILE="/tmp/ftplist.$RANDOM.txt" | |
CMDFILE="/tmp/ftpcmd.$RANDOM.txt" | |
ndays=14 | |
print_usage() { | |
echo "" |
This file contains hidden or 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
// Check if a slave has < 10 GB of free space, wipe out workspaces if it does | |
import hudson.model.*; | |
import hudson.util.*; | |
import jenkins.model.*; | |
import hudson.FilePath.FileCallable; | |
import hudson.slaves.OfflineCause; | |
import hudson.node_monitors.*; | |
for (node in Jenkins.instance.nodes) { |