Skip to content

Instantly share code, notes, and snippets.

Ryan Aslett ryanaslett

Block or report user

Report or block ryanaslett

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:3da4f555361b87ef3314b1ea3e7171a1
Processing core
Cloning into 'upstream-split-source'...
done.
Note: checking out '55e055c3eeb15c941f92f1db2376e9578a9ddccc'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.
If you want to create a new branch to retain commits you create, you may
View sstd3.snippet.dsl
Scope (\_TZ)
{
ThermalZone (PCT0)
{
Method (_INI, 0, NotSerialized) // _INI: Initialize
{
}
Method (_STA, 0, NotSerialized) // _STA: Status
{
View drupalci.md

Your DrupalCI Build

A guide for drupal.org project maintainers.

Note: Put this in a handbook page when it's been RTBCd.

What Is DrupalCI?

View gist:251ea67e3f0688246aa52bc9aa28441b
git clone --no-checkout '/Users/bojanz/.composer/cache/vcs/https---git.drupal.org-project-commerce-bootstrap/' 'web/themes/contrib/commerce_bootstrap' --dissociate --reference '/Users/bojanz/.composer/cache/vcs/https---git.drupal.org-project-commerce-bootstrap/' && cd 'web/themes/contrib/commerce_bootstrap' && git remote set-url origin 'https://git.drupal.org/project/commerce_bootstrap' && git remote add composer 'https://git.drupal.org/project/commerce_bootstrap'
@ryanaslett
ryanaslett / database_cloner.sh
Last active Jun 12, 2017
Fix broken replication.
View database_cloner.sh
#!/bin/bash
set +uex
#Gather some variables
PRIMARY=$(crm status --as-xml |xpath -q -e "string(/crm_mon/resources/clone/resource[@role='Master']/node/@name)" 2>/dev/null)
REPLICA=$(crm status --as-xml |xpath -q -e "string(/crm_mon/resources/clone/resource[@role='Slave']/node/@name)" 2>/dev/null)
PRIMARY_IP=$(crm status --as-xml |xpath -q -e "string(/crm_mon/node_attributes/node[@name='${PRIMARY}']/attribute[@name='p_mysql_mysql_master_IP']/@value)" 2>/dev/null)
REPLICATION_PW=$(crm configure show xml |xpath -q -e "string(/cib/configuration/resources/master/primitive/instance_attributes/nvpair[@id='p_mysql-instance_attributes-replication_passwd']/@value)" 2>/dev/null)
#disable puppet on both nodes
View gist:a53cf5c450062cab85f06fb25f7b36ec
[0x7f5a2841cfd0] basename("core/modules/system/tests/themes/test_theme_twig_registry_loader_subtheme/test_theme_twig_registry_loader_subtheme.info.yml", ".info.yml") [internal function]
[0x7f5a2841cf70] Drupal\Core\Extension\Extension->getName() /var/www/html/core/lib/Drupal/Core/Extension/Extension.php:82
[0x7f5a2841ced0] Drupal\Core\Extension\ExtensionDiscovery->process(array(41)[0x7f5a2841cf20]) /var/www/html/core/lib/Drupal/Core/Extension/ExtensionDiscovery.php:378
[0x7f5a2841cdc0] Drupal\Core\Extension\ExtensionDiscovery->scan("theme") /var/www/html/core/lib/Drupal/Core/Extension/ExtensionDiscovery.php:221
[0x7f5a2841cc20] Drupal\Core\Extension\ThemeHandler->rebuildThemeData() /var/www/html/core/lib/Drupal/Core/Extension/ThemeHandler.php:247
[0x7f5a2841cb60] Drupal\Core\Extension\ThemeHandler->refreshInfo() /var/www/html/core/lib/Drupal/Core/Extension/ThemeHandler.php:225
[0x7f5a2841cad0] Drupal\Core\Extension\ThemeHandler->listInfo() /var/www/html/core/lib/Drupal/Core/Extension/ThemeHandler.php:186
[0x7
View gist:db7a02034bb5bf0fb6f6f396fae2a0ea
[0x7fa4d8bdf870] basename("core/modules/system/tests/themes/test_invalid_basetheme_sub/test_invalid_basetheme_sub.info.yml", ".info.yml") [internal function]
[0x7fa4d8bdf810] Drupal\Core\Extension\Extension->getName() /var/www/html/core/lib/Drupal/Core/Extension/Extension.php:82
[0x7fa4d8bdf770] Drupal\Core\Extension\ExtensionDiscovery->process(array(41)[0x7fa4d8bdf7c0]) /var/www/html/core/lib/Drupal/Core/Extension/ExtensionDiscovery.php:378
[0x7fa4d8bdf660] Drupal\Core\Extension\ExtensionDiscovery->scan("theme") /var/www/html/core/lib/Drupal/Core/Extension/ExtensionDiscovery.php:221
[0x7fa4d8bdf4c0] Drupal\Core\Extension\ThemeHandler->rebuildThemeData() /var/www/html/core/lib/Drupal/Core/Extension/ThemeHandler.php:247
[0x7fa4d8bdf400] Drupal\Core\Extension\ThemeHandler->refreshInfo() /var/www/html/core/lib/Drupal/Core/Extension/ThemeHandler.php:225
[0x7fa4d8bdf370] Drupal\Core\Extension\ThemeHandler->listInfo() /var/www/html/core/lib/Drupal/Core/Extension/ThemeHandler.php:186
[0x7fa4d8bdf2b0] Drupal\Core\Ext
@ryanaslett
ryanaslett / Docker Builds
Created Feb 12, 2017
output of our latest drupalci docker builds.
View Docker Builds
This file has been truncated, but you can view the full file.
Started by an SCM change
Building remotely on build1 in workspace /home/bender/jenkins/workspace/drupalci_build_containers
> git rev-parse --is-inside-work-tree # timeout=10
Fetching changes from the remote Git repository
> git config remote.origin.url git://git.drupal.org/project/drupalci_environments.git # timeout=10
Fetching upstream changes from git://git.drupal.org/project/drupalci_environments.git
> git --version # timeout=10
> git fetch --tags --progress git://git.drupal.org/project/drupalci_environments.git +refs/heads/*:refs/remotes/origin/*
Seen branch in repository origin/2609560-Base-DCI-containers-off-official-containers
View gist:6f7f773c94bf34c7f7ec5b163e08b00c
postgres=# select * from pg_statio_all_tables where relname in ('pg_class','pg_type');
relid | schemaname | relname | heap_blks_read | heap_blks_hit | idx_blks_read | idx_blks_hit | toast_blks_read | toast_blks_hit | tidx_blks_read | tidx_blks_hit
-------+------------+----------+----------------+---------------+---------------+--------------+-----------------+----------------+----------------+---------------
1247 | pg_catalog | pg_type | 8 | 58 | 13 | 65 | | | |
1259 | pg_catalog | pg_class | 114 | 742 | 30 | 611 | | | |
(2 rows)
View gist:6bcc723284ffd9f5a29ab86c9f3d0a35
postgres=# select * from pg_class where pg_relation_filenode(oid) = 11685;
WARNING: terminal is not fully functional
relname | relnamespace | reltype | reloftype | relowner | relam | relfilenode | reltablespace | relpages | reltuples | reltoastrelid | reltoastidxid | relhasindex | relisshared | relpersistence | relkind | relnatts | relchecks | relhasoids
| relhaspkey | relhasrules | relhastriggers | relhassubclass | relfrozenxid | relacl | reloptions
----------+--------------+---------+-----------+----------+-------+-------------+---------------+----------+-----------+---------------+---------------+-------------+-------------+----------------+---------+----------+-----------+------------
+------------+-------------+----------------+----------------+--------------+---------------+------------
pg_class | 11 | 83 | 0 | 10 | 0 | 0 | 0 | 8 | 281 | 0 | 0 | t | f | p | r |
You can’t perform that action at this time.