Skip to content

Instantly share code, notes, and snippets.

View vvondra's full-sized avatar
🕺

Vojtěch Vondra vvondra

🕺
View GitHub Profile
@RobertoSchneiders
RobertoSchneiders / elasticbeanstalk_deploy_iam_policy.md
Last active May 28, 2024 23:07
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": [
        {
@rarous
rarous / orig.clj
Last active November 27, 2017 09:38
Refactoring of Tic-Tac-Toe in Clojure
(ns piskvorky.core
(:require [clojure.string :as s])
(:gen-class))
(defn usage []
(println "Ahoj v piskvorkach naslepo.\nPovolene prikazy jsou:\nnew - nova hra\nquit - konec\n[a-i][0-9] - tah na pole, kde rada je pozice a, b, c, d, e, f, g, h, i. Sloupec je 1 ... az 9.\nformat zapisu je napr. e5\nZacina x"))
(defn make-board []
(vec (repeat 9 (vec (repeat 9 :nothing)))))
# The version number for this release
$versionNumber = $Env:APPVEYOR_BUILD_VERSION
# The Commit SHA for corresponding to this release
$commitId = $Env:APPVEYOR_REPO_COMMIT
# The notes to accompany this release, uses the commit message in this case
$releaseNotes = $Env:APPVEYOR_REPO_COMMIT_MESSAGE
# The folder artifacts are built to
$artifactOutputDirectory = $Env:APPVEYOR_BUILD_FOLDER
# The name of the file to attach to this release
$artifact = 'xunit-build-runner.zip'
@s7anley
s7anley / pre-commit-php-cs-fixer.sh
Last active August 29, 2015 14:05
Pre commit php-cs-fixer
#!/bin/bash
PROJECTROOT="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )/"
FIXER=php-cs-fixer.phar
if [ ! -e ${PROJECTROOT}${FIXER} ]; then
echo "PHP-CS-Fixer not available, downloading to ${PROJECTROOT}${FIXER}..."
curl -s http://cs.sensiolabs.org/get/$FIXER > ${PROJECTROOT}${FIXER}
echo ""
fi
@wookiecooking
wookiecooking / aliases.sh
Created November 30, 2013 00:52
[Shell] Assortment of OSX influenced bash aliases and functions
# Rails Stuff
alias stoprails='kill -9 $(lsof -i :3000 -t)'
alias startrails='rails server -d'
alias restartrails='stopRails && startRails'
#Check PHP For Erroes
alias phpcheck='find ./ -name \*.php | xargs -n 1 php -l'
# ROT13-encode text. Works for decoding, too! ;)
alias rot13='tr a-zA-Z n-za-mN-ZA-M'
@nessthehero
nessthehero / README.md
Last active March 27, 2018 14:59
JavaScript Boilerplate

JS Boilerplate

Simple boilerplate I use to start JavaScript projects.

githalytics.com alpha

@baldurrensch
baldurrensch / TimeReportingTestListener.php
Created December 19, 2012 17:53
A PHP Unit Listener that records individual test time runs and can print out warnings if a test is slower then some critical threshold
<?php
namespace Hautelook\ApiBundle\Tests;
use PHPUnit_Framework_TestListener;
use PHPUnit_Framework_Test;
use PHPUnit_Framework_TestSuite;
use PHPUnit_Framework_AssertionFailedError;
use Exception;