Skip to content

Instantly share code, notes, and snippets.

# This tells kubecfg to read its config from the local directory
export KUBECONFIG=./kubeconfig
# Looking at the cluster
kubectl get nodes
kubectl get pods --namespace=kube-system
# Running a single pod
kubectl run --generator=run-pod/v1 --image=gcr.io/kuar-demo/kuard-amd64:1 kuard
kubectl get pods
@helderjs
helderjs / dql.sql
Created December 29, 2013 17:56
DQL Query
SELECT DISTINCT item.positioning
FROM Ciwwic\PositionBundle\Entity\PositionItem item
JOIN item.periods period
WHERE item.keyword = :keyword
AND item.region = :region
AND item.page = :page
AND period.date = :period
@helderjs
helderjs / gist:8048984
Created December 20, 2013 01:14
Exemplo Goutte
<html>
<head>
<title>PHP Teste</title>
</head>
<body>
<?php
require_once 'goutte.phar';
$goutte = new Goutte\Client();
$baseURL = 'http://www.galaticosonline.com/';
/**
* @Route("/state/searchbyuser", name="state_search_by_user"
* @Method("GET")
*/
public function searchByUser()
{
$request = $this->getRequest();
$user = $this->getUser();
$em = $this->getDoctrine()->getManager();
$query = $em->execute('