Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • hpc-team/HPCasCode
  • chines/ansible_cluster_in_a_box
2 results
Show changes
#!/bin/bash
vglrun --version
#!/bin/bash
name=$( realpath $0 | xargs dirname | xargs basename )
ver=${1:-"default"}
bin_dirs=$(module show $name/$ver 2>&1 | sed -n "s/.* PATH \(.*\)/\1/p")
NAME_EXEC_EXIST=false
for bin in $bin_dirs; do
for i in $(find $bin -maxdepth 1 -executable -type f ); do
if [[ $(basename $i) == $name ]]; then
$i --version;
exit $?
fi
done
done
#!/bin/bash
name=$( realpath $0 | xargs dirname | xargs basename )
ver=${1:-"default"}
bin_dirs=$(module show $name/$ver 2>&1 | sed -n "s/.* PATH \(.*\)/\1/p")
NAME_EXEC_EXIST=false
for bin in $bin_dirs; do
for i in $(find $bin -maxdepth 1 -executable -type f ); do
if [[ $(basename $i) == $name ]]; then
$i --version;
exit $?
fi
done
done
#!/bin/bash
#MODULE_LOGGING_PATH=/projects/pMOSP/module_logging
MODULE_LOGGING_PATH=/home/luhanc/module_logging
userlist=$(ls -d $MODULE_LOGGING_PATH/*/)
latest=$(ls -t $MODULE_LOGGING_PATH | head -n1)
ts=$(date -r $MODULE_LOGGING_PATH/$latest | sed 's/ /_/g' | sed 's/\:/\_/g')
echo $ts
#!/bin/bash
name=$1
ver=$2
mtime=${3:-180}
MODULE_LOGGING_PATH=/projects/pMOSP/module_logging
#MODULE_LOGGING_PATH=/home/luhanc/module_logging
declare -A usage
while read i;do
if [ -f $i ] && grep -q $name/$ver $i; then
username=$(dirname $i | xargs basename)
if [ ${usage[$username]+_} ]; then
usage[$username]=$((usage[$username]+1))
else
usage[$username]=1
fi
fi
done < <(find $MODULE_LOGGING_PATH -mtime -$mtime)
declare -i total=0
for K in "${!usage[@]}"; do echo $K --- ${usage[$K]};total+=${usage[$K]}; done
echo "Total $total use in past $mtime days"
---
-
hosts: openvpn-clients
remote_user: ec2-user
roles:
- syncExports
- nfs-client
sudo: true
vars:
nfs_server: "vm-118-138-240-224.erc.monash.edu.au"
openvpn_servers:
- vm-118-138-240-224.erc.monash.edu.au
x509_ca_server: vm-118-138-240-224.erc.monash.edu.au
# easy-rsa parameter settings
# NOTE: If you installed from an RPM,
# don't edit this file in place in
# /usr/share/openvpn/easy-rsa --
# instead, you should copy the whole
# easy-rsa directory to another location
# (such as /etc/openvpn) so that your
# edits will not be wiped out by a future
# OpenVPN package upgrade.
# This variable should point to
# the top level of the easy-rsa
# tree.
export EASY_RSA="/etc/easy-rsa/2.0"
#
# This variable should point to
# the requested executables
#
export OPENSSL="openssl"
export PKCS11TOOL="pkcs11-tool"
export GREP="grep"
# This variable should point to
# the openssl.cnf file included
# with easy-rsa.
export KEY_CONFIG=`$EASY_RSA/whichopensslcnf $EASY_RSA`
# Edit this variable to point to
# your soon-to-be-created key
# directory.
#
# WARNING: clean-all will do
# a rm -rf on this directory
# so make sure you define
# it correctly!
export KEY_DIR="$EASY_RSA/keys"
# Issue rm -rf warning
echo NOTE: If you run ./clean-all, I will be doing a rm -rf on $KEY_DIR
# PKCS11 fixes
export PKCS11_MODULE_PATH="dummy"
export PKCS11_PIN="dummy"
# Increase this to 2048 if you
# are paranoid. This will slow
# down TLS negotiation performance
# as well as the one-time DH parms
# generation process.
export KEY_SIZE=512
# In how many days should the root CA key expire?
export CA_EXPIRE=3650
# In how many days should certificates expire?
export KEY_EXPIRE=3650
# These are the default values for fields
# which will be placed in the certificate.
# Don't leave any of these fields blank.
export KEY_COUNTRY={{ countryName }}
export KEY_PROVINCE={{ reginalName }}
export KEY_CITY={{ cityName }}
export KEY_ORG={{ organizationName }}
export KEY_EMAIL={{ emailAddress }}
export KEY_OU={{ organizationUnit }}
# X509 Subject Field
export KEY_NAME="EasyRSA"
# PKCS11 Smart Card
# export PKCS11_MODULE_PATH="/usr/lib/changeme.so"
# export PKCS11_PIN=1234
# If you'd like to sign all keys with the same Common Name, uncomment the KEY_CN export below
# You will also need to make sure your OpenVPN server config has the duplicate-cn option set
# export KEY_CN="CommonName"
---
apache: httpd
packager: yum
---
apache: apache2
packager: apt
---
packager: yum
apache: httpd