This file contains hidden or 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
#!/bin/bash | |
set -e | |
SERVICE_NAME=$1; shift | |
DOCKER_CMD=docker | |
TASK_ID=$(${DOCKER_CMD} service ps --filter 'desired-state=running' $SERVICE_NAME -q) | |
NODE_ID=$(${DOCKER_CMD} inspect --format '{{ .NodeID }}' $TASK_ID) | |
CONTAINER_ID=$(${DOCKER_CMD} inspect --format '{{ .Status.ContainerStatus.ContainerID }}' $TASK_ID) | |
TASK_NAME=swarm_exec_${RANDOM} |
This file contains hidden or 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
blueprint: | |
name: Group Sonos on Motion | |
description: > | |
# Group Sonos on Motion | |
**Version: 1.0** | |
Group a Sonos device to a main device when presence (e.g. motion) is detected and the main device is playing music. | |
Can be extended with custom conditions, for example, only group the Sonos when you're not asleep. | |
This file contains hidden or 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
```bash | |
echo "" /var/log/auth.log - Clear auth.log file | |
echo '''' -/.bash history - Clear current user bash history | |
rrn -/.bash histor/ -rf - Delete .bash_history file | |
history -c - Clear current session history | |
export HISTFILESIZE=O - Set history max lines to 0 | |
export HISTSIZE=O - Set history max commands to 0 | |
unset HISTFILE - Disable history logging (need to logout to take effect) | |
kill -9 $$ - Kills current session |
This file contains hidden or 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
import boto3 | |
import sys | |
import csv | |
import ipaddress | |
def describe_regions(session): | |
try: | |
aws_regions = [] | |
ec2_client = session.client('ec2') | |
response_regions = ec2_client.describe_regions()['Regions'] |
This file contains hidden or 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
<?xml version="1.0" encoding="UTF-8"?> | |
<!-- TODO set checkForUnintentionallyCoveredCode="true" once https://www.drupal.org/node/2626832 is resolved. --> | |
<!-- PHPUnit expects functional tests to be run with either a privileged user | |
or your current system user. See core/tests/README.md and | |
https://www.drupal.org/node/2116263 for details. | |
--> | |
<phpunit bootstrap="tests/bootstrap.php" colors="true" | |
beStrictAboutTestsThatDoNotTestAnything="true" | |
beStrictAboutOutputDuringTests="true" |
This file contains hidden or 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
Date: 2015-05-20 - Wednesday - 9:36am PST - This readme was ported from a [google docs collaborative draft](https://docs.google.com/document/d/1SwH_y4kZyMa_8FlucGOaEdGzFBGp2wB3pAgoLsWEs8s/edit#). | |
# DrupalCI Testbot | |
--- | |
#### Contents | |
`Ctrl-f` for these topic headings or use a markdown renderer to use them as anchor links. | |
- [Project Synopsis](#synopsis) | |
- [What are we doing here?](#what) |
This file contains hidden or 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
diff --git a/core/scripts/run-tests.sh b/core/scripts/run-tests.sh | |
index df61328..72df950 100755 | |
--- a/core/scripts/run-tests.sh | |
+++ b/core/scripts/run-tests.sh | |
@@ -19,6 +19,10 @@ | |
$autoloader = require_once __DIR__ . '/../../autoload.php'; | |
+$path = getenv('HOME') . '/.composer/vendor/legovaer/phpcov-runner/lib'; | |
+set_include_path(get_include_path() . PATH_SEPARATOR . $path); |
This file contains hidden or 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
diff --git a/core/scripts/run-tests.sh b/core/scripts/run-tests.sh | |
index df61328..72df950 100755 | |
--- a/core/scripts/run-tests.sh | |
+++ b/core/scripts/run-tests.sh | |
@@ -19,6 +19,10 @@ | |
$autoloader = require_once __DIR__ . '/../../autoload.php'; | |
+$path = getenv('HOME') . '/.composer/vendor/legovaer/phpcov-runner/lib'; | |
+set_include_path(get_include_path() . PATH_SEPARATOR . $path); |
This file contains hidden or 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
diff --git a/scripts/run-tests.sh b/scripts/run-tests.sh | |
index 30b3aab..02bd2a9 100755 | |
--- a/scripts/run-tests.sh | |
+++ b/scripts/run-tests.sh | |
@@ -12,6 +12,10 @@ define('SIMPLETEST_SCRIPT_EXIT_SUCCESS', 0); | |
define('SIMPLETEST_SCRIPT_EXIT_FAILURE', 1); | |
define('SIMPLETEST_SCRIPT_EXIT_EXCEPTION', 2); | |
+$path = getenv('HOME') . '/.composer/vendor/legovaer/phpcov-runner/lib'; | |
+set_include_path(get_include_path() . PATH_SEPARATOR . $path); |
This file contains hidden or 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
diff --git a/core/scripts/run-tests.sh b/core/scripts/run-tests.sh | |
index df61328..2b18c3e 100755 | |
--- a/core/scripts/run-tests.sh | |
+++ b/core/scripts/run-tests.sh | |
@@ -17,6 +17,10 @@ | |
use Drupal\simpletest\TestDiscovery; | |
use Symfony\Component\HttpFoundation\Request; | |
+$path = __DIR__ . "/../vendor/phpunit/phpcov/src/lib"; | |
+set_include_path(get_include_path() . PATH_SEPARATOR . $path); |
NewerOlder