This file contains 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
### Keybase proof | |
I hereby claim: | |
* I am memosanchez on github. | |
* I am memo (https://keybase.io/memo) on keybase. | |
* I have a public key whose fingerprint is F759 623E 98CE 4227 8F22 9CE7 8CF7 50E9 C97C 4323 | |
To claim this, I am signing this object: |
This file contains 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
class myComponent extends React.Component { | |
state = { | |
data: null, | |
}; | |
async componentDidMount() { | |
const res = await fetch('/api/endpoint'); | |
const dataFromApi = res.json(); | |
this.setState({ data: dataFromApi }); |
This file contains 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
# install git | |
sudo apt-get install g++ curl libssl-dev apache2-utils make | |
sudo apt-get install git-core | |
# download the Node source, compile and install it | |
cd /opt | |
git clone https://github.com/joyent/node.git | |
cd node | |
git checkout v0.6 | |
./configure |
This file contains 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
{ | |
graphitePort: 2003, | |
graphiteHost: "localhost", | |
port: 8125, | |
backends: [ "./backends/graphite" ] | |
} |
This file contains 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
var server = { host: process.env.ES_HOST || 'localhost' | |
, port: process.env.ES_PORT || 9200 | |
, secure: false | |
, auth: { username: process.env.ES_USERNAME | |
, password: process.env.ES_PASSWORD | |
} | |
} | |
var serverOptions = { | |
host: process.env.ES_HOST, |