Skip to content

Instantly share code, notes, and snippets.

View rickhernandezio's full-sized avatar
🎯
Focusing

Rick Hernandez rickhernandezio

🎯
Focusing
View GitHub Profile
MailPro = require('mailpro')
var mailPro = new MailPro({
privateKey: "key-xxxxxxxxxxxxxxx",
publicKey: "pubkey-xxxxxxxxxxxxx",
domain: "domain.com",
secret: "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
});
// You can start using any of the methods below
wget https://raw.githubusercontent.com/knowrick/DynamoDB/master/setup.sh
sudo sh setup.sh
netstat -ntlp | grep LISTEN
tail -f /var/log/system.log
sudo systemctl start dynamodb.service
@rickhernandezio
rickhernandezio / Verify service is up
Last active January 20, 2018 18:19
Verify service is up
sudo systemctl stop dynamodb.service
sudo systemctl start dynamodb.service
sudo systemctl status dynamodb.service
@rickhernandezio
rickhernandezio / Reload Daemon service
Created January 20, 2018 18:16
Reload Daemon service
systemctl daemon-reload
touch /etc/systemd/system/dynamodb.service
vim /etc/systemd/system/dynamodb.service
[Unit]
Description=DynamoDB on Localhost
After=network.target
Documentation=https://docs.aws.amazon.com/amazondynamodb/latest/developerguide/DynamoDBLocal.html
[Service]
Environment=deploydir=/opt/dynamodb
Type=simple
User=dynamodb
Group=dynamodb
@rickhernandezio
rickhernandezio / gist:37bd57479a85f24ddfe663ce97ab2c2e
Created January 20, 2018 18:11
Create a user that will run the service
useradd dynamodb
chown -R dynamodb:dynamodb /opt/dynamodb
@rickhernandezio
rickhernandezio / gist:59233f9270282ef6a1515898775657a2
Created January 20, 2018 18:07
Create a deploy directory for the service daemon
mkdir /opt/dynamodb
mv * /opt/dynamodb
cd /opt/dynamodb
mkdir /opt/dynamodb/data
find . -type d -exec chmod 755 {} \;
find . -type f -exec chmod 644 {} \;
chmod -R g+w ./data