This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* List of locales supported by Facebook. | |
* | |
* These are the same supported locales that you can only call when loading the FB JS SDK at | |
* //connect.facebook.net/{LOCALE_ID}/all.js | |
* | |
* Locales taken from http://www.facebook.com/translations/FacebookLocales.xml | |
* | |
* Last Updated: 04/09/2012 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
# Attempt to check if the folder exist. | |
# If it exist echo out a string. You have to echo something | |
# if the directory does exist or else the task is considered failed | |
# Output is set to $is_default_created. Note that this variable is | |
# object and not an atomic value. | |
- name: Attempt to check if a directory exist | |
action: shell test -d /my/folder && echo "exist" || echo "" | |
register: is_folder_created |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# Usage Example: | |
# ./install_ansible.sh 'v1.1' path/to/local/ansible/hosts/file | |
# Look up https://github.com/ansible/ansible for version tags to use | |
versionTag=$1 | |
ansibleHosts=$2 | |
# Install Git |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- | |
TargetName: cron:install | |
Partly based on http://codeinthehole.com/writing/deploying-cron-jobs-using-phing/ | |
@param env.name The env name | |
@env.config_path Path in project for the env configs | |
@param project.folder AKA the name of the project | |
--> | |
<target name="cron:install" description="Install Cron Job Config. Run with sudo"> | |
<property name="cron_source_path" value="${env.config_path}/system/cron.d" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- id: php-lint | |
name: PHP Syntax Check (Quick) | |
description: Runs php -l on all staged files. Exits when it hits the first | |
errored file | |
entry: php -l | |
language: system | |
files: \.php$ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- repo: http://source/to/your/hook/repo/url | |
sha: master | |
hooks: | |
- id: php-lint |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
server { | |
set $rootPath /var/www/vhosts/mysite/public; | |
listen 80; | |
server_name assets.mydomain.com; | |
root $rootPath; | |
access_log /var/log/nginx/access_assets.log; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
policies: | |
- name: ec2-auto-tag-owner | |
mode: | |
type: cloud-trail | |
events: | |
- CreateInstance | |
filters: | |
- tag:Owner: absent | |
actions: | |
- type: auto-tag-user |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(custodian) vagrant@sliong:/workspace/custodian$ custodian validate test.yml | |
2017-05-05 21:32:41,128: custodian.commands:ERROR Configuration invalid: test.yml | |
2017-05-05 21:32:41,136: custodian.commands:ERROR {'filters': [{'tag:Owner': 'absent'}], 'name': 'ec2-auto-tag-owner', 'actions': [{'tag': 'OwnerContact', 'type': 'auto-tag-user'}], 'mode': {'type': 'cloud-trail', 'events': ['CreateInstance']}} is not valid under any of the given schemas | |
Failed validating 'anyOf' in schema['properties']['policies']['items']: | |
{'anyOf': [{'$ref': '#/definitions/resources/firehose/policy'}, | |
{'$ref': '#/definitions/resources/rds-cluster-snapshot/policy'}, | |
{'$ref': '#/definitions/resources/event-rule/policy'}, | |
{'$ref': '#/definitions/resources/elb/policy'}, | |
{'$ref': '#/definitions/resources/redshift-snapshot/policy'}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
policies: | |
- name: ec2-auto-tag-owner | |
resource: ec2 | |
mode: | |
type: cloudtrail | |
events: | |
- RunInstances | |
filters: | |
- "tag:Owner": absent | |
actions: |
OlderNewer