openssl req -x509 -newkey rsa:4096 -sha256 -keyout example.key -out example.crt -subj "/CN=example.com" -days 3650 -passout pass:foobar
openssl x509 -x509toreq -in example.crt -out example.csr -signkey example.key -passin pass:foobar
openssl req -x509 -newkey rsa:4096 -sha256 -keyout example.key -out example.crt -subj "/CN=example.com" -days 3650 -passout pass:foobar
openssl x509 -x509toreq -in example.crt -out example.csr -signkey example.key -passin pass:foobar
Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.
$ python -m SimpleHTTPServer 8000| git clone https://github.com/vfarcic/k8s-specs.git | |
| cd k8s-specs | |
| git pull | |
| open "https://console.aws.amazon.com/iam/home#/security_credential" | |
| export AWS_ACCESS_KEY_ID=[...] |
| // getComponent is a function that returns a promise for a component | |
| // It will not be called until the first mount | |
| function asyncComponent(getComponent) { | |
| return class AsyncComponent extends React.Component { | |
| static Component = null; | |
| state = { Component: AsyncComponent.Component }; | |
| componentWillMount() { | |
| if (!this.state.Component) { | |
| getComponent().then(Component => { |
This guide describes how to bootstrap new Production Core OS Cluster as High Availability Service in a 15 minutes with using etcd2, Fleet, Flannel, Confd, Nginx Balancer and Docker.
For excessively paranoid client authentication.
Organization & Common Name: Some human identifier for this server CA.
openssl genrsa -des3 -out ca.key 4096
openssl req -new -x509 -days 365 -key ca.key -out ca.crt
| # Need to do the following steps: | |
| # 1. create /var/prometheus first. | |
| # 2. run: docker-compose run promdash ./bin/rake db:migrate | |
| nodeexporter: | |
| image: prom/node-exporter | |
| ports: | |
| - "9100:9100" | |
| prometheus: | |
| image: prom/prometheus |
| import UIKit | |
| import MessageUI // Import MessageUI | |
| // Add the delegate protocol | |
| class ViewController: UIViewController, MFMessageComposeViewControllerDelegate { | |
| // Send a message | |
| func sendMessage() { | |
| let messageVC = MFMessageComposeViewController() | |
| messageVC.body = "Message String" |
git clone [email protected]:YOUR-USERNAME/YOUR-FORKED-REPO.git
cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream