Skip to content

Instantly share code, notes, and snippets.

View realms-ai's full-sized avatar

Realms AI realms-ai

View GitHub Profile
@realms-ai
realms-ai / docker-cache-cloudtrain.md
Created July 5, 2023 15:19
Docker Cloudtrain Demo to cache the builds.

Docker with Cache Management

FROM --platform=linux/arm64 node:12-alpine
WORKDIR /app
COPY . .
RUN npm install --omit=dev
EXPOSE 3000
CMD["node", "start"]
@realms-ai
realms-ai / kafka-confluent.md
Created June 28, 2023 04:19
Kafka Confluent Basic Info

Kafka (Confluent)

  • Code: KAFKA101 (promotion code)

Kafka Confluent CLI

  • Install Confluent CLI

Commands

@realms-ai
realms-ai / trading-tips.md
Created June 24, 2023 19:41
Stock Market Trading tips to improve your portfolio and profits

Trading Tips

  1. 52 weeks high - stable and strong company

    • 4-7% profit in 2-3 days
    • moneycontrol.com
      • Markets
      • Stock Action
      • tradingview.com
  2. Books

@realms-ai
realms-ai / finance-tips.md
Last active May 8, 2024 08:37
Finance Tips to increase passive income sources

Finance

Various finance tips to increase your passive income sources

  1. Finviz (Site)
    1. Select Insider
    2. Buy and Sell Information
  2. Syllaby.io (What questions people are searching for) - Generate a viral video script
    1. Stack it with Synthesia.io, and you can take the script from Syllaby, choose one of their video templates, paste the script in, and boom!
  3. And if you want to take it one step further, stack it with Repurpose.io
@realms-ai
realms-ai / google-cloud-practice.md
Created June 24, 2023 19:37
Basic Google Cloud Service knowledge

Google Cloud

1. Virtual Machines

  • Pre-emptilbe (Just like Spot instances)
  • Committed Use Discounts (Reserve Instances)

2. IAM

  • Organization
  • Folders
  • Projects
@realms-ai
realms-ai / kubernetes-practice.md
Last active June 27, 2023 22:33
Practicing kubernetes along with commands to do 80% of the tasks

Kubernetes

  • Open source container orchestration tool
  • Features
    • High Availability
    • Scalability or high performance
    • Disaster Recovery - backup and restore

K8s Architecture

@realms-ai
realms-ai / github-action.md
Created June 24, 2023 19:30
Practicing Github to enable CI/CD for the applications

Github Actions

This is a tool to automate CI/CD of projects on Github Documentation

  • File stays in .github/workflows
name: nameOfTheActionService (Java CI with Gradle)
@realms-ai
realms-ai / docker-practice.md
Created June 24, 2023 19:29
Docker Commands to write a docker file along with compose files

Docker

Creating Network

Network helps container communicate with each other via a bridge

docker network create networkName
docker run mongo --net networkName
@realms-ai
realms-ai / anyNumberSum.js
Last active June 12, 2023 08:56
This code gives you a sub-array of n-element whose sum is equal to the targetSum. TargetSum can be an array too to (In case of array, it returns the Object with targetSum as keys and value as an array of numbers whose sum is equal to the targetSum).
// num represents the no of element needed in sub-array whose total is equal to targetSum
function anyNumberSum(array, targetSum, num = 3) {
// write your code here
const hash = {} // = {'1': [], '2': [], '3': []}
let nArr = Array.from({length: num}, (v, i) => {
hash[i+1] = {}
return i + 1
})
nArr = nArr.reverse()
nArr.shift()
@realms-ai
realms-ai / github_multiple_users.md
Last active June 24, 2023 19:32
Handle Multiple Github users

Handle Multiple Github Users

# Other github account: Simer   
Host *-s           
   HostName github.com      
   IdentityFile ~/.ssh/simer    
   IdentitiesOnly yes

# Other github account: UntroddenLabs