<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Warner Bell</title>
    <description>The latest articles on DEV Community by Warner Bell (@warnerbell).</description>
    <link>https://dev.to/warnerbell</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F918089%2F047b6477-420f-42c1-9829-59e881851127.png</url>
      <title>DEV Community: Warner Bell</title>
      <link>https://dev.to/warnerbell</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/warnerbell"/>
    <language>en</language>
    <item>
      <title>I Found an LLM Weakness. Fixing It Cut My Token Usage 50%.</title>
      <dc:creator>Warner Bell</dc:creator>
      <pubDate>Sat, 03 Jan 2026 13:47:53 +0000</pubDate>
      <link>https://dev.to/warnerbell/i-found-an-llm-weakness-fixing-it-cut-my-token-usage-50-58i6</link>
      <guid>https://dev.to/warnerbell/i-found-an-llm-weakness-fixing-it-cut-my-token-usage-50-58i6</guid>
      <description>&lt;h1&gt;
  
  
  I Found an LLM Weakness. Fixing It Cut My Token Usage 50%.
&lt;/h1&gt;

&lt;p&gt;I hit this wall while building a personalized AI assistant I named Nathaniel. The prompt grew to over 1,000 lines: behavioral frameworks, crisis protocols, specialized knowledge, and operational procedures. It looked like it was working beautifully, until I began to notice particular instructions or directives were not being followed, despite consuming ~3,000 tokens before the conversation even started. After some digging and testing, I discovered the issue: for very long prompts, the model wasn't reliably processing content later in the document. Whether due to attention limitations, chunked file reading, or premature response generation, the effect was the same: instructions buried deep in the prompt were being missed.&lt;/p&gt;

&lt;p&gt;The fix: put a Table of Contents at the top. When the model hits the TOC first, it has a reference map before it starts processing. It knows what sections exist and where to find them. Instead of hoping the model reaches the relevant instructions before responding, the TOC tells it exactly where to look. Loading only the relevant sections means those instructions are no longer buried deep, they're front and center. This also provided the ability to point the model directly at a particular section by name: "Use your writing protocol to enhance the following draft."&lt;/p&gt;

&lt;p&gt;Other practitioners handle large prompts by splitting into multiple documents with routing logic, or building multi-prompt orchestration layers. Those work, but add deployment complexity. I wanted one document that the model could actually navigate, a way to prevent it from responding prematurely after the first chunk, or deprioritizing instructions buried later in the context.&lt;/p&gt;

&lt;p&gt;This approach works in consumer interfaces like ChatGPT and Claude, but shows the most promise in agents and IDE-based assistants, environments where you control the system prompt and can apply context engineering practices with attached data files.&lt;/p&gt;

&lt;p&gt;The traditional solutions all felt like compromises:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Split into multiple documents&lt;/strong&gt;: Dependency management and deployment complexity&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Load everything every time&lt;/strong&gt;: Inefficient and slow&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Create a simplified version&lt;/strong&gt;: Lose the comprehensive capability that made it valuable&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  The Mechanics
&lt;/h2&gt;

&lt;p&gt;LLMs have a finite window when reading and parsing files. For very long one-shot prompts, this means chunking: the model reads the first chunk, processes it, moves to the next. The problem: the model often hits the first chunk and attempts to respond immediately, missing critical directives laid out later.&lt;/p&gt;

&lt;p&gt;The TOC changes this dynamic. When the model hits the TOC first, it has a reference map before it starts processing. Instead of deciding what to use from three massive chunks (and probably getting it wrong), it can load the entire context set that actually matters for the request.&lt;/p&gt;

&lt;p&gt;The benefits cascade:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Smarter search&lt;/strong&gt;: The model knows where to look before it starts looking&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Token savings&lt;/strong&gt;: Load only relevant sections instead of everything&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Full context&lt;/strong&gt;: Room for the complete context that matters, not truncated chunks&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Speed&lt;/strong&gt;: Faster processing by eliminating unnecessary content&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I called it &lt;strong&gt;TOC-Based Dynamic Loading&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;The initial implementation used line numbers to identify section boundaries. That broke immediately. Any edit to the document shifted all downstream line numbers. For a living prompt document that evolves constantly, line numbers were a maintenance nightmare.&lt;/p&gt;

&lt;p&gt;The solution: HTML comment markers as anchors. Insert &lt;code&gt;&amp;lt;!-- #section-name --&amp;gt;&lt;/code&gt; at each section boundary. These markers are invisible to the LLM's output but serve as stable reference points. When you edit content within a section, the anchors don't move. The routing table maps keywords to anchor names, not line numbers. The pattern became maintainable.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;💡 &lt;strong&gt;Key insight&lt;/strong&gt;: Anchors survive content edits. Line numbers don't. For living documents, this is everything.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;After weeks of refinement, production validation confirmed consistent results:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Metric&lt;/th&gt;
&lt;th&gt;Result&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Token reduction&lt;/td&gt;
&lt;td&gt;44-63% per interaction&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Processing speed&lt;/td&gt;
&lt;td&gt;30-40% faster&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Targeted loading rate&lt;/td&gt;
&lt;td&gt;82% of requests&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Fallback rate&lt;/td&gt;
&lt;td&gt;18% (under 20% target)&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Note: Fallback rate depends on keyword mapping granularity. Tighter mappings yield lower fallback rates.&lt;/p&gt;




&lt;h2&gt;
  
  
  How It Works for Personalizing Agents
&lt;/h2&gt;

&lt;p&gt;The pattern has four components:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Core Context (Always Loaded)
&lt;/h3&gt;

&lt;p&gt;The foundation every request needs: identity, behavioral constraints, quick reference. Think of it as the "personality kernel" that maintains assistant consistency.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Sizing guideline:&lt;/strong&gt; Keep core context under 25% of your total document (if including it in a one-shot doc). If it's bigger, re-evaluate what's truly "always needed."&lt;/p&gt;

&lt;p&gt;Another pattern: input core context (personality kernel) directly into agent instructions, with a pointer to an attached reference doc containing full behavioral instructions laid out in sections.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Keyword Mapping Table
&lt;/h3&gt;

&lt;p&gt;A table that maps user request keywords to document sections:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;| Keywords | Target Section | Priority |
|----------|---------------|----------|
| crisis, emergency, urgent | Crisis Management | HIGH |
| planning, strategy, roadmap | Strategic Frameworks | HIGH |
| code, build, deploy | Development Protocols | MEDIUM |
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  3. Targeted Loading
&lt;/h3&gt;

&lt;p&gt;Based on keyword analysis, load 1-2 relevant sections instead of the entire document. Most requests need only a fraction of a comprehensive prompt.&lt;/p&gt;

&lt;h3&gt;
  
  
  4. Fallback Protocol
&lt;/h3&gt;

&lt;p&gt;When requests are ambiguous or span multiple areas, load the full document. This ensures no capability loss. The pattern optimizes common cases without sacrificing edge cases.&lt;/p&gt;




&lt;h2&gt;
  
  
  The Critical Decision: Section Boundaries
&lt;/h2&gt;

&lt;p&gt;This is where most implementations fail. How do you reliably identify where sections start and end?&lt;/p&gt;

&lt;p&gt;I tested three approaches:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Approach&lt;/th&gt;
&lt;th&gt;Mechanism&lt;/th&gt;
&lt;th&gt;Maintainability&lt;/th&gt;
&lt;th&gt;Drift Risk&lt;/th&gt;
&lt;th&gt;Verdict&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Line Numbers&lt;/td&gt;
&lt;td&gt;Map keywords to line ranges&lt;/td&gt;
&lt;td&gt;Low&lt;/td&gt;
&lt;td&gt;High (breaks on any edit)&lt;/td&gt;
&lt;td&gt;❌ Avoid&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Split Files&lt;/td&gt;
&lt;td&gt;Separate docs + index&lt;/td&gt;
&lt;td&gt;Medium&lt;/td&gt;
&lt;td&gt;None&lt;/td&gt;
&lt;td&gt;⚠️ Situational&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Anchor-Based&lt;/td&gt;
&lt;td&gt;Map keywords to section anchors&lt;/td&gt;
&lt;td&gt;High&lt;/td&gt;
&lt;td&gt;Low (survives edits)&lt;/td&gt;
&lt;td&gt;✅ Winner&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;h3&gt;
  
  
  Why Anchors Win
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Line Numbers&lt;/strong&gt; broke immediately. Any edit shifted all downstream line numbers. Maintenance nightmare.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Split Files&lt;/strong&gt; worked, but added deployment complexity and made the system harder to reason about.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Anchor-Based Routing&lt;/strong&gt; is the winner. Use HTML comment markers as anchors at section boundaries:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;&lt;span class="c"&gt;&amp;lt;!-- #crisis-management --&amp;gt;&lt;/span&gt;
&lt;span class="gu"&gt;## Crisis Management Protocol&lt;/span&gt;
[... 200 lines of crisis content ...]

