Skip to content

Instantly share code, notes, and snippets.

View chiefkana's full-sized avatar
🏢
Working

Kanat Bektursyn chiefkana

🏢
Working
  • ATI.kz
  • Kazakhstan, Almaty
View GitHub Profile
@chiefkana
chiefkana / gist:37f8d14e195adf83c585e9ce4a76a786
Created March 21, 2022 10:13 — forked from sc212/gist:2287047
CSS: Clean up default browser styling
html, body {
border:0;
margin:0;
padding:0;
}
body {
font:100%/1.25 Arial, Helvetica, sans-serif;
}
@chiefkana
chiefkana / node_nginx_ssl.md
Created September 16, 2021 11:00 — forked from bradtraversy/node_nginx_ssl.md
Node app deploy with nginx & SSL

Node.js Deployment

Steps to deploy a Node.js app to DigitalOcean using PM2, NGINX as a reverse proxy and an SSL from LetsEncrypt

1. Sign up for Digital Ocean

If you use the referal link below, you get $10 free (1 or 2 months) https://m.do.co/c/5424d440c63a

2. Create a droplet and log in via ssh

I will be using the root user, but would suggest creating a new user

Configure Mail Settings

Before you can send emails with ColdFusion, a mail server you want to use needs to be set. Configuring the mail server can be done in the ColdFusion Administrator.

If you do not have a mail server of your own, your localhost can act as a mail server. ColdFusion will act normally, but since there is no mail server set up on your localhost, emails will not arrive at their destination. Another option is to use the mail server of Gmail (a Gmail account is required for this). The settings for this mail server can be found at the end of this section.

@chiefkana
chiefkana / autoStore.js
Created September 2, 2021 06:52 — forked from du5rte/autoStore.js
Auto saving to localStorage with MobX
import mobx from "mobx"
import store from "store"
export default function(_this) {
let firstRun = true
// will run on change
mobx.autorun(() => {
// on load check if there's an existing store on localStorage and extend the store
if (firstRun) {