Skip to content

Instantly share code, notes, and snippets.

View lucasjellema's full-sized avatar

Lucas Jellema lucasjellema

View GitHub Profile
@lucasjellema
lucasjellema / readme.md
Last active December 5, 2023 09:22
OCI NoSQL Database SQL

To create the table, we need a DDL statement - it still feels weird to say stuff like that regarding a NoSQL database

CREATE TABLE TWEETS_TABLE(id LONG, text STRING, author STRING, tweet_timestamp TIMESTAMP(0), language STRING, hashtags STRING, PRIMARY KEY(SHARD(id))) USING TTL 1 DAYS

This can be done in OCI CLI. It is convenient to first set the compartment OCID

export COMPARTMENT_OCID=ocid................................

Then:

@lucasjellema
lucasjellema / build_specification.yaml
Last active April 24, 2023 09:58
function tweetretriever build specification file
version: 0.1
component: build
timeoutInSeconds: 6000
runAs: root
shell: bash
env:
# these are local variables to the build config
variables:
FUNCTION_DIRECTORY: "tweet_retriever_source/functions/tweet-summarizer"
# # the value of a vaultVariable is the secret-id (in OCI ID format) stored in the OCI Vault service

Conclusion Code Cafe - 17th November 2022 - Handson

Three handson labs:

  • Backstage
  • Gitpod
  • OpenTelemetry

Backstage

The Backstage handson provides a Gitpod workspace in which a Backstage instance can be easily installed and explored. The handson instruction has some references to tutorials that help you look around Backstage.

@lucasjellema
lucasjellema / docker-compose.yml
Created May 22, 2018 04:57
Docker Compose file for Apache Kafka, the Confluent Platform (4.1.0) - with Kafka Connect, Kafka Manager, Schema Registry and KSQL (1.0) - assuming a Docker Host accessible at 192.168.188.102
version: '2'
services:
zookeeper:
image: "confluentinc/cp-zookeeper:4.1.0"
hostname: zookeeper
ports:
- "2181:2181"
environment:
ZOOKEEPER_CLIENT_PORT: 2181
@lucasjellema
lucasjellema / Vagrantfile
Last active May 26, 2022 05:23
Vagrantfile for creating and running an Ubuntu VM with large disk, preconfigured IP address, provisioned Docker and Docker Compose
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure(2) do |config|
# The most common configuration options are documented and commented below.
# For a complete reference, please see the online documentation at
# https://docs.vagrantup.com.
# Every Vagrant development environment requires a box. You can search for
# boxes at https://atlas.hashicorp.com/search.
@lucasjellema
lucasjellema / objectstorage.go
Last active December 31, 2021 11:39
Dapr custom state store on OCI ObjectStorage
/*
OCI Object Storage state store.
Sample configuration in yaml:
apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
name: statestore
spec:
@lucasjellema
lucasjellema / objectstorage.go
Created December 28, 2021 13:39
SkeletonStateStoreComponent
/*
OCI Object Storage state store.
Sample configuration in yaml:
apiVersion: dapr.io/v1alpha1
kind: Component
metadata:
name: statestore
spec:
@lucasjellema
lucasjellema / main.go
Last active December 28, 2021 12:08
OCI Go SDK ObjectStorag explorations
package main
import (
"context"
"fmt"
"io"
"io/ioutil"
"log"
"net/http"
"os"
@lucasjellema
lucasjellema / commands.md
Last active December 12, 2021 12:46
OKE-dashboard-app-deployment

Get Kubernetes Dashboard Running

Install Dashboard on Cluster kubectl apply -f https://raw.githubusercontent.com/kubernetes/dashboard/v2.4.0/aio/deploy/recommended.yaml

Verify the deployment kubectl -n kubernetes-dashboard get pods

Proxy Cluster kubectl proxy

@lucasjellema
lucasjellema / query.tf
Last active December 2, 2021 07:40
terraform-oci-query-functions-in-application
variable "application_name" { default = "cloudnative-2021App"}
data "oci_functions_applications" "function_applications" {
compartment_id = var.compartment_id
display_name = "${var.application_name}"
}
data "oci_functions_functions" "application_functions" {
application_id = data.oci_functions_applications.function_applications.applications[0].id
}