Skip to content

Instantly share code, notes, and snippets.

View brodeynewman's full-sized avatar
🧠
Learning

mnesia brodeynewman

🧠
Learning
  • WhiteFiber
View GitHub Profile
@brodeynewman
brodeynewman / ipmi-enable.sh
Created January 29, 2025 18:10
Dell x86 ipmi enable via Redfish
#!/bin/bash
USERNAME="admin"
PASSWORD="pass"
IP_RANGE=(10.10.5.{1..36})
for IP in "${IP_RANGE[@]}"; do
echo "Enabling IPMI on $IP..."
curl -u "$USERNAME:$PASSWORD" -k --location --request PATCH "https://$IP/redfish/v1/Managers/iDRAC.Embedded.1/NetworkProtocol/" \
@brodeynewman
brodeynewman / ethernets.sh
Last active January 29, 2025 18:11
Get ethernet info from redfish API
#!/bin/bash
IPMI_PASS="pass"
USERNAME="user"
PORT="623"
VERIFY_CA="False"
IP_RANGE=(10.10.5.{1..36})
OUTPUT_FILE="mac_mapping.json"
@brodeynewman
brodeynewman / changelog.md
Last active December 18, 2021 16:30
Changelog

Changelog!

All notable changes to this project will be documented in this file...

The format is based on Keep a Changelog and this project adheres to Semantic Versioning.

[1.3.2] - 2021-12-20

One more!

@brodeynewman
brodeynewman / ecs.tf
Last active January 4, 2021 22:37
tf ecs
provider "aws" {
region = var.region
}
data "aws_iam_role" "ecr" {
name = "AWSServiceRoleForECRReplication"
}
module "label" {
source = "git::https://github.com/cloudposse/terraform-null-label.git?ref=master"
@brodeynewman
brodeynewman / gist:2af5c36963661281479b24537daa19fc
Created September 7, 2020 17:13
S3 Static hosting bucket policy
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "PublicReadGetObject",
"Effect": "Allow",
"Principal": "*",
"Action": [
"s3:GetObject"
],
RewriteEngine On
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} -f [OR]
RewriteCond %{DOCUMENT_ROOT}%{REQUEST_URI} -d
RewriteRule ^ - [L]
RewriteRule ^ /index.html [L]
@brodeynewman
brodeynewman / gist:fbccd68edbd07c7ff31fbe8f2a752453
Created March 23, 2017 18:26
React Native Navigation Component
import React, { Component } from 'react';
import {
Text,
View,
TouchableOpacity
} from 'react-native';
export default class Nav extends Component {
constructor(props) {
super(props)
@brodeynewman
brodeynewman / Atom: React Native Component Snippet
Last active March 2, 2017 16:42
Copy this into your Atom snippets
'.source.js':
'React Native Component':
'prefix': 'rnc'
'body': """
import React, { Component } from 'react';
import {
StyleSheet,
Text,
View,
@brodeynewman
brodeynewman / React.js Animation Toggle
Last active May 29, 2017 16:00
Optimal animation toggling with react.
import React, { Component } from 'react';
class Toggle extends Component {
constructor() {
super()
this.state = {
collapsed: true
};
}