Skip to content

Instantly share code, notes, and snippets.

staticClients:
- id: example-app
redirectURIs:
- 'http://127.0.0.1:5555/callback'
name: 'Some sample app'
secret: your-super-secret
server {
listen 80;
location / {
root /usr/share/nginx/html;
index index.html index.htm;
try_files $uri $uri/ /index.html;
if (!-e $request_filename){
rewrite ^(.*)$ /index.html break;
@berinle
berinle / gist:0d92d5caa24545702e83fe6a1c8a0ea8
Last active January 19, 2021 16:27
working_istio_vs_react
---
apiVersion: networking.istio.io/v1alpha3
kind: Gateway
metadata:
name: foo-gateway
spec:
selector:
istio: ingressgateway # use istio default controller
servers:
- port:
@berinle
berinle / v1.2.x
Last active January 20, 2021 21:36
kf-image-list
k8s.gcr.io/autoscaling/cluster-autoscaler:v1.20.0
docker.io/seldonio/seldon-core-operator:1.6.0-dev
gcr.io/arrikto/kubeflow/oidc-authservice:fef11c3
gcr.io/knative-releases/knative.dev/serving/cmd/controller@sha256:b86ac8ecc6b2688a0e0b9cb68298220a752125d0a048b8edf2cf42403224393
gcr.io/knative-releases/knative.dev/serving/cmd/autoscaler-hpa@sha256:34eeb5629fbc2c1461d220728ff9144da0918c71a4684a2bf6ed594f926af570
gcr.io/knative-releases/knative.dev/serving/cmd/activator@sha256:ffa3d72ee6c2eeb2357999248191a643405288061b7080381f22875cb703e929
gcr.io/knative-releases/knative.dev/serving/cmd/autoscaler@sha256:f89fd23889c3e0ca3d8e42c9b189dc2f93aa5b3a91c64e8aab75e952a210eeb3
gcr.io/knative-releases/knative.dev/serving/cmd/controller@sha256:b86ac8ecc6b2688a0e0b9cb68298220a752125d0a048b8edf2cf42403224393
@berinle
berinle / gist:db9997dc53be198cf662737b9f141120
Created October 11, 2019 11:33
stemcell build for windows
root@ffeaf3c666a6:/app# ./stembuild-linux-x86_64-2019.11 construct --help
stembuild-linux-x86_64-2019.11 construct -vm-ip <IP of VM> -vm-username <vm username> -vm-password <vm password> -vcenter-url <vCenter URL> -vcenter-username <vCenter username> -vcenter-password <vCenter password> -vm-inventory-path <vCenter VM inventory path>
Prepares a VM to be used by stembuild package. It leverages stemcell automation scripts to provision a VM to be used as a stemcell.
Requirements:
LGPO.zip in current working directory
Running Windows VM with:
- Up to date Operating System
- Reachable by IP
@berinle
berinle / db.json
Last active December 3, 2018 02:51
cf-mariadb.txt
"VCAP_SERVICES": {
"p.mysql": [
{
"credentials": {
"hostname": "xx.xx.xx.xx",
"jdbcUrl": "jdbc:mysql://xx.xx.xx.xx:3306/service_instance_db?user=5ec4bbb40f5a407f937cf99e2643b857\u0026password=*****\u0026useSSL=false",
"name": "service_instance_db",
"password": "********",
"port": 3306,
"uri": "mysql://5ec4bbb40f5a407f937cf99e2643b857:********@xx.xx.xx.xx:3306/service_instance_db?reconnect=true",
@berinle
berinle / auth-interceptor.java
Created December 19, 2016 18:31
request interceptor
class AuthInterceptor implements RequestInterceptor {
@Override
public void apply(RequestTemplate template) {
Map<String, Collection<String>> headers = template.request().headers();
Collection<String> authorization = headers.get("Authorization");
if (null != authorization && !authorization.isEmpty()) {
for (String s : authorization) {
template.header("Authorization", s);
}
@berinle
berinle / gist:6ab52cc296d337e340c9
Created February 25, 2016 19:14
ansible ec2.py error on first run
command run:
ansible-playbook -i playbooks.d/inventory/ec2.py test.yml -e @env/dev.yml
ERROR! The file playbooks.d/inventory/ec2.py is marked as executable, but failed to execute correctly. If this is not supposed to be an executable script, correct this with `chmod -x playbooks.d/inventory/ec2.py`.
ERROR! failed to parse executable inventory script results from /home/ec2-user/dd/playbooks.d/inventory/ec2.py: ERROR! Syntax Error while loading YAML.
The error appears to have been in '<string>': line 3, column 21, but may
be elsewhere in the file depending on the exact syntax problem.
@berinle
berinle / troubleshooting-deis
Created July 20, 2014 22:04
Troubleshooting deis
❯ fleetctl --version
fleetctl version 0.5.0
❯ make run
Job deis-router.1.service loaded on ece0269d.../172.17.8.100
Job deis-builder-data.service loaded on ece0269d.../172.17.8.100
Job deis-database-data.service loaded on ece0269d.../172.17.8.100
Job deis-logger-data.service loaded on ece0269d.../172.17.8.100
Job deis-registry-data.service loaded on ece0269d.../172.17.8.100
fleetctl --strict-host-key-checking=false load registry/systemd/deis-registry.service logger/systemd/deis-logger.service cache/systemd/deis-cache.service database/systemd/deis-database.service
@berinle
berinle / cheats
Created March 5, 2014 16:30
Digital Ocean + Dokku Cheats
== Deploying on digital ocean with the dokku image
### Read this great article
https://www.andrewmunsell.com/blog/dokku-tutorial-digital-ocean
### Make sure you update the buildstep *on the remote box* by doing this:
See https://github.com/progrium/dokku#upgrading[Uprading dokku set up]
====