Skip to content

Instantly share code, notes, and snippets.

View helms-charity's full-sized avatar

Charity Helms helms-charity

View GitHub Profile
@markshust
markshust / hosts
Last active February 12, 2021 22:20
Notion DNS servers in the event of an outage...
# Add the following records to your DNS config
## Mac: /etc/hosts
## Windows: C:\Windows\System32\drivers\etc\hosts
104.18.23.110 admin-stg.notion.so
104.18.23.110 aif.notion.so
104.18.23.110 analytics-iframe.notion.so
104.18.23.110 analytics.pgncs.notion.so
104.18.23.110 api.notion.so
104.18.23.110 api.pgncs.notion.so
104.18.23.110 dev.notion.so
@jayankandathil
jayankandathil / CollectAWSEC2CloudWatchData.ps1
Created July 19, 2018 21:42
Collect CloudWatch metrics for an EC2 instance in AWS using PowerShell
# Author : Jayan Kandathil (Adobe Managed Services)
# Date : July 19, 2018
# https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_GetMetricStatistics.html
# https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/ec2-metricscollected.html
# https://aws.amazon.com/blogs/developer/writing-and-archiving-custom-metrics-using-amazon-cloudwatch-and-aws-tools-for-powershell/
# Get authentication credentials
Set-AWSCredential -AccessKey YOURAWSACCESSKEY -SecretKey yOUR354aws39875358sECRET93453-96kEY -SessionToken yOURawssESSIONtOKENEaDKGld+XcXoR/yOUtHINKtHISiSreAL2XD1k9tgQ/TKIjhXXTXxM
# Set Test Start Time and Test End Time (remember to adjust for your time zone - CloudWatch data is in UTC)
@jayankandathil
jayankandathil / CollectAWSEBSCloudWatchData.ps1
Created July 19, 2018 18:53
Collect CloudWatch metrics for an EBS volume in AWS using PowerShell
# Author : Jayan Kandathil (Adobe Managed Services)
# Date : July 19, 2018
# https://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_GetMetricStatistics.html
# https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/rds-metricscollected.html
# https://aws.amazon.com/blogs/developer/writing-and-archiving-custom-metrics-using-amazon-cloudwatch-and-aws-tools-for-powershell/
# Get authentication credentials
Set-AWSCredential -AccessKey YOURAWSACCESSKEY -SecretKey yOUR354aws39875358sECRET93453-96kEY -SessionToken yOURawssESSIONtOKENEaDKGld+XcXoR/yOUtHINKtHISiSreAL2XD1k9tgQ/TKIjhXXTXxM
# Set Test Start Time and Test End Time (remember to adjust for your time zone - CloudWatch data is in UTC)
@Artistan
Artistan / A Readme for Adding Certs.md
Last active March 11, 2024 21:12
Add new certificate (cert) from local/internal intranet to your mac

Add a cert to you macbook

USAGE

~/add_cert.sh my.intra.net

you will be asked for your password to add thit to keychain

  • downloads pem file
  • adds to trusted root certificates
@jayankandathil
jayankandathil / SlingJMXAllQueues.groovy
Last active August 4, 2022 10:41
Groovy script that prints out JMX Metrics for [Adobe Experience Manager] [Apache Sling] [AllQueues]
// Author : Jayan Kandathil
// Last Updated : May 19, 2017
// Version : 0.1
import java.lang.management.*
import javax.management.ObjectName
import javax.management.remote.JMXConnectorFactory as JmxFactory
import javax.management.remote.JMXServiceURL as JmxUrl
import java.text.DecimalFormat;
@warking
warking / install_linuxbrew_on_centos7.sh
Last active August 19, 2023 19:26
standalone linuxbrew setup script for CentOS 7
# Non-root account is recommended for this process
# centos-specific prepration
sudo yum -y update && sudo yum -y groupinstall 'Development Tools' && sudo yum -y install curl irb m4 ruby
# Sanitize the environment
PATH=~/.linuxbrew/bin:/usr/local/bin:/usr/bin:/bin
unset LD_LIBRARY_PATH PKG_CONFIG_PATH
# install linuxbrew
anonymous
anonymous / config.json
Created October 23, 2014 02:03
Bootstrap Customizer Config
{
"vars": {
"@gray-darker": "lighten(#000, 13.5%)",
"@gray-dark": "lighten(#000, 20%)",
"@gray": "lighten(#000, 33.5%)",
"@gray-light": "lighten(#000, 46.7%)",
"@gray-lighter": "lighten(#000, 93.5%)",
"@brand-primary": "#428bca",
"@brand-success": "#5cb85c",
"@brand-info": "#5bc0de",
@floriankraft
floriankraft / JcrQueryLibrary.md
Last active May 3, 2024 05:50
Some useful JCR queries (XPATH, SQL2) for AEM/CQ development.

SQL2

All nodes with a specific name

SELECT * FROM [nt:unstructured] AS node
WHERE ISDESCENDANTNODE(node, "/search/in/path")
AND NAME() = "nodeName"

All pages below content path

@jayankandathil
jayankandathil / start.sh
Last active February 9, 2017 02:06
Production-quality start script for CQ 5.6.1 (Adobe Experience Manager) with JVM heap and garbage collection tuning - assumes the use of a 1.7 Oracle "HotSpot" JDK
#!/bin/bash
#
# This script configures the start information for this server.
#
# The following variables may be used to override the defaults.
# For one-time overrides the variable can be set as part of the command-line; e.g.,
#
# % CQ_PORT=1234 ./start
#
@kand
kand / Custom Sidekick Dialog in CQ5
Last active December 1, 2017 06:28
Add a custom dialog as an option in the sidekick. customSidekickDialog.js will add another action to the DEFAULT_ACTIONS list for the sidekick. In this example, the action will open a dialog but, in practice, you could put any action you wanted in the handler. launchSidekick.js is Javascript that should replace the Javascript in your project tha…
Set up your file structure something like this:
/apps/your-site/components/page
-> yourPage
-> clientlibs
-> js
-> customSidekickDialog.js
-> .content.xml
-> js.txt
-> customDialog.xml