Skip to content

Instantly share code, notes, and snippets.

View robsonbittencourt's full-sized avatar

Robson robsonbittencourt

View GitHub Profile
@robsonbittencourt
robsonbittencourt / userdata.sh
Created October 15, 2014 00:20
A user data sample for AWS Launch Configuration
#!/bin/bash
yum groupinstall -y "Web Server"
service httpd start
instance_id=$(curl http://169.254.169.254/latest/meta-data/instance-id)
echo "<h3>I'am the instance $instance_id</h3>" > /var/www/html/index.html
public static Long getRandomLong() {
return Long.valueOf(new Random().nextInt(999999999) + 1);
}
public static String getRandomString() {
return getRandomString(10);
}
public static String getRandomString(int length) {
final Random random = new Random();
#!/bin/bash
##curl
sudo apt-get -y install curl &&
## Adding repositories
### Chrome
wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo apt-key add -
sudo sh -c 'echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list'
# .bash_profile
if [ -r ~/.bashrc ]; then
. ~/.bashrc
fi
@robsonbittencourt
robsonbittencourt / config
Last active August 29, 2020 17:16
Terminator config
[global_config]
tab_position = hidden
[keybindings]
[profiles]
[[default]]
icon_bell = False
background_darkness = 0.85
background_type = transparent
cursor_color = "#aaaaaa"
foreground_color = "#ffffff"