Skip to content

Instantly share code, notes, and snippets.

View rcbop's full-sized avatar

Rogerio Peixoto rcbop

  • Spain
View GitHub Profile
@SayantanRC
SayantanRC / jellyfin-samsung.md
Last active May 30, 2025 19:32
Sign Jellyfin for Samsung TVs

Prerequisite

This guide is based on using an Ubuntu VM. The whole process will take several hours when doing for the first time. I faced issues with Windows 11, but you are free to try it. There are helpful comments below for Windows users.

Please read all the steps first before proceeding.

Steps

  1. Get ubuntu 18.04 LTS. Create a VM if needed.
  2. Install Tizen Studio from here: https://developer.tizen.org/development/tizen-studio/download
  3. Run the .bin file from terminal

############################################################################################################ ################## ############################# ################## #############################

              This Gist collection contains all localstack related examples

################## ############################# ################## ############################# ############################################################################################################

@PurpleBooth
PurpleBooth / 1password
Last active February 2, 2025 20:51
Use sops to cache the one password vault session token because op is horrible to use
#!/usr/bin/env bash
set -euo pipefail
CACHE_DIR="${XDG_CACHE_HOME:-$HOME/Library/Caches}/wrapper-1password"
CACHE_FILE="$CACHE_DIR/session-token.yaml"
OP_LOCATION="$(command -v op)"
mkdir -p "$CACHE_DIR"
@hermanbanken
hermanbanken / Dockerfile
Last active May 22, 2025 06:20
Compiling NGINX module as dynamic module for use in docker
FROM nginx:alpine AS builder
# nginx:alpine contains NGINX_VERSION environment variable, like so:
# ENV NGINX_VERSION 1.15.0
# Our NCHAN version
ENV NCHAN_VERSION 1.1.15
# Download sources
RUN wget "http://nginx.org/download/nginx-${NGINX_VERSION}.tar.gz" -O nginx.tar.gz && \
@RobertoSchneiders
RobertoSchneiders / elasticbeanstalk_deploy_iam_policy.md
Last active October 29, 2024 19:38
IAM Policy for deploy on Elastic Beanstalk

I am deploying with this IAM using Codeship and Circle CI to Elastic Beanstalk. I had a lot of trouble with this config. I talked to the aws support for about 6 hours until this worked properly, so, I guess it is worth to share.

UPDATE: In the end, I have to use the AWSElasticBeanstalkFullAccess policy. My custom policy keep breaking every week with some new added permission or some EB internal change. Anyway, the IAM I was using is below.

This works for me with CircleCI and EB Cli.

{
    "Version": "2012-10-17",
    "Statement": [
        {
@ianblenke
ianblenke / prune_eb_versions.sh
Last active March 8, 2019 16:46
Delete any ElasticBeanstalk application versions older than a week old that are not currently in use by an environment.
awsargs="--profile aws-dev --region us-east-1"
now=$(date -j -f "%a %b %d %T %Z %Y" "$(date)" "+%s" 2>/dev/null);
oneweekago=$(expr $now - 604800);
aws elasticbeanstalk describe-application-versions $awsargs | \
jq -r '.ApplicationVersions[] | .ApplicationName + " " + .VersionLabel + " " + .DateCreated'| \
while read line ; do
fields=( $line )
utime=$(date -j -f %Y-%m-%dT%H:%M:%S "${fields[2]};" "+%s" 2>/dev/null);
if [[ $utime -lt $oneweekago ]]; then
if [ -n "$(aws elasticbeanstalk describe-environments $awsargs \
@rbanks74
rbanks74 / ebs-snapshot.sh
Created May 1, 2015 17:24
Copy of CaseyLabs/aws-ec2-ebs-automatic-snapshot-bash
#!/bin/bash
export PATH=$PATH:/usr/local/bin/:/usr/bin
# Safety feature: exit script if error is returned, or if variables not set.
# Exit if a pipeline results in an error.
set -ue
set -o pipefail
## Automatic EBS Volume Snapshot Creation & Clean-Up Script