Skip to content

Instantly share code, notes, and snippets.

View martinreus's full-sized avatar
💻

Martin Reus martinreus

💻
View GitHub Profile
@martinreus
martinreus / ollama.service
Created February 10, 2025 19:25
expose ollama server to the world
´´´bash
sudo systemctl edit ollama.service
´´´
with
```
[Service]
@martinreus
martinreus / launch.json
Created December 16, 2024 07:24
Launch cypress tests VSCode - current open file
{
// needs cypress npm package installed
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "launch",
"name": "Launch e2e tests",
"skipFiles": ["<node_internals>/**"],
"program": "${workspaceFolder}/node_modules/.bin/cypress",
@martinreus
martinreus / opensearch_IAM_signed_req.ts
Created November 26, 2024 17:05
Create a signed request against opensearch using IAM creds
import { defaultProvider } from "@aws-sdk/credential-provider-node";
import {SignatureV4} from "@aws-sdk/signature-v4"
import { Sha256 } from "@aws-crypto/sha256-js";
import { HttpRequest } from '@aws-sdk/protocol-http'; // For structuring the HTTP request
export const doOpenSearchStuff = async () => {
// Use the AWS SigV4 signer to sign the HTTP request
const signer = new SignatureV4({
@martinreus
martinreus / launch.json
Last active September 26, 2025 09:45
launch.json configuration for debugging currently opened typescript file in vscode
{
"version": "0.2.0",
"configurations": [
{
"name": "Launch TypeScript File",
"type": "node",
"request": "launch",
"skipFiles": ["<node_internals>/**"],
"program": "${file}",
"runtimeArgs": ["-r", "ts-node/register"],