<?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: K-Rintaro</title>
    <description>The latest articles on DEV Community by K-Rintaro (@krintaro).</description>
    <link>https://dev.to/krintaro</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%2F498370%2F4ae9cdd1-7878-40a4-b92b-8172b1ce3e26.jpeg</url>
      <title>DEV Community: K-Rintaro</title>
      <link>https://dev.to/krintaro</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/krintaro"/>
    <language>en</language>
    <item>
      <title>AWS Cost Notification to Discord</title>
      <dc:creator>K-Rintaro</dc:creator>
      <pubDate>Sun, 07 Feb 2021 09:54:07 +0000</pubDate>
      <link>https://dev.to/krintaro/aws-cost-notification-to-discord-3e8m</link>
      <guid>https://dev.to/krintaro/aws-cost-notification-to-discord-3e8m</guid>
      <description>&lt;p&gt;AWS pricing system is very complicated, so there are many useful tools that can notify AWS cost daily or monthly.&lt;br&gt;
Many tools are developed for Slack, but I love Discord.&lt;br&gt;
Therefore, I developed AWS Cost Notification System for Discord.&lt;/p&gt;

&lt;p&gt;This system can notify "Today's AWS cost" to Discord at 23 o'clock every day.&lt;br&gt;
Also, that can notify "Last Month's AWS cost" to Discord at 23 o'clock first day of the month. (This can be changed at index.js)&lt;/p&gt;

&lt;p&gt;All source code: &lt;a href="https://github.com/K-Rintaro/aws-cost-discord-notify" rel="noopener noreferrer"&gt;https://github.com/K-Rintaro/aws-cost-discord-notify&lt;/a&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%2Fi%2Fh8xh5qlri03gq9swki71.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%2Fi%2Fh8xh5qlri03gq9swki71.png" alt="aws-cost-discord-notify" width="672" height="808"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h1&gt;
  
  
  Requirement
&lt;/h1&gt;

&lt;p&gt;node.js&lt;br&gt;
npm packages&lt;br&gt;
・aws-cost-explorer&lt;br&gt;
・dotenv&lt;br&gt;
・discord.js&lt;br&gt;
・node-cron&lt;br&gt;
・node-fetch&lt;/p&gt;
&lt;h1&gt;
  
  
  How to use
&lt;/h1&gt;

&lt;p&gt;aws-cost-discord-notify needs to use AWS Cost Explorer API.&lt;br&gt;
That costs 0.01 USD every request.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Create your Discord bot at &lt;a href="https://discord.com/developers/applications" rel="noopener noreferrer"&gt;https://discord.com/developers/applications&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Create AWS IAM user and get access key id &amp;amp; secret access key&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Example policy:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"Version"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"2012-10-17"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="nl"&gt;"Statement"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Effect"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Allow"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Action"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="s2"&gt;"ce:*"&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="nl"&gt;"Resource"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="w"&gt;
        &lt;/span&gt;&lt;span class="s2"&gt;"*"&lt;/span&gt;&lt;span class="w"&gt;
      &lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
  &lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ol&gt;
&lt;li&gt;Create .env file and set Discord token, AWS access key and AWS secret access key that you got.&lt;/li&gt;
&lt;li&gt;Get index.js from &lt;a href="https://github.com/K-Rintaro/aws-cost-discord-notify" rel="noopener noreferrer"&gt;GitHub repo&lt;/a&gt; and set your Discord channel id. You can change notification time, too.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;I hope I can be of any help to you.&lt;/p&gt;

</description>
      <category>aws</category>
      <category>javascript</category>
    </item>
    <item>
      <title>"ALL YOU NEED TO DO" IS WRITTEN HERE.</title>
      <dc:creator>K-Rintaro</dc:creator>
      <pubDate>Mon, 23 Nov 2020 10:23:20 +0000</pubDate>
      <link>https://dev.to/krintaro/all-you-need-to-do-is-written-here-d7g</link>
      <guid>https://dev.to/krintaro/all-you-need-to-do-is-written-here-d7g</guid>
      <description>&lt;h2&gt;
  
  
  doppelganger-license
&lt;/h2&gt;

&lt;p&gt;I was afraid of license violations.&lt;/p&gt;

&lt;p&gt;There are some tools that can check dependencies' licenses, but they were difficult for me to use.&lt;/p&gt;

&lt;p&gt;I wanted a tool that can tell me "all I need to do" into one file.&lt;/p&gt;

&lt;p&gt;For these reasons, I decided to make the tool. &lt;/p&gt;

&lt;p&gt;The name of tool is &lt;a href="https://github.com/K-RIntaro/doppelganger-license" rel="noopener noreferrer"&gt;"doppelganger-license"&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;doppelganger-license can tell you "all you need to do" into one file.&lt;/p&gt;

&lt;p&gt;Also, it is able to gather all license terms of dependencies.&lt;/p&gt;

&lt;p&gt;The things that you have to do to use this are only &lt;u&gt;three&lt;/u&gt;.&lt;br&gt;
1 Install doppelgangar-license&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$ npm install doppelganger-license
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;2 Make memo.txt &amp;amp; dependencies.txt&lt;/p&gt;

&lt;p&gt;3 Enter "doppelgenger-license".&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$ doppelganger-license
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It's very simple.&lt;/p&gt;

&lt;p&gt;These features are based on package-lock.json.&lt;/p&gt;

&lt;p&gt;doppelganger-license gets dependencies from this file, and searching packages at npmjs &amp;amp; jsdelivr.&lt;/p&gt;

&lt;p&gt;I think that doppelganger-license can become more useful.&lt;/p&gt;

&lt;p&gt;I would be grateful if you could contribute at GitHub repository.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/K-RIntaro/doppelganger-license" rel="noopener noreferrer"&gt;GitHub repository of doppelganger-license&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Thank you for reading.&lt;/p&gt;

</description>
      <category>github</category>
      <category>npm</category>
      <category>javascript</category>
    </item>
  </channel>
</rss>
