diff --git a/jupyter/setup.md b/jupyter/setup.md new file mode 100644 index 0000000..09608e4 --- /dev/null +++ b/jupyter/setup.md @@ -0,0 +1,14 @@ + +install R kernel for jupyter to use +* `sudo R` +* `install.packages('IRkernel')` +* `IRkernel::installspec()` + +run on network: +`jupyter notebook --ip 10.0.10.15 --port 8888` + + +basic packages: +* ggplot2, plyr, ggExtra, scales + + diff --git a/nodejs/express.md b/nodejs/express.md index 9c98b94..b23159c 100644 --- a/nodejs/express.md +++ b/nodejs/express.md @@ -6,4 +6,23 @@ openssl genrsa -out key.pem openssl req -new -key key.pem -out csr.pem openssl x509 -req -days 9999 -in csr.pem -signkey key.pem -out cert.pem rm csr.pem -``` \ No newline at end of file +``` + + +##Chrome stops accepting self-signed certs needs mod + +https://stackoverflow.com/questions/43665243/invalid-self-signed-ssl-cert-subject-alternative-name-missing + +1. set a file v3.ext +``` +authorityKeyIdentifier=keyid,issuer +basicConstraints=CA:FALSE +keyUsage = digitalSignature, nonRepudiation, keyEncipherment, dataEncipherment +subjectAltName = @alt_names + +[alt_names] +DNS.1 = %%DOMAIN%% +``` + +2. openssl req -new -key key.pem -out csr.pem -sha256 -extfile v3.ext + diff --git a/nodejs/new_proj.md b/nodejs/new_proj.md new file mode 100644 index 0000000..e69de29 diff --git a/ubuntu/system_service.md b/ubuntu/system_service.md new file mode 100644 index 0000000..9ce0bac --- /dev/null +++ b/ubuntu/system_service.md @@ -0,0 +1,21 @@ +`//etc/systemd/system/filename.service` + +``` +[Unit] +Description=forecast_api +After=network.target + +[Service] +ExecStart=/usr/bin/node //opt/forecast_api/index.js +Restart=always +User=fc_api +Environemnt=NODE_ENV=production +WorkingDirectory=//opt/forecast_api + +[Install] +WantedBy=multi-user.target +``` + +`systemctl enable forecast.api` + +`systemctl start forecast_api.service` \ No newline at end of file