This text is italic
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
| sudo su | |
| #create jvm directory | |
| mkdir /usr/lib/jvm | |
| #uncompress, change to your file name | |
| tar -zxf jdk-8u211-linux-x64.tar.gz -C /usr/lib/jvm | |
| #check if files are there | |
| #ls /usr/lib/jvm |
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
| # to generate your dhparam.pem file, run in the terminal | |
| openssl dhparam -out /etc/nginx/ssl/dhparam.pem 2048 |
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
| # Private key | |
| openssl genpkey -algorithm RSA -out private.pem -pkeyopt rsa_keygen_bits:2048 | |
| # Public key | |
| openssl rsa -pubout -in private.pem -out public_key.pem | |
| # Private key in pkcs8 format (for Java maybe :D) | |
| openssl pkcs8 -topk8 -in private.pem -out private_key.pem | |
| ## nocrypt (Private key does have no password) |
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
| @Configuration | |
| @EnableJpaAuditing(dateTimeProviderRef = "dateTimeProvider") | |
| @EnableJpaRepositories("com.sample.repository") | |
| @EnableTransactionManagement | |
| public class DatabaseConfiguration implements EnvironmentAware { | |
| private final Logger log = LoggerFactory.getLogger(DatabaseConfiguration.class); | |
| private RelaxedPropertyResolver dataSourcePropertyResolver; | |
| private RelaxedPropertyResolver slaveDataSourcePropertyResolver; |
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
| docker network disconnect "${PWD##*/}_shared" roach-4 | |
| docker network disconnect "${PWD##*/}_shared" roach-5 |
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
| Convert a video to Mp4(MPEG-4 AVC) and AAC audio | |
| /* Step 1. Declaring source file and Target file */ | |
| File source = new File("source.avi"); | |
| File target = new File("target.mp4"); | |
| /* Step 2. Set Audio Attrributes for conversion*/ | |
| AudioAttributes audio = new AudioAttributes(); | |
| audio.setCodec("aac"); | |
| // here 64kbit/s is 64000 |