&lt;span class="c"&gt;&amp;lt;!-- #development --&amp;gt;&lt;/span&gt;
&lt;span class="gu"&gt;## Development Protocols  &lt;/span&gt;
[... 350 lines of dev content ...]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;These HTML comment markers (&lt;code&gt;&amp;lt;!-- #section-name --&amp;gt;&lt;/code&gt;) are invisible to the LLM's output but serve as stable reference points. When you edit content within a section, the anchors don't move. For living prompt documents that evolve constantly, this is critical.&lt;/p&gt;

&lt;p&gt;Your routing header maps keywords to anchor names, not line numbers. This is the Simple Version:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;&lt;span class="gu"&gt;## TOC - Dynamic Section Loading&lt;/span&gt;

&lt;span class="gs"&gt;**Load only the section(s) matching task keywords. Fallback to full load if ambiguous.**&lt;/span&gt;

&lt;span class="gs"&gt;**Table of Contents:**&lt;/span&gt;

| Keywords | Anchor | Description |
|----------|--------|-------------|
| crisis, emergency | #crisis-management | Production issues |
| code, build, test | #development | Development work |
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Anchors survive content edits within sections. For living prompt documents that you're constantly refining, this is the difference between a maintainable system and a fragile one.&lt;/p&gt;




&lt;h2&gt;
  
  
  A Real Example
&lt;/h2&gt;

&lt;p&gt;Here's what this looks like in practice. My AI assistant prompt transformation:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Before:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;1,089 lines loaded every interaction&lt;/li&gt;
&lt;li&gt;~3,000+ tokens consumed before the conversation started&lt;/li&gt;
&lt;li&gt;Noticeable latency on complex requests&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;After:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Core context: ~200 lines (always loaded) or loaded first.&lt;/li&gt;
&lt;li&gt;Targeted sections: 200-400 lines (based on request)&lt;/li&gt;
&lt;li&gt;Total per interaction: 400-600 lines (~1,200-1,800 tokens)&lt;/li&gt;
&lt;li&gt;Fallback rate: &amp;lt;20% of interactions&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Sample Routing Header (Robust Version)
&lt;/h3&gt;

&lt;p&gt;For complex one-shot prompts with core context requirements:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;&lt;span class="gu"&gt;## TOC - Dynamic Section Loading&lt;/span&gt;

&lt;span class="gu"&gt;### STEP 1: LOAD CORE CONTEXT (ALWAYS)&lt;/span&gt;
Identity &amp;amp; Behavioral Framework (~200 lines)

&lt;span class="gu"&gt;### STEP 2: ANALYZE USER REQUEST&lt;/span&gt;
Match keywords from the Table of Contents below.

&lt;span class="gu"&gt;### STEP 3: LOAD TARGETED SECTIONS&lt;/span&gt;

&lt;span class="gs"&gt;**Table of Contents:**&lt;/span&gt;

| Keywords | Anchor | Lines |
|----------|--------|-------|
| customer, account, support | #customer-protocols | ~250 |
| code, build, architecture | #development | ~300 |
| crisis, outage, emergency | #crisis-mgmt | ~150 |
| planning, strategy | #strategic | ~200 |
| team, mentor, feedback | #team | ~180 |
| write, document, blog | #writing | ~120 |

&lt;span class="gu"&gt;### STEP 4: FALLBACK&lt;/span&gt;
If no keywords match OR request spans 3+ areas → load full document

&lt;span class="gs"&gt;**Multi-section triggers**&lt;/span&gt;:
&lt;span class="p"&gt;-&lt;/span&gt; "deploy to production" → #development + #crisis-mgmt
&lt;span class="p"&gt;-&lt;/span&gt; "customer escalation" → #customer-protocols + #crisis-mgmt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  When to Use This Pattern
&lt;/h2&gt;

&lt;h3&gt;
  
  
  ✅ Apply when:
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Document &amp;gt; 500 lines&lt;/strong&gt; (~4,000 tokens): Smaller docs don't need optimization&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;3+ distinct, independently-useful sections&lt;/strong&gt;: Content must be modular&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Typical task uses &amp;lt; 50% of content&lt;/strong&gt;: If most content is needed anyway, skip this&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Sections have clear boundaries&lt;/strong&gt;: Can be anchored reliably&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  ❌ Skip when:
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;Sections are highly interdependent (need most content anyway)&lt;/li&gt;
&lt;li&gt;Content is consumed sequentially (not random access)&lt;/li&gt;
&lt;li&gt;Document changes frequently (keyword mapping overhead)&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  Use Cases Beyond AI Assistants
&lt;/h2&gt;

&lt;p&gt;The efficiency gains matter, but what excites me most is what this pattern enables:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Portable Personal Context&lt;/strong&gt;: Carry your AI assistant's personality, preferences, and learned patterns across different models and platforms. A well-structured prompt with dynamic loading can move from Claude to GPT to Gemini while maintaining consistent behavior.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Product Requirements Documents (PRDs)&lt;/strong&gt;: Feature specs with distinct sections (overview, requirements, constraints, acceptance criteria).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Technical Specifications&lt;/strong&gt;: Architecture docs, API specs, system design documents with modular sections.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Behavioral Systems&lt;/strong&gt;: AI agent instructions, persona definitions, role-specific operational knowledge.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Reference Documentation&lt;/strong&gt;: Large reference materials, training content, compliance procedures accessed by topic.&lt;/p&gt;




&lt;h2&gt;
  
  
  Try It Yourself
&lt;/h2&gt;

&lt;p&gt;To get started with large prompts:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Audit your prompt&lt;/strong&gt;: Identify distinct, independently-useful sections&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Define core context&lt;/strong&gt;: What's needed for ANY request? Keep it under 25%&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Add anchors&lt;/strong&gt;: HTML comments at section boundaries&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Build the routing table&lt;/strong&gt;: Map user keywords to anchors&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Add fallback logic&lt;/strong&gt;: Ensure no capability loss&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Start simple. Refine keyword mappings as you observe how users interact with your assistant.&lt;/p&gt;




&lt;h2&gt;
  
  
  Let's Discuss
&lt;/h2&gt;

&lt;p&gt;I'm curious what patterns others use for prompt optimization:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Are you splitting documents? &lt;/li&gt;
&lt;li&gt;Using different routing mechanisms? &lt;/li&gt;
&lt;li&gt;Running into similar challenges?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Drop a comment. I'd love to hear what's working (or not working) for you.&lt;/p&gt;




&lt;h2&gt;
  
  
  Why I'm Sharing This
&lt;/h2&gt;

&lt;p&gt;I spent weeks refining this pattern through trial and error. After my validation, I wanted to give back to the prompt engineering community. Context engineering is becoming a critical skill as the use of agents develops and prompts grow more sophisticated. Patterns like this will matter more as we push models to handle complex, persistent behaviors.&lt;/p&gt;

&lt;p&gt;This article covers the pattern itself. The full case study on building Nathaniel, my AI assistant with 1,000+ lines of behavioral protocols, learning systems, and adaptive personality, is coming soon. If you're interested in the complete architecture and lessons learned, follow along.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;This full pattern documentation is available as a &lt;a href="https://gist.github.com/Warner-Bell/e3a34a82214d370cdc9fa816d349c16b" rel="noopener noreferrer"&gt;GitHub Gist&lt;/a&gt; if you want to fork and adapt it.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>promptengineering</category>
      <category>optimization</category>
      <category>llm</category>
    </item>
    <item>
      <title>🎧 AWS Audio Transcription Automation with CloudFormation</title>
      <dc:creator>Warner Bell</dc:creator>
      <pubDate>Sat, 09 Nov 2024 16:51:45 +0000</pubDate>
      <link>https://dev.to/warnerbell/aws-audio-transcription-automation-with-cloudformation-207g</link>
      <guid>https://dev.to/warnerbell/aws-audio-transcription-automation-with-cloudformation-207g</guid>
      <description>&lt;p&gt;Welcome to the &lt;strong&gt;AWS Audio Transcription Automation&lt;/strong&gt; project! This CloudFormation stack automates transcription of audio files (MP4, MP3, and WAV) using &lt;strong&gt;Amazon Transcribe&lt;/strong&gt;. Easily upload your audio files to S3, trigger transcription jobs, and store results in an output S3 bucket — all automated! 🎉&lt;/p&gt;

&lt;h2&gt;
  
  
  Architecture Diagram
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjxrtflev6djmbvxywq22.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjxrtflev6djmbvxywq22.png" alt="Transcription Diagram drawio (1)" width="800" height="742"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;GitHub repo: &lt;a href="https://github.com/Warner-Bell/audio-transcription-build" rel="noopener noreferrer"&gt;https://github.com/Warner-Bell/audio-transcription-build&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  🚀 Features
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Automatic Transcription&lt;/strong&gt;: Supports MP4, MP3, and WAV audio files, using Amazon Transcribe.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Secure Storage&lt;/strong&gt;: AES-256 encryption for S3 buckets.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Lifecycle Management&lt;/strong&gt;: Automatically expire input files after 1 day and log files after 2 days.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Logging&lt;/strong&gt;: Logs Lambda function execution and S3 access.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Event-Driven Transcription&lt;/strong&gt;: Automatically triggers transcription jobs upon file upload.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Final HTML Output&lt;/strong&gt;: Transcription results are processed into an HTML file, viewable on any browser for easy reading.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  🛠️ Technology Stack
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Amazon S3&lt;/strong&gt;: Storage for audio files, transcription results, and access logs.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;AWS Lambda&lt;/strong&gt;: Event-driven function to trigger transcription jobs.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Amazon Transcribe&lt;/strong&gt;: Speech-to-text transcription service.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Amazon CloudWatch&lt;/strong&gt;: Logs Lambda function activity.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;IAM Roles&lt;/strong&gt;: Manages permissions for Lambda and S3.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  🎯 How It Works
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Upload&lt;/strong&gt; audio files (MP4, MP3, or WAV) to the designated S3 input bucket.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Lambda Triggered&lt;/strong&gt;: Upon upload, a Lambda function triggers an Amazon Transcribe job.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Transcription Results&lt;/strong&gt;: Transcription results are stored in the specified S3 output bucket, and formatted as an HTML file for easy viewing.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  🧩 CloudFormation Resources
&lt;/h2&gt;

&lt;p&gt;This CloudFormation stack provisions the following resources:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Input S3 Bucket&lt;/strong&gt;: For audio files awaiting transcription.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Output S3 Bucket&lt;/strong&gt;: Stores completed transcription results.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Logging S3 Bucket&lt;/strong&gt;: Logs access events for both input and output buckets.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;AWS Lambda Function&lt;/strong&gt;: Automatically triggers transcription jobs.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;IAM Role&lt;/strong&gt;: Provides necessary permissions for the Lambda function.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;CloudWatch Log Group&lt;/strong&gt;: Logs Lambda function execution.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  📦 Installation &amp;amp; Setup
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Prerequisites
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;AWS CLI&lt;/strong&gt;: Installed and configured on your local machine.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;AWS Account&lt;/strong&gt;: Ensure permissions to create CloudFormation stacks, Lambda functions, and S3 buckets.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Edit Deploy File&lt;/strong&gt;: Edit the &lt;code&gt;STACK_NAME&lt;/code&gt; constant to a unique name in the &lt;code&gt;deploy-transcription.sh&lt;/code&gt; file. Update the region in the &lt;code&gt;s3-trigger.sh&lt;/code&gt; file if your region is not &lt;code&gt;us-east-1&lt;/code&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Deploy the Stack
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Clone the repository&lt;/strong&gt;:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;   git clone https://github.com/Warner-Bell/audio-transcription-build.git
   &lt;span class="nb"&gt;cd &lt;/span&gt;audio-transcription-automation
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Update the &lt;code&gt;s3-trigger.sh&lt;/code&gt; file with you stack name&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Run the deployment script&lt;/strong&gt;:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;   ./bin/deploy-transcription.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This script deploys the CloudFormation stack using a template file, setting up the required S3 buckets, Lambda function, and permissions.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Deploy S3 Trigger for Lambda&lt;/strong&gt;:
After deploying the CloudFormation stack, set up the S3 bucket trigger using &lt;code&gt;s3-trigger.sh&lt;/code&gt;:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;   ./bin/s3-trigger.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Note&lt;/strong&gt;: The S3 trigger configuration script (&lt;code&gt;s3-trigger.sh&lt;/code&gt;) is created as a separate script to avoid circular dependencies between the S3 bucket, Lambda function, and logging configuration.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Verify Deployment&lt;/strong&gt;: Monitor the deployment progress in the &lt;strong&gt;AWS CloudFormation Console&lt;/strong&gt; to ensure all resources are created successfully.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Start Transcribing&lt;/strong&gt;: Once deployed, simply upload audio files to the designated input S3 bucket to start transcription. After running the S3 bucket trigger, upload your files to S3 using &lt;code&gt;upload-to-s3.sh&lt;/code&gt; (&lt;strong&gt;Edit&lt;/strong&gt; the file variables with your info.)&lt;br&gt;
&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;   ./bin/upload-to-s3.sh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Note on Output&lt;/strong&gt;: Transcription output files are stored in both JSON and HTML format in the output S3 bucket. The HTML format can be viewed directly in any web browser for easy reading, eliminating the need to manually copy text from JSON files.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2&gt;
  
  
  📂 Project Structure
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;.&lt;/span&gt;
├── audio-samples        &lt;span class="c"&gt;# 3 sample audio files in mp3, mp4, and wav format&lt;/span&gt;
├── bin/
│   ├── deploy-transcription.sh &lt;span class="c"&gt;# Deployment script&lt;/span&gt;
│   ├── empty-buckets.sh        &lt;span class="c"&gt;# Empty all Project Buckets&lt;/span&gt;
│   ├── s3-trigger.sh           &lt;span class="c"&gt;# Lambda role configuration and S3 bucket notifications&lt;/span&gt;
│   ├── upload-to-s3.sh         &lt;span class="c"&gt;# Upload selected audio file to s3&lt;/span&gt;
├── cfn/audio-transcription.yaml         &lt;span class="c"&gt;# CloudFormation template&lt;/span&gt;
├── README.md                   &lt;span class="c"&gt;# Project documentation&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  📊 Monitoring &amp;amp; Logging
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;CloudWatch Logs&lt;/strong&gt;: View Lambda execution logs in the AWS CloudWatch console.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;S3 Access Logs&lt;/strong&gt;: Access logs for input and output S3 buckets are stored in the logging bucket.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  ⚙️ Recommended Practices
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Adjust Bucket Retention&lt;/strong&gt;: Modify lifecycle policies to suit your data retention requirements.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Configure Notifications&lt;/strong&gt;: Install and configure &lt;code&gt;notify-send&lt;/code&gt; on Linux for deployment notifications (optional).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Review IAM Policies&lt;/strong&gt;: Ensure permissions are as restrictive as possible for production use.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  🤝 Contributing
&lt;/h2&gt;

&lt;p&gt;We welcome contributions! To contribute, follow these steps:&lt;/p&gt;

&lt;h3&gt;
  
  
  How to Contribute
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;Fork the repo 🍴&lt;/li&gt;
&lt;li&gt;Create a new branch:
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;   git checkout &lt;span class="nt"&gt;-b&lt;/span&gt; feature/awesome-feature
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Commit your changes 💻&lt;/li&gt;
&lt;li&gt;Push your branch and submit a PR 🛠️&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  🌍 License
&lt;/h2&gt;

&lt;p&gt;This project is licensed under the MIT License. See the &lt;a href="https://dev.toLICENSE"&gt;LICENSE&lt;/a&gt; file for details.&lt;/p&gt;

&lt;h2&gt;
  
  
  🏆 Acknowledgements
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Thanks to &lt;strong&gt;AWS&lt;/strong&gt; for their robust services. 💪&lt;/li&gt;
&lt;li&gt;Special thanks to &lt;strong&gt;OpenAI&lt;/strong&gt; for inspiring innovation with AI-based tools. 🙌&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  📬 Contact
&lt;/h2&gt;

&lt;p&gt;Warner Bell - &lt;a href="https://dot.cards/warnerbell" rel="noopener noreferrer"&gt;Tap In!&lt;/a&gt;&lt;/p&gt;




&lt;p&gt;✨ &lt;strong&gt;Happy Transcribing!&lt;/strong&gt; ✨&lt;/p&gt;

</description>
      <category>awstranscribe</category>
      <category>cicd</category>
      <category>lambda</category>
      <category>s3</category>
    </item>
    <item>
      <title>Building 'TheContentCaddie': My Participation in the PartyRock Generative AI Hackathon</title>
      <dc:creator>Warner Bell</dc:creator>
      <pubDate>Sun, 27 Oct 2024 16:50:42 +0000</pubDate>
      <link>https://dev.to/warnerbell/building-thecontentcaddie-my-participation-in-the-partyrock-generative-ai-hackathon-23ml</link>
      <guid>https://dev.to/warnerbell/building-thecontentcaddie-my-participation-in-the-partyrock-generative-ai-hackathon-23ml</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F1ru7jr2y9d4z8rkl72js.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F1ru7jr2y9d4z8rkl72js.png" alt="TheContentCaddie" width="800" height="800"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  🚀 Introduction
&lt;/h2&gt;

&lt;p&gt;Hello, Dev.to community! I’m excited to share my journey in the PartyRock Generative AI Hackathon by AWS. I recently worked on an exciting project: creating "TheContentCaddie," an AI Video Content Generation &amp;amp; Promotion Assistant. This app is designed to aid content creators in the daunting task of producing and promoting digital content, particularly for platforms like YouTube.&lt;/p&gt;

&lt;h2&gt;
  
  
  🤔 What Inspired Me?
&lt;/h2&gt;

&lt;p&gt;My inspiration for the app came from my understanding of creating content for social media, especially video content for platforms like YouTube. I know how conceptualizing, organizing, gathering data, creating content, recording, editing, designing art and graphics, uploading, and promoting content is a job fit for a team. However, many creators, myself included, are trying to navigate all aspects of getting their content out to help the masses, grow a personal brand, or build an online following, often as a one-person band. &lt;br&gt;
when I first got started I wanted to create some content documenting my experience and processes participating in the hackathon but juggling the content creation and meeting the hackathon's requirements seemed too daunting a task, especially with everything else going on in my work and life. That's when it hit me: my hackathon entry should be an app that helps creators with all the legwork involved in creating their content. Even better, I can use it to create the content documenting my hackathon joining experience, closing the loop, and achieving a state of Zen, with a paradoxical connotation where the need for a tool to help with content creation, inspired the creation of a tool, that would help with the creation of the content documenting the creation of the tool, that helped create the content… 🤯🤯🤯 &lt;/p&gt;

&lt;h2&gt;
  
  
  🛠️ How I Built the Project
&lt;/h2&gt;

&lt;p&gt;Building "TheContentCaddie" on AWS's PartyRock platform was an exhilarating challenge. I embraced the world of generative AI, leveraging the platform's capabilities to bring my vision to life. My process was a blend of creativity, technical skill, and a deep dive into the realms of LLM prompting.&lt;/p&gt;

&lt;h3&gt;
  
  
  The Development Process
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Conceptualization&lt;/strong&gt;: I started by defining the core functionalities: script generation, SEO optimization, concept image creation, and social media promotion.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Integration of Generative AI&lt;/strong&gt;: Leveraging PartyRock's AI capabilities, I incorporated features for generating video scripts, titles, descriptions, and promotional content.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;LLM Prompting&lt;/strong&gt;: Learning about LLM prompting was a game-changer. Understanding how to craft prompts effectively was crucial in getting the desired outputs.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Building the Chatbot&lt;/strong&gt;: The AI chatbot was integrated to offer expert social media marketing advice, enhancing the app's utility.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  Tools and Technologies
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;AWS PartyRock&lt;/strong&gt;: For the AI-driven backend.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  🚧 Challenges Faced
&lt;/h2&gt;

&lt;p&gt;One of the main challenges was harnessing the AI to produce the desired outcomes. It required a lot of ideation, iteration, and testing to understand the intricacies of the AI models and find the best methods to achieve my goals.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;AI Responsiveness&lt;/strong&gt;: Fine-tuning the AI to generate relevant and engaging content was challenging. It involved numerous iterations and tweaking of LLM prompts.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Integration Complexity&lt;/strong&gt;: Ensuring seamless integration of different AI functionalities while maintaining a user-friendly interface was a steep learning curve.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Time Management&lt;/strong&gt;: Balancing the project with my professional commitments was demanding, requiring effective time management skills.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  📚 What I Learned
&lt;/h2&gt;

&lt;p&gt;Throughout this journey, I've learned about the ease and speed of developing applications on PartyRock. I've gained insights into LLM prompting and how different inputs can significantly alter the outputs of language models. This experience has opened my eyes to the broader world of hackathons, and I'm excited to participate in more in the future.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;LLM Prompt Engineering&lt;/strong&gt;: The art of crafting effective prompts to guide AI output was a key takeaway.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Rapid Prototyping on AWS&lt;/strong&gt;: The agility and power of AWS tools in bringing a concept to life were enlightening.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hackathon Culture&lt;/strong&gt;: The collaborative, innovative spirit of hackathons has sparked a new interest in me to participate in more such events.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  🏆 Accomplishments that I'm proud of
&lt;/h2&gt;

&lt;p&gt;This hackathon has been an incredible learning journey. I'm proud of diving into this challenge, exploring new territories in cloud technology, and creating an app that could potentially revolutionize content creation for many creators out there.&lt;/p&gt;

&lt;h2&gt;
  
  
  🎉 Closing Thoughts
&lt;/h2&gt;

&lt;p&gt;Building "TheContentCaddie" was not just about creating an app; it was about solving a real-world problem that resonates with many in the digital content space. This project has been a journey of learning, growth, and immense satisfaction. I'm excited to see how it helps content creators streamline their workflows and achieve their creative visions more efficiently.&lt;/p&gt;

&lt;p&gt;I hope my journey inspires fellow developers and creators. Let's continue to innovate and solve problems, one hackathon at a time!&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Thanks for reading! Feel free to drop your thoughts or questions in the comments below. Happy coding!&lt;/em&gt;&lt;/p&gt;




&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F09jpxiwrqcht7wxiykeb.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F09jpxiwrqcht7wxiykeb.png" alt=" " width="800" height="800"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;p&gt;Would you like to know more about "TheContentCaddie"? Check out the project on &lt;a href="https://partyrock.aws/u/WarnerBell/Va_dT1BP6/TheContentCaddie" rel="noopener noreferrer"&gt;PartyRock&lt;/a&gt; or reach out to me on &lt;a href="https://www.linkedin.com/in/warnerbell/" rel="noopener noreferrer"&gt;LinkedIn&lt;/a&gt;. Let's connect! 🌟&lt;/p&gt;

</description>
      <category>aws</category>
      <category>partyrock</category>
      <category>generativeai</category>
      <category>hackathon</category>
    </item>
    <item>
      <title>🔐 How to Generate a GitHub Personal Access Token (PAT)</title>
      <dc:creator>Warner Bell</dc:creator>
      <pubDate>Sun, 27 Oct 2024 16:32:07 +0000</pubDate>
      <link>https://dev.to/warnerbell/how-to-generate-a-github-personal-access-token-pat-1bg5</link>
      <guid>https://dev.to/warnerbell/how-to-generate-a-github-personal-access-token-pat-1bg5</guid>
      <description>&lt;p&gt;Follow these steps to create a GitHub Personal Access Token (PAT) to use for authentication with Git or other tools:&lt;/p&gt;

&lt;h2&gt;
  
  
  1. 🔑 &lt;strong&gt;Log in to GitHub:&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Go to &lt;a href="https://github.com" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt; and log in to your account.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  2. ⚙️ &lt;strong&gt;Access Developer Settings:&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;In the upper-right corner of any GitHub page, click your profile picture.&lt;/li&gt;
&lt;li&gt;Select &lt;strong&gt;Settings&lt;/strong&gt; from the dropdown.&lt;/li&gt;
&lt;li&gt;Scroll down and, on the left sidebar, click &lt;strong&gt;Developer settings&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  3. 🛠 &lt;strong&gt;Generate a Personal Access Token:&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;In &lt;strong&gt;Developer settings&lt;/strong&gt;, select &lt;strong&gt;Personal access tokens&lt;/strong&gt; from the sidebar.&lt;/li&gt;
&lt;li&gt;Click on &lt;strong&gt;Tokens (classic)&lt;/strong&gt; and then click &lt;strong&gt;Generate new token&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Generate New Token (Classic)&lt;/li&gt;
&lt;li&gt;Give the token a descriptive name, such as &lt;em&gt;"Git CLI Token"&lt;/em&gt;, so you can remember why you created it.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  4. 🔐 &lt;strong&gt;Select Scopes and Permissions:&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Choose the scopes or permissions to grant this token. For full access to repositories (push, pull, etc.), select the &lt;code&gt;repo&lt;/code&gt; scope.&lt;/li&gt;
&lt;li&gt;You may also want to choose &lt;code&gt;workflow&lt;/code&gt; for GitHub Actions or &lt;code&gt;admin:repo_hook&lt;/code&gt; for repository webhooks.&lt;/li&gt;
&lt;li&gt;If you only need specific permissions, select the minimum necessary scopes for better security.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  5. ⚡ &lt;strong&gt;Generate the Token:&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;After selecting your desired scopes, click &lt;strong&gt;Generate token&lt;/strong&gt; at the bottom of the page.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  6. 📋 &lt;strong&gt;Copy the Token:&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Important&lt;/strong&gt;: Once the token is generated, copy it immediately. You &lt;strong&gt;won't&lt;/strong&gt; be able to view the token again after you leave the page.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  7. 🛡 &lt;strong&gt;Store the Token Safely:&lt;/strong&gt;
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Save the token in a secure location, like a password manager.&lt;/li&gt;
&lt;li&gt;Use this token instead of your password when performing operations like pushing or pulling from a GitHub repository.&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  🧑‍💻 &lt;strong&gt;Using the Token with Git:&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;When prompted for a username and password during Git operations, use:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Username&lt;/strong&gt;: Your GitHub username.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Password&lt;/strong&gt;: Paste your newly generated PAT.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Example during &lt;code&gt;git push&lt;/code&gt; or &lt;code&gt;git pull&lt;/code&gt;:&lt;/p&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;
shell
Username: your-github-username
Password: your-access-token
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

</description>
    </item>
    <item>
      <title>Setting Up a Basic Dev Environment on a Windows/Linux Machine</title>
      <dc:creator>Warner Bell</dc:creator>
      <pubDate>Sun, 27 Oct 2024 16:30:04 +0000</pubDate>
      <link>https://dev.to/warnerbell/setting-up-a-basic-dev-environment-on-a-windowslinux-machine-4na4</link>
      <guid>https://dev.to/warnerbell/setting-up-a-basic-dev-environment-on-a-windowslinux-machine-4na4</guid>
      <description>&lt;h2&gt;
  
  
  🚀 Set Up Your Dev Environment
&lt;/h2&gt;

&lt;p&gt;Welcome to your step-by-step guide for setting up a &lt;strong&gt;powerful development environment&lt;/strong&gt; using &lt;strong&gt;Windows Subsystem for Linux (WSL)&lt;/strong&gt;, &lt;strong&gt;Visual Studio Code (VSCode)&lt;/strong&gt;, and essential tools like &lt;strong&gt;Git&lt;/strong&gt; and &lt;strong&gt;Node Version Manager (NVM)&lt;/strong&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  📑 &lt;strong&gt;Table of Contents&lt;/strong&gt;
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;💻 IDE - Install Visual Studio Code (VSCode)&lt;/li&gt;
&lt;li&gt;🔧 Configure VSCode for Development&lt;/li&gt;
&lt;li&gt;🐧 WSL - Setting Up Ubuntu and Updating Linux Kernel&lt;/li&gt;
&lt;li&gt;
🛠️ Essential Dev Tools

&lt;ul&gt;
&lt;li&gt;Node Version Manager (NVM)&lt;/li&gt;
&lt;li&gt;AWS CLI v2&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;🐍 Python and pip&lt;/li&gt;
&lt;li&gt;⚡ Git - Installation and Configuration&lt;/li&gt;
&lt;li&gt;🔑 Git Credential Manager (GCM)&lt;/li&gt;
&lt;li&gt;🔒 Configure Security Settings&lt;/li&gt;
&lt;li&gt;🎉 Final Congratulations&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  💻 IDE - Install Visual Studio Code (VSCode)
&lt;/h2&gt;

&lt;p&gt;VSCode is a &lt;strong&gt;crucial tool&lt;/strong&gt; for development. Let's get it installed and ready!&lt;/p&gt;

&lt;h3&gt;
  
  
  🔽 &lt;strong&gt;Steps to Install VSCode:&lt;/strong&gt;
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Download VSCode:&lt;/strong&gt; Visit &lt;a href="https://code.visualstudio.com/Download" rel="noopener noreferrer"&gt;Visual Studio Code&lt;/a&gt; and download the Windows installer.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Run the Installer:&lt;/strong&gt; Double-click the downloaded file and follow the instructions. Check the options to:

&lt;ul&gt;
&lt;li&gt;Add VSCode to the PATH.&lt;/li&gt;
&lt;li&gt;Create a desktop icon for quick access.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  🚀 &lt;strong&gt;Install VSCode Using PowerShell CLI:&lt;/strong&gt;
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="nv"&gt;$InstallerUrl&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"https://code.visualstudio.com/sha/download?build=stable&amp;amp;os=win32-x64-user"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="nv"&gt;$InstallerPath&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="nv"&gt;$&lt;/span&gt;&lt;span class="nn"&gt;env&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="nv"&gt;TEMP&lt;/span&gt;&lt;span class="s2"&gt;\VSCodeInstaller.exe"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;Invoke-WebRequest&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Uri&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$InstallerUrl&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-OutFile&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$InstallerPath&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;Start-Process&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-FilePath&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$InstallerPath&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-ArgumentList&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"/verysilent"&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-NoNewWindow&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nt"&gt;-Wait&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="n"&gt;Remove-Item&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nv"&gt;$InstallerPath&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  🚀 &lt;strong&gt;Install VSCode Using Linux CLI:&lt;/strong&gt;
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;curl gpg
curl &lt;span class="nt"&gt;-fsSL&lt;/span&gt; https://packages.microsoft.com/keys/microsoft.asc | gpg &lt;span class="nt"&gt;--dearmor&lt;/span&gt; &lt;span class="nt"&gt;-o&lt;/span&gt; /usr/share/keyrings/ms.gpg
&lt;span class="nb"&gt;echo&lt;/span&gt; &lt;span class="s2"&gt;"deb [arch=amd64 signed-by=/usr/share/keyrings/ms.gpg] https://packages.microsoft.com/repos/code stable main"&lt;/span&gt; | &lt;span class="nb"&gt;sudo tee&lt;/span&gt; /etc/apt/sources.list.d/vscode.list
&lt;span class="nb"&gt;sudo &lt;/span&gt;apt update
&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;code
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;blockquote&gt;
&lt;p&gt;After installing, launch VSCode by typing &lt;code&gt;code&lt;/code&gt; in your terminal.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;h2&gt;
  
  
  🔧 Configure VSCode for Development
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🛠️ &lt;strong&gt;Steps to Configure VSCode:&lt;/strong&gt;
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Open VSCode:&lt;/strong&gt; Launch VSCode from your &lt;strong&gt;Start Menu&lt;/strong&gt; or &lt;strong&gt;Desktop Icon&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Install Extensions:&lt;/strong&gt; Go to the Extensions Marketplace by pressing &lt;code&gt;Ctrl+Shift+X&lt;/code&gt;. Recommended extensions:

&lt;ul&gt;
&lt;li&gt;🔗 &lt;strong&gt;Remote Development&lt;/strong&gt; – for remote development within WSL.&lt;/li&gt;
&lt;li&gt;🐍 &lt;strong&gt;Python&lt;/strong&gt; – for Python development.&lt;/li&gt;
&lt;li&gt;🧩 &lt;strong&gt;GitLens&lt;/strong&gt; – enhances Git capabilities.&lt;/li&gt;
&lt;li&gt;🐳 &lt;strong&gt;Docker&lt;/strong&gt; – for containerization.&lt;/li&gt;
&lt;li&gt;✨ &lt;strong&gt;ESLint&lt;/strong&gt; – for JavaScript development.&lt;/li&gt;
&lt;li&gt;📜 &lt;strong&gt;YAML&lt;/strong&gt; – for YAML language support.&lt;/li&gt;
&lt;li&gt;💻 &lt;strong&gt;Live Share&lt;/strong&gt; – for collaborative coding.&lt;/li&gt;
&lt;li&gt;🔐 &lt;strong&gt;Remote - SSH&lt;/strong&gt; – to connect via SSH to remote servers.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  🐧 WSL - Setting Up Ubuntu and Updating Linux Kernel
&lt;/h2&gt;

&lt;p&gt;Build a &lt;strong&gt;robust foundation&lt;/strong&gt; by setting up &lt;strong&gt;WSL&lt;/strong&gt; and &lt;strong&gt;Ubuntu&lt;/strong&gt; on your Windows machine.&lt;/p&gt;

&lt;h3&gt;
  
  
  🛠️ &lt;strong&gt;Steps to Install WSL &amp;amp; Ubuntu:&lt;/strong&gt;
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Install WSL Ubuntu:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;In VSCode Open a &lt;strong&gt;PowerShell&lt;/strong&gt; terminal and enter:
&lt;/li&gt;
&lt;/ul&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt; wsl &lt;span class="nt"&gt;--install&lt;/span&gt; &lt;span class="nt"&gt;-d&lt;/span&gt; Ubuntu
&lt;/code&gt;&lt;/pre&gt;

&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;Click Yes if prompted to allow program to make changes, view install progress in terminal.&lt;/li&gt;
&lt;li&gt;Wait for the installation to complete, &lt;/li&gt;
&lt;li&gt;Reboot your machine. (a terminal window will open upon reboot)&lt;/li&gt;
&lt;li&gt;In the terminal window type a username when prompted (all lowercase), enter a password wait for the process to complete then close the window.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Update Linux Packages:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Now that WSL is up and running, we need to ensure our Linux packages are up-to-date. &lt;/li&gt;
&lt;li&gt;Open VSCode open your Ubuntu(WSL) terminal and run:
&lt;/li&gt;
&lt;/ul&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt; &lt;span class="nb"&gt;sudo &lt;/span&gt;apt update &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nb"&gt;sudo &lt;/span&gt;apt upgrade &lt;span class="nt"&gt;-y&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  🛠️ Essential Dev Tools
&lt;/h2&gt;

&lt;p&gt;To build high-quality software, install these &lt;strong&gt;essential tools&lt;/strong&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt-get &lt;span class="nb"&gt;install &lt;/span&gt;wget ca-certificates curl
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  🚀 &lt;strong&gt;Node Version Manager (NVM):&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Manage your Node.js versions efficiently with NVM:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-o-&lt;/span&gt; https://raw.githubusercontent.com/nvm-sh/nvm/master/install.sh | bash
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  🚀 &lt;strong&gt;AWS CLI v2&lt;/strong&gt;:
&lt;/h3&gt;

&lt;p&gt;The AWS Command Line Interface (CLI) v2 is essential for interacting with AWS services directly from the command line. Install it with the following steps:&lt;/p&gt;

&lt;h4&gt;
  
  
  &lt;strong&gt;Installation:&lt;/strong&gt;
&lt;/h4&gt;

&lt;p&gt;For Linux:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="s2"&gt;"https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip"&lt;/span&gt; &lt;span class="nt"&gt;-o&lt;/span&gt; &lt;span class="s2"&gt;"awscliv2.zip"&lt;/span&gt;
unzip awscliv2.zip
&lt;span class="nb"&gt;sudo&lt;/span&gt; ./aws/install
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;For Windows (via PowerShell):&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight powershell"&gt;&lt;code&gt;&lt;span class="n"&gt;msiexec.exe&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;/i&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="nx"&gt;https://awscli.amazonaws.com/AWSCLIV2.msi&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h4&gt;
  
  
  &lt;strong&gt;Verify the installation:&lt;/strong&gt;
&lt;/h4&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;aws &lt;span class="nt"&gt;--version&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This should return the installed version of AWS CLI v2.&lt;/p&gt;




&lt;h2&gt;
  
  
  🐍 Python and pip
&lt;/h2&gt;

&lt;p&gt;Python is an essential tool for cloud development. Install &lt;strong&gt;Python&lt;/strong&gt; and &lt;strong&gt;pip&lt;/strong&gt; with:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;python3-pip &lt;span class="nt"&gt;-y&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  ✅ &lt;strong&gt;CFN-Lint (CloudFormation Linter):&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Ensure quality in your CloudFormation templates:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;pip3 &lt;span class="nb"&gt;install &lt;/span&gt;cfn-lint
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;blockquote&gt;
&lt;p&gt;Don't forget to install the &lt;strong&gt;CloudFormation Linter&lt;/strong&gt; extension in VSCode!&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  🔧 jq (Command-line JSON processor):
&lt;/h3&gt;

&lt;p&gt;jq is a lightweight command-line JSON processor, essential for parsing and manipulating JSON data:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt-get &lt;span class="nb"&gt;install &lt;/span&gt;jq
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  💽 Install Database Tools (if needed)
&lt;/h2&gt;

&lt;p&gt;If your development requires a database, install the appropriate database. For example, for MySQL:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt; Download MySQL: Go to the MySQL Downloads page and select the Windows version.&lt;/li&gt;
&lt;li&gt; Install MySQL: Follow the setup wizard, set up your root password, and configure the server.&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  ⚡ Git - Installation and Configuration
&lt;/h2&gt;

&lt;p&gt;Git is essential for &lt;strong&gt;version control&lt;/strong&gt;. Install and configure Git with the following:&lt;/p&gt;

&lt;h3&gt;
  
  
  🛠️ &lt;strong&gt;Install Git:&lt;/strong&gt;
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt-get &lt;span class="nb"&gt;install &lt;/span&gt;git
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  🧑‍💻 &lt;strong&gt;Configure Git Identity:&lt;/strong&gt;
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git config &lt;span class="nt"&gt;--global&lt;/span&gt; user.name &lt;span class="s2"&gt;"Your Name"&lt;/span&gt;
git config &lt;span class="nt"&gt;--global&lt;/span&gt; user.email &lt;span class="s2"&gt;"your.email@example.com"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  🔍 &lt;strong&gt;View Git Configuration:&lt;/strong&gt;
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git config &lt;span class="nt"&gt;--list&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Install Git CLI:
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;sudo &lt;/span&gt;apt &lt;span class="nb"&gt;install &lt;/span&gt;gh
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🔑 Git Credential Manager (GCM)
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Git Credential Manager (GCM)&lt;/strong&gt; simplifies authentication for Git services like &lt;strong&gt;GitHub&lt;/strong&gt; and &lt;strong&gt;Azure DevOps&lt;/strong&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  💡 &lt;strong&gt;Setting Up GCM in WSL:&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Set up GCM within WSL:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git config &lt;span class="nt"&gt;--global&lt;/span&gt; credential.helper &lt;span class="s2"&gt;"/mnt/c/Program&lt;/span&gt;&lt;span class="se"&gt;\ &lt;/span&gt;&lt;span class="s2"&gt;Files/Git/mingw64/bin/git-credential-manager.exe"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;h2&gt;
  
  
  🔒 Configure Security Settings
&lt;/h2&gt;

&lt;h3&gt;
  
  
  🔧 &lt;strong&gt;Steps to Secure Your System:&lt;/strong&gt; ### (Optional)
&lt;/h3&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Windows Security:&lt;/strong&gt; Ensure &lt;strong&gt;Windows Defender&lt;/strong&gt; or your preferred antivirus is active and updated.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Firewall Settings:&lt;/strong&gt; Configure your &lt;strong&gt;Windows Firewall&lt;/strong&gt; to allow development tools while blocking unauthorized access.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Secure Browsers:&lt;/strong&gt; Install security extensions like &lt;strong&gt;HTTPS Everywhere&lt;/strong&gt; and ensure your browsers are up to date.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Regular Updates:&lt;/strong&gt; Keep &lt;strong&gt;Windows OS&lt;/strong&gt;, &lt;strong&gt;VSCode&lt;/strong&gt;, and all installed packages/extensions updated.&lt;/li&gt;
&lt;/ol&gt;




&lt;h2&gt;
  
  
  🎉 Final Congratulations
&lt;/h2&gt;

&lt;p&gt;You now have a &lt;strong&gt;fully configured, secure development environment&lt;/strong&gt; on your Windows machine using &lt;strong&gt;WSL&lt;/strong&gt;, &lt;strong&gt;VSCode&lt;/strong&gt;, &lt;strong&gt;Git&lt;/strong&gt;, and other standard development tools. You're ready for cloud development and ensuring your &lt;strong&gt;CloudFormation templates&lt;/strong&gt; are linted before merging into the main branch.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Happy Coding!&lt;/strong&gt; 💻🌐&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Automating CloudFormation Deployments: The DevOps Way with AWS Git sync &amp; GitHub Actions</title>
      <dc:creator>Warner Bell</dc:creator>
      <pubDate>Sat, 27 Jan 2024 17:12:36 +0000</pubDate>
      <link>https://dev.to/warnerbell/automating-cloudformation-deployments-the-devops-way-with-aws-git-sync-github-actions-15o1</link>
      <guid>https://dev.to/warnerbell/automating-cloudformation-deployments-the-devops-way-with-aws-git-sync-github-actions-15o1</guid>
      <description>&lt;h2&gt;
  
  
  Hey Devs, Let's Git This Party Started!
&lt;/h2&gt;

&lt;p&gt;CloudFormation Git sync provides remote management of stacks, enabling customers to synchronize their stacks from a CloudFormation template stored in a remote Git repository. You can enable CloudFormation Git sync through the AWS Console, CLI, and SDKs. With Git sync, you can manage your CloudFormation stacks using source control it works with GitHub, GitHub enterprise, GitLab, and BitBucket.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://youtu.be/U7bYRBXK5JE" rel="noopener noreferrer"&gt;Step-by-Step Walk-Through Video&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Kickoff: Setting Up Your GitHub Repo&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;Hop into GitHub&lt;/strong&gt;: Just slide into your GitHub account. No account yet? No sweat, signing up is a breeze.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Dashboard Time&lt;/strong&gt;: Once you're in, you're gonna land on your dashboard. It's your command center.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Repo Magic&lt;/strong&gt;:&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;  Hit the '+' sign up top. Feels like unlocking a treasure, right?&lt;/li&gt;
&lt;li&gt;  Choose 'New Repository' from the dropdown.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;Repo Details&lt;/strong&gt;:&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;  Name your brainchild.&lt;/li&gt;
&lt;li&gt;  Public or Private? Your call.&lt;/li&gt;
&lt;li&gt;  Add a catchy description.&lt;/li&gt;
&lt;li&gt;  Init with a README? Always a smart move.&lt;/li&gt;
&lt;li&gt;  Pick a license if you're feeling it.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;Create It&lt;/strong&gt;: Smash that 'Create repository' button.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Bam! Repository Ready&lt;/strong&gt;: Your new digital playground is set on GitHub.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Securing the Fort with a Token&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;Settings, Please&lt;/strong&gt;: Click your profile pic and hit 'Settings'.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Developer Mode On&lt;/strong&gt;: Find 'Developer settings' on the left.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Token Time&lt;/strong&gt;: Under 'Access Tokens', select 'Personal access tokens'.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Token Generation&lt;/strong&gt;:&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;  Click 'Generate token'. Feels like launching a rocket, huh?&lt;/li&gt;
&lt;li&gt;  Name it something cool.&lt;/li&gt;
&lt;li&gt;  Pick the powers (permissions) wisely.&lt;/li&gt;
&lt;li&gt;  Expiry date? Your choice.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;Copy That Token&lt;/strong&gt;: Guard it like a secret treasure.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Local Repo Clone: Bringing it Home&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;Git Ready&lt;/strong&gt;: No Git? Download it from the Git website.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Terminal or Command Prompt&lt;/strong&gt;: Open it. It's like opening the door to Narnia.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Directory Navigation&lt;/strong&gt;:&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;  Use 'cd' to move to your desired folder. Desktop? &lt;strong&gt;cd ~/Desktop&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;Clone Command&lt;/strong&gt;:&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;  &lt;strong&gt;git clone &lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;  Replace &lt;strong&gt;&lt;/strong&gt; with yours.&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;Token Authentication&lt;/strong&gt;: Private repo? Use your token as the password.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Cloned and Ready&lt;/strong&gt;: Your repo's now on your local machine. Time to make magic!&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Crafting Your CloudFormation Template.yaml&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;New File in IDE&lt;/strong&gt;: Click 'File' &amp;gt; 'New File'.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Save with .yaml Extension&lt;/strong&gt;: Name it like 'cfn-template.yaml'.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Template Time&lt;/strong&gt;: Paste your CloudFormation template here.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;AWSTemplateFormatVersion: 2010-09-09

Description: This is my gitsync demo template

Resources:

  GitsyncVpc:

    Type: AWS::EC2::VPC

    Properties:

      CidrBlock: 10.0.0.1/16

      EnableDnsSupport: true

      Tags:

        - Key: Name

          Value: gitsyncvpc

  GitsyncSubnet:

    Type: AWS::EC2::Subnet

    Properties:

      VpcId: !Ref GitsyncVpc

      CidrBlock: 10.0.0.1/24

      Tags:

        - Key: keyname

          Value: value
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Template Validation: No Errors Allowed&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;Save and Validate&lt;/strong&gt;: Run &lt;strong&gt;cfn-lint -t .yaml&lt;/strong&gt; in your terminal. To check your template for any syntax errors and provide feedback in the Output pane - keep it error-free.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;If you don't have cfn-lint installed, you can install it with the following command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;pip3 install cfn-lint
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Deployment File: Setting Up for Success&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;New File Again&lt;/strong&gt;: In your IDE, 'File' &amp;gt; 'New File'.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Save as 'deployment-file.yaml'&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Path and Tags&lt;/strong&gt;: Include the file path of your CloudFormation template and any tags.
&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;template-file-path: ./cfn-temp.yaml

tags:

    Name: 'gitsync'

    Project: 'Demo'
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;GitHub Actions: Keeping Your Code in Check&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;  Setup and establish the following folder structure:  &lt;strong&gt;.github/workflows/pull-request.yaml&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;  Define workflow to lint your pull requests.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;name: Pull Request workflow

on:

  - pull_request

jobs:

  cloudformation-linter:

    runs-on: ubuntu-latest

    steps:

      - name: Checkout

        uses: actions/checkout@v3

      - name: Linter install

        uses: scottbrenner/cfn-lint-action@v2

        with:

          command: cfn-lint -t ./cfn-temp.yaml
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Branching and Committing: Own Your Updates&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Create a new branch&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Add and commit your configs.&lt;br&gt;
&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git switch -c gitSync-updateBranch

git add -A

git commit -m "add gitsync configs"

git push origin gitSync-updateBranch
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Git Sync Prereqs: Keep Your Stack in Sync&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;AWS Console Login&lt;/strong&gt;: Head over to the AWS Management Console.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Developer Tools Connection&lt;/strong&gt;:&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;  Search ' Code Pipeline ' in AWS services.&lt;/li&gt;
&lt;li&gt;  Navigate to Connections&lt;/li&gt;
&lt;li&gt;  Create a new connection to GitHub.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkok6zo7ulfkrk5n9wmni.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fkok6zo7ulfkrk5n9wmni.png" alt="serch codepipeline" width="729" height="365"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fabl2qya6yxdt0b63oz49.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fabl2qya6yxdt0b63oz49.png" alt="choose connections" width="730" height="298"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffzlb4ljl51ebde4uujds.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffzlb4ljl51ebde4uujds.png" alt="create connection" width="730" height="356"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;IAM Role Creation&lt;/strong&gt;: Create the role that will deploy our CloudFormation template. Be sure to note the name you select for this as you'll be using it to manage your stack later. This example uses gitsync-cloudformation-deployment-role.&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;  Navigate ' IAM ' in AWS services.&lt;/li&gt;
&lt;li&gt;  Navigate to Connections&lt;/li&gt;
&lt;li&gt;  Create a new role for Cloudformaton. (gitsync-demo-role)&lt;/li&gt;
&lt;li&gt;  Create an inline policy for the role. (gitsync-demorole-policy)
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;JSON:

{

    "Version": "2012-10-17",

    "Statement": [

        {

            "Effect": "Allow",

            "Action": [

                "ec2:CreateVpc",

                "ec2:CreateSubnet",

                "ec2:DescribeVpcs",

                "ec2:DescribeSubnets",

                "ec2:DeleteVpc",

                "ec2:DeleteSubnet",

                "ec2:ModifySubnetAttribute",

                "ec2:CreateTags",

                "ec2:ModifyVpcAttribute"

            ],

            "Resource": "*",

            "Condition": {

                "ForAnyValue:StringEquals": {

                    "aws:CalledVia": [

                        "cloudformation.amazonaws.com"

                    ]

                }

            }

        }

    ]

}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Link up with CloudFormation!&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Once the role has been created, you'll create a new Stack:&lt;/p&gt;

&lt;p&gt;Here, you can see the new option to select Sync from Git template source, which you can configure on the next screen. Since you already created your stack deployment file, you can select I am providing my own file in my repository.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fiind1fing6ikwu9uaaw6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fiind1fing6ikwu9uaaw6.png" alt="create stack" width="800" height="494"&gt;&lt;/a&gt;&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0jsgzrliwi93bbneza0l.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0jsgzrliwi93bbneza0l.png" alt="stack file" width="800" height="192"&gt;&lt;/a&gt;&lt;br&gt;
Next, you can configure your Git integration to choose your repository. You'll need to use the Connection you created beforehand and select your repository. Select GitHub, your connection, the repository, and branch, the deployment file location.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9ien6cku4kk9slja7sy0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9ien6cku4kk9slja7sy0.png" alt="stack config" width="800" height="459"&gt;&lt;/a&gt;&lt;br&gt;
Now, you will select New IAM Role to create a service managed role. This role will enable Git sync to connect to your repository. The role will be re-usable.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Flajgpwjqz758pgd4d0t0.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Flajgpwjqz758pgd4d0t0.png" alt="stack role" width="800" height="199"&gt;&lt;/a&gt;&lt;br&gt;
On the next page, you'll select the IAM Role you created earlier to manage this stack. This role controls the resources that CloudFormation will deploy..&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fh0labcrv35y9vt9h8ymk.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fh0labcrv35y9vt9h8ymk.png" alt="stack perm role" width="800" height="214"&gt;&lt;/a&gt;&lt;br&gt;
Finally, you can see the status of your sync in the new "Git sync" tab, including the configuration you provided earlier as well as the status of your sync, your previous deployments, and the option to retry or disconnect the sync if needed.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fgmyjmh423p95es650zis.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fgmyjmh423p95es650zis.png" alt="git sync" width="800" height="398"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Give It a Whirl&lt;/strong&gt;&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt; &lt;strong&gt;Get over to GitHub&lt;/strong&gt;: log into your Github account.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Create a Pull Request&lt;/strong&gt;: Create a new pull request and wait for lint checks to pass.&lt;/li&gt;
&lt;li&gt; &lt;strong&gt;Merge Pull Request&lt;/strong&gt;: Include the file path of your CloudFormation template and any tags.
&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpno4ogqy7wzj97acfuai.png" alt="pull request" width="800" height="388"&gt;
&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ffroehyrgdmfldn9cwrqd.png" alt="checks" width="800" height="242"&gt;
&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F1kb2305r3zuiiecfklyq.png" alt="checks pass" width="800" height="320"&gt;
Return to the CloudFormation Console and see that the stack is being provisioned. You can also look at the stack details to see the events, outputs, etc.
&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frim7pctr3wwzr7gxc3d4.png" alt="in progress" width="800" height="339"&gt;
When the sync is complete Git sync will show the provisioning status as succeeded and the stack with all its resources will be deployed.
&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fefexjaelpruenunsdxwn.png" alt="git sync status" width="800" height="474"&gt;
&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhrgerysg0hu0u8y3x399.png" alt="sync success" width="800" height="57"&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;strong&gt;Conclusion: Wrapping Up Like a Pro&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You've just set up a slick, automated environment for CloudFormation templates. Validation on pull requests and auto-deployment to your stack? Now when your repo/template is updated and merged gitsync will automatically make the changes to your cloudformation stack and resources. We got this! This is that next-level CI/CD for your infrastructure code, a brand new workflow for me, and as always Builder Fun!&lt;/p&gt;

</description>
      <category>cloudformation</category>
      <category>gitsync</category>
      <category>aws</category>
      <category>github</category>
    </item>
    <item>
      <title>Taking on the Cloud-Resume-Challenge: My Experience</title>
      <dc:creator>Warner Bell</dc:creator>
      <pubDate>Tue, 16 May 2023 21:53:56 +0000</pubDate>
      <link>https://dev.to/warnerbell/taking-on-the-cloud-resume-challenge-my-experience-1ema</link>
      <guid>https://dev.to/warnerbell/taking-on-the-cloud-resume-challenge-my-experience-1ema</guid>
      <description>&lt;p&gt;&lt;strong&gt;Inspiration&lt;/strong&gt;&lt;br&gt;
I recently stumbled across the Cloud-Resume-Challenge and thought to myself, “That looks like a fun and useful little project I can do to learn and play in the cloud!” After doing some research, I found all the information I needed on the challenge’s website and began planning my approach.&lt;/p&gt;

&lt;p&gt;I had previously created a “Secure Static Website on AWS” using only the AWS console as a tutorial for my YouTube channel, @cloudoptimized. However, for this challenge, I wanted to do as much of it as possible in “Infrastructure as Code” (IaC).&lt;/p&gt;

&lt;p&gt;The Cloud-Resume-Challenge has several components, including certifications, HTML, CSS, a static website, HTTPS, DNS, JavaScript, a database, an API, testing, IaC, source control, and CI/CD. I will describe how I approached each component of the challenge.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Certifications&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Prior to finding this challenge, I had obtained the following certifications: AWS Certified Cloud Practitioner, AWS Certified SysOps Administrator — Associate, AWS Certified Solutions Architect — Associate, and Microsoft Certified Azure Fundamentals. These certifications provide a solid foundation for cloud computing and will be useful in my future career.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;HTML and CSS&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;For my HTML and CSS, I used a free sample site template from HTML5UP. They have some amazing offerings 100% free under their creative commons. I modified the template to create a basic configuration resume.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Static Website&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;I created a fully responsive static &lt;a href="//warnerbell.com"&gt;portfolio&lt;/a&gt; website using AWS S3. I used AWS CLI, CloudFormation, and AWS CDK to automate the deployment of the website. The FQDN was registered using AWS ACM, and the site was hosted on AWS S3. I followed the structure laid out by the Cloud-Resume-Challenge as much as possible.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;HTTPS&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;To ensure the website’s security, I obtained an SSL/TLS certificate from AWS Certificate Manager (ACM). ACM is a service that lets you easily provision, manage, and deploy public and private Secure Sockets Layer/Transport Layer Security (SSL/TLS) certificates for use with AWS services and your internal connected resources.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;DNS&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;I used Route53 hosted zones to create DNS records that alias to a CloudFront distribution and CNAMEs for the certificate. Route 53 is a highly available and scalable Domain Name System (DNS) web service. It connects user requests to internet applications running on AWS or on-premises.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;JavaScript&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;I used JavaScript to code the visits counter for the cloud portfolio frontend. JavaScript is a scripting or programming language that allows you to implement complex features on web pages. Every time a web page does more than just sit there and display static information, JavaScript is involved.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Database&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;I used AWS DynamoDB as the database for the site’s visits counter. DynamoDB is a fully managed NoSQL database service that provides fast and predictable performance with seamless scalability. It lets you offload the administrative burdens of operating and scaling a distributed database, so you don’t have to worry about hardware provisioning, setup and configuration, replication, software patching, or cluster scaling.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;API&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;For the API requirement of the challenge, I used Lambda URL. A function URL is a dedicated HTTP(S) endpoint for your Lambda function. You can create and configure a function URL through the Lambda console or the Lambda API. When you create a function URL, Lambda automatically generates a unique URL endpoint for you. Once you create a function URL, its URL endpoint never changes.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Python&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The code for the Lambda function, which retrieves and updates the views in the DynamoDB database, was written in Python. Python is an interpreted, object-oriented, high-level programming language with dynamic semantics. Its high-level built-in data structures, combined with dynamic typing and dynamic binding, make it very attractive.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Tests&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;During and after completing the build process, I deployed my website and began testing its functionality. I tested each component of the website to ensure that it was working as intended and that there were no errors or bugs. I also ran load tests to ensure that my website was able to handle high levels of traffic.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Infrastructure as Code&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;To manage and provision infrastructure more efficiently, I’m building CloudFormation templates for key components of the site and writing bash scripts to deploy them. Additionally, for small deployments and testing, I plan to use either AWS CDK or AWS SAM. This approach is known as Infrastructure as Code (IaC), which involves managing infrastructure through code rather than through manual processes. By using IaC, I can more easily manage and maintain my infrastructure and ensure that any changes are properly versioned and documented.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Source Control&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;For source control, I chose &lt;a href="https://github.com/Warner-Bell" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt;, an Internet hosting service for software development and version control using Git. GitHub provides a distributed version control of Git as well as access control, bug tracking, software feature requests, task management, continuous integration, and wikis for every project. By using GitHub, I can easily collaborate with others and keep track of changes to my codebase over time. Additionally, GitHub’s built-in tools for issue tracking and task management make it easy to keep track of bugs and feature requests.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;CI/CD (Back end)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;To streamline the development process, I decided to combine the continuous integration and continuous deployment (CI/CD) of both the front end and back end into one process using GitHub Actions. GitHub Actions allows me to automate, customize, and execute my software development workflows right in my repository. By using GitHub Actions, I can more easily build, test, and deploy my code and ensure that everything works as expected before pushing it to production.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;CI/CD (Front end)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;For the continuous integration and continuous deployment of my portfolio website’s front end, I’ll also be using GitHub Actions. By leveraging GitHub Actions, I can automate the process of building and deploying my front-end code, which will save me a lot of time and effort. I’ve written a GitHub .yaml file using Workflow syntax for GitHub Actions with a customization for security that will update my portfolio website upon push from the local repo. This approach will help me maintain a more efficient development workflow and ensure that my site stays up to date with the latest changes.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Challenges&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;One of the things that I found challenging during this project was getting the automation set up and configured properly. There were a lot of different components to configure, and it took some time to get everything working together. However, once I had everything set up, it was very easy to deploy and manage my website.&lt;/p&gt;

&lt;p&gt;Overall, I found the Cloud Resume Challenge to be a fun and challenging project that helped me learn a lot about cloud infrastructure and web development. The challenge forced me to learn about a lot of different tools that I hadn’t used before, and it was rewarding to see everything come together into a fully functional website.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;End of The Day&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The Cloud Resume Challenge is a great way to learn about cloud infrastructure and web development. The challenge forces you to learn about a lot of different services and tools, and it provides a structured framework for building a fully functional website. While the project can be challenging at times, the end result is a rewarding and valuable learning experience. I highly recommend the Cloud Resume Challenge to anyone who is interested in learning more about cloud infrastructure and web development.&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
