I hereby claim:
- I am krainet on github.
- I am ralberti (https://keybase.io/ralberti) on keybase.
- I have a public key ASAmfztx7hy7_Z34xVwW0BTG6DFA3-wFIxhEGC7Qce4HOAo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
#!/bin/bash | |
kubectl apply -f https://raw.githubusercontent.com/kubernetes/dashboard/v1.10.1/src/deploy/recommended/kubernetes-dashboard.yaml | |
#create service account | |
cat <<EOF > k8s-service-account.yaml | |
apiVersion: v1 | |
kind: ServiceAccount | |
metadata: | |
name: admin-user |
#!/bin/bash | |
kubectl get nodes | |
cp /etc/kubernetes/admin.conf ~/.kube/config |
#!/bin/bash | |
kubeadm join 192.168.1.142:6443 --token 0gx03i.bkjfviauhce6q3ns --discovery-token-ca-cert-hash sha256:bed83e5c33b66416d8d6081b7416d8f7d25777238bcfe9efd1fa88c2ddb79974 | |
#is you lost your join command yo can retriew with (on master): | |
#kubeadm token create --print-join-command |
#!/bin/bash | |
systemctl daemon-reload | |
systemctl restart kubelet | |
kubeadm init | |
#if you are root | |
export KUBECONFIG=/etc/kubernetes/admin.conf |
#!/bin/bash | |
swapoff -a | |
#vi /etc/fstab and disable swap partition | |
yum install -y docker | |
systemctl enable docker && systemctl start docker | |
cat <<EOF > /etc/yum.repos.d/kubernetes.repo |
Create a repo. Make sure there is at least one file in it (even just the README) Generate ssh key:
ssh-keygen -t rsa -C "your_email@example.com"
Copy the contents of the file ~/.ssh/id_rsa.pub to your SSH keys in your GitHub account settings. Test SSH key:
ssh -T git@github.com
<?php | |
class PushApns | |
{ | |
private $apnsPemFile="ck.pem"; //pem file link | |
private $type = 'dev'; //development and distribution (dev or dis) | |
private $passphrase = 'yourPass'; | |
public function SendNotification($device_token, $message, $sound = "bingbong.aiff",$debug=false) | |
{ |
//Without AngularJS | |
//Include socket.io library to your JS app | |
//Sample: <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/socket.io/1.5.1/socket.io.js"></script> | |
//Instantiate global var socket. | |
var socket = io(); |
/* | |
* Api Test Módule | |
*/ | |
angular.module('productsService', []) | |
.factory('productsService', ['$resource', '$q', '$log', | |
function ($resource, $q, $log) { | |
return { | |
api: function (extra_route) { | |
if (!extra_route) { | |
extra_route = ''; |