yum -y install https://yum.puppetlabs.com/puppetlabs-release-pc1-el-7.noarch.rpm; \
yum -y install http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm; \
yum -y install https://yum.theforeman.org/releases/1.15/el7/x86_64/foreman-release.rpm; \
yum -y install foreman-release-scl; \
yum -y install foreman-installer; \
echo "192.168.227.154 foreman1.test.local foreman1" >> /etc/hosts; \
echo "192.168.227.154 web-foreman.test.local" >> /etc/hosts; \
echo "192.168.227.156 proxy1.test.local proxy1" >> /etc/hosts; \
This file contains hidden or 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
const axios = require('axios'); | |
const http = require('http'); | |
const https = require('https'); | |
module.exports = axios.create({ | |
//60 sec timeout | |
timeout: 60000, | |
//keepAlive pools and reuses TCP connections, so it's faster | |
httpAgent: new http.Agent({ keepAlive: true }), |
This file contains hidden or 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
<html> | |
<body> | |
<script> | |
function sum(array) { | |
var num = 0; | |
for (var i = 0, l = array.length; i < l; i++) num += array[i]; | |
return num; | |
} |
This file contains hidden or 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
#!/usr/bin/env osascript -l JavaScript | |
// macOS Sierra uses a JavaScriptCore analagous to that in Safari 10.1. This supports all of | |
// ECMAScript 2015 (“ES6”), and even much of ECMAScript 2016! For instance, try `async` functions: | |
async function hello(){ | |
return "Hello, world!" | |
} | |
function run(argv) { | |
var p = hello(); |
This file contains hidden or 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
{ config, lib, pkgs, ... }: | |
let | |
inherit (lib) mkIf mkMerge mkThenElse; | |
cfg = config.r6d.config-generator; | |
computers = config.r6d.computers; | |
profiles = config.r6d.profiles; | |
in | |
{ |
This file contains hidden or 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
""" | |
A bare bones examples of optimizing a black-box function (f) using | |
Natural Evolution Strategies (NES), where the parameter distribution is a | |
gaussian of fixed standard deviation. | |
""" | |
import numpy as np | |
np.random.seed(0) | |
# the function we want to optimize |
Please go to Enable Docker Remote API with TLS client verification.
This file contains hidden or 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
const presets = ['react', 'es2015']; | |
export const development = { | |
presets, | |
}; | |
export const production = { | |
presets, | |
plugins: ['transform-remove-console'], | |
}; |
- React: https://github.com/insin/react-hn (PWA)
- VueJS 2.0: https://github.com/vuejs/vue-hackernews-2.0 (PWA)
- Angular 2.0: https://github.com/housseindjirdeh/angular2-hn (PWA)
- Ember: https://github.com/chancancode/hn-reader
- Preact: https://github.com/addyosmani/preact-hn (PWA)
- Inferno: https://github.com/infernojs/inferno-hn