Skip to content

Instantly share code, notes, and snippets.

View DMeechan's full-sized avatar
🧑‍🌾
Building stuff

Daniel Meechan DMeechan

🧑‍🌾
Building stuff
View GitHub Profile
@DMeechan
DMeechan / word-list.js
Last active April 21, 2025 13:15
BIP39 mnemonic phases word list (2048 words)
const WORDLIST = ["abandon","ability","able","about","above","absent","absorb","abstract","absurd","abuse",
"access","accident","account","accuse","achieve","acid","acoustic","acquire","across","act",
"action","actor","actress","actual","adapt","add","addict","address","adjust","admit",
"adult","advance","advice","aerobic","affair","afford","afraid","again","age","agent",
"agree","ahead","aim","air","airport","aisle","alarm","album","alcohol","alert",
"alien","all","alley","allow","almost","alone","alpha","already","also","alter",
"always","amateur","amazing","among","amount","amused","analyst","anchor","ancient","anger",
"angle","angry","animal","ankle","announce","annual","another","answer","antenna","antique",
"anxiety","any","apart","apology","appear","apple","approve","april","arch","arctic",
"area","arena","argue","arm","armed","armor","army","around","arrange","arrest",
@DMeechan
DMeechan / ansible-java-pre-task.yml
Last active July 27, 2018 12:55
DevOps Course Chapter 2: Ansible - Use Ansible's pre-tasks to install Java before our role installs Selenium
pre_tasks:
- name: Install Java
apt:
name: default-jre
state: present
update_cache: yes
@DMeechan
DMeechan / node-js-ibm-cloud-manifest.yml
Created July 16, 2018 13:37
Manifest file to deploy Node.js application to IBM Cloud
---
applications:
- name: devops-todo-1-or-whatever-you-chose
memory: 128M
buildpack: sdk-for-nodejs
command: npm run start
env:
OPTIMIZE_MEMORY: true
@DMeechan
DMeechan / ansible-roles.yml
Last active July 25, 2018 15:58
DevOps Course Chapter 2 - Ansible
roles:
- arknoll.selenium
@DMeechan
DMeechan / ansible-selenium-vars.yml
Created July 3, 2018 15:24
DevOps Course Chapter 2 - Ansible
selenium_install_firefox: yes
selenium_install_chrome: no
selenium_version: 3.12.0
@DMeechan
DMeechan / playbook-example.yml
Last active July 3, 2018 14:39
DevOps Course Chapter 2 - Ansible
---
- hosts: mygroup
tasks:
- name: Installs Git version control
apt:
name: git
state: present
update-cache: true
- name: Installs GoAccess
apt:
@DMeechan
DMeechan / ibm-cloud-run-automated-selenium-tests.sh
Last active June 19, 2018 13:40
DevOps Course Chapter 9 - integrating our automated tests into our delivery pipeline
#!/bin/bash
# This script is run on IBM Cloud in the delivery pipeline
# It enables a Test stage to run automated Selenium tests
# In Firefox using a virtual display
echo "==> Updating all dependencies"
sudo apt-get -y --force-yes update
echo "==> Installing Firefox"
sudo apt-get -y --force-yes install firefox
firefox -v
@DMeechan
DMeechan / mocha-first-test-case-full.js
Last active June 19, 2018 12:22
DevOps Course Chapter 8 - Automated testing
// This collection of test cases will be testing the title of the page
describe('title', function() {
const driver = getDriver();
// Before every test runs, we'll need to open up the web page in Firefox
beforeEach(openWebsite(driver));
// ▼ Write the test case for the page title below here ▼
it('is correct', async function() {
@DMeechan
DMeechan / ibm-cloud-deploy.sh
Created June 19, 2018 08:41
DevOps Course Chapter 7 - Automating our deployments
#!/bin/bash
cf push -f ./manifest.yml
export APP_URL=http://$(cf app $CF_APP_NAME | grep -e urls: -e routes: | awk '{print $2}')
@DMeechan
DMeechan / mocha-complete-test-cases.js
Created June 18, 2018 15:18
DevOps Course Chapter 8 - Automated testing
describe('tasks', function() {
const driver = getDriver();
beforeEach(openWebsite(driver));
// ▼ Write the test case for the tasks list below here ▼
it('lists four tasks', async function() {
try {
const list = await driver.findElements(By.tagName("li"));
list.length.should.equal(4);
} catch (error) {