Skip to content

Instantly share code, notes, and snippets.

View channainfo's full-sized avatar
🎯
Focusing

Channa Ly channainfo

🎯
Focusing
  • InSTEDD, SureSwift Capital, BookMeBus, VTENH, Onthegosystems
  • Phnom Penh
  • X @channaly
  • LinkedIn in/channaly
View GitHub Profile
@channainfo
channainfo / app.DockerFile
Created January 23, 2023 07:28 — forked from satendra02/app.DockerFile
docker+rails+puma+nginx+postgres (Production ready)
FROM ruby:2.3.1
# Install dependencies
RUN apt-get update -qq && apt-get install -y build-essential libpq-dev nodejs
# Set an environment variable where the Rails app is installed to inside of Docker image:
ENV RAILS_ROOT /var/www/app_name
RUN mkdir -p $RAILS_ROOT
# Set working directory, where the commands will be ran:
curl -XPUT localhost:9200/test
curl -XPUT http://localhost:9200/test/data/_mapping -d '{
"data" : {
"dynamic_templates" : [
{
"string_template" : {
"match" : "*",
"match_mapping_type" : "string",
"mapping" : {
@channainfo
channainfo / config.conf
Created September 23, 2021 11:14 — forked from gcsfred/config.conf
Sample integration between Elasticsearch and Amazon Personalize - entire file
[DEFAULT]
product_ranking_start = 10
product_ranking_steps_down = 0.2
cat_ranking_start = 10
cat_ranking_steps_down = 0.2
product_recommendations_campaignArn=arn:aws:personalize:us-east-2:11123456:campaign/es-test03-hrnn
product_rankings_campaignArn=arn:aws:personalize:us-east-2:222789:campaign/es-test03-rank
property1_recommendations_campaignArn=arn:aws:personalize:us-east-2:3333456:campaign/es-test03-cat-hrnn
property1_rankings_campaignArn=arn:aws:personalize:us-east-2:444789:campaign/es-test03-cat-rank
@channainfo
channainfo / .dockerignore
Created May 29, 2021 08:50 — forked from davidderus/.dockerignore
Docker + Rails + Puma + Postgres + Nginx
.git
.gitignore
/doc
.yardoc
coverage
jsdoc
/tmp
/log
Dockerfile
Dockerfile.prod
@channainfo
channainfo / install_ffmpeg_ubuntu.sh
Created March 27, 2019 07:33 — forked from dalmatele/install_ffmpeg_ubuntu.sh
Install latest ffmpeg on ubuntu 12.04 or 14.04, 16.04
#!/bin/bash
# Bash script to install latest version of ffmpeg and its dependencies on Ubuntu 12.04 or 14.04
# Inspired from https://gist.github.com/faleev/3435377
# Remove any existing packages:
sudo apt-get -y remove ffmpeg x264 libav-tools libvpx-dev libx264-dev
# Get the dependencies (Ubuntu Server or headless users):
sudo apt-get update
@channainfo
channainfo / .gitconfig
Created September 30, 2015 02:21 — forked from pksunkara/config
Sample of git config file (Example .gitconfig)
[user]
name = Pavan Kumar Sunkara
email = [email protected]
[core]
editor = vim
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol
excludesfile = ~/.gitignore
[sendemail]
smtpencryption = tls
smtpserver = smtp.gmail.com