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
Grails externalized configuration files: | |
If you want to include a config groovy class, you have to include it as an object in the config location list. | |
Despite the comments saying this: | |
// grails.config.locations = [ "classpath:${appName}-config.properties", | |
// "classpath:${appName}-config.groovy", | |
// "file:${userHome}/.grails/${appName}-config.properties", | |
// "file:${userHome}/.grails/${appName}-config.groovy"] |
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
# Number indicates size, in bytes, to leave. Can run on a file that is currently being written to, like server logs. | |
sudo truncate -s 4 server.log | |
# Deletes files and directories older than 7 days | |
sudo find <full path dir> -ctime +7 -exec rm -rf {} \; | |
# Disk space | |
df | |
df -h // human-readable |
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
# Assumptions | |
- OpenSSL is installed | |
- base working directory is /usr/lib/ssl/misc | |
# Create new certificate authority, created in demoCA directory | |
sudo ./CA.pl -newca | |
# Sign a certificate request using CA created above | |
sudo openssl x509 -req -CA demoCA/cacert.pem -CAkey demoCA/private/cakey.pem -in newreq.pem -out localhost.cer -days 1460 -CAcreateserial |
NewerOlder