<?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: josnin</title>
    <description>The latest articles on DEV Community by josnin (@josnin).</description>
    <link>https://dev.to/josnin</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%2F472764%2F8f89a273-4dca-4f39-9654-300168b82af2.png</url>
      <title>DEV Community: josnin</title>
      <link>https://dev.to/josnin</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/josnin"/>
    <language>en</language>
    <item>
      <title>Jenkins in Podman</title>
      <dc:creator>josnin</dc:creator>
      <pubDate>Fri, 17 Mar 2023 14:37:34 +0000</pubDate>
      <link>https://dev.to/josnin/jenkins-in-podman-4f1g</link>
      <guid>https://dev.to/josnin/jenkins-in-podman-4f1g</guid>
      <description>&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;podman volume create jenkins_home
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;podman run -u root -p 8080:8080 -p 50000:50000 -d  -v jenkins_home:/var/jenkins_home jenkins/jenkins:lts-jdk11
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;podman ps
CONTAINER ID  IMAGE                                COMMAND     CREATED        STATUS            PORTS                                             NAMES
14e76c1d7f1b  docker.io/jenkins/jenkins:lts-jdk11              2 minutes ago  Up 2 minutes ago  0.0.0.0:8080-&amp;gt;8080/tcp, 0.0.0.0:50000-&amp;gt;50000/tcp  intelligent_gates

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

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;podman logs 14e76c1d7f1b
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Reference: &lt;a href="https://www.youtube.com/watch?v=qGLEuXK46gQ"&gt;https://www.youtube.com/watch?v=qGLEuXK46gQ&lt;/a&gt;&lt;br&gt;
Blue Ocean: &lt;a href="https://www.youtube.com/watch?v=ekiL2AUToks"&gt;https://www.youtube.com/watch?v=ekiL2AUToks&lt;/a&gt;&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Use Gmail for SMTP</title>
      <dc:creator>josnin</dc:creator>
      <pubDate>Fri, 17 Mar 2023 14:26:00 +0000</pubDate>
      <link>https://dev.to/josnin/use-gmail-for-smtp-mpp</link>
      <guid>https://dev.to/josnin/use-gmail-for-smtp-mpp</guid>
      <description>&lt;h2&gt;
  
  
  Login to your gmail account and Goto Account &amp;gt; Security
&lt;/h2&gt;

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

&lt;h2&gt;
  
  
  Enable 2 Step verification
&lt;/h2&gt;

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

&lt;h2&gt;
  
  
  Look for the App Password
&lt;/h2&gt;

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

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

&lt;h2&gt;
  
  
  Select App &amp;gt; Other &amp;gt; Click Generate
&lt;/h2&gt;

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

</description>
    </item>
    <item>
      <title>LVM+VirtualBox (Extend Disk Size)</title>
      <dc:creator>josnin</dc:creator>
      <pubDate>Sat, 15 May 2021 05:42:05 +0000</pubDate>
      <link>https://dev.to/josnin/lvm-virtualbox-extend-disk-size-1bb8</link>
      <guid>https://dev.to/josnin/lvm-virtualbox-extend-disk-size-1bb8</guid>
      <description>&lt;ul&gt;
&lt;li&gt;Increase your VirtualBox HD first&lt;/li&gt;
&lt;/ul&gt;

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

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

&lt;ul&gt;
&lt;li&gt;We need to convert the available space (/dev/sda) into a new partitions , fdisk is the utility to do so&lt;/li&gt;
&lt;/ul&gt;

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

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

&lt;ul&gt;
&lt;li&gt;We cannot just add to the Volume Group, there is something that we need to change before doing so (Partition Type).
now we have a new partition /dev/sda4&lt;/li&gt;
&lt;/ul&gt;

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

&lt;ul&gt;
&lt;li&gt;In order to create a Physical volume, we are going to use pvcreate&lt;/li&gt;
&lt;/ul&gt;

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

&lt;ul&gt;
&lt;li&gt;Use pvs command, If you wanna know how many Physical Volume the machine is setup, it can show the Volume Group assign to the new partition.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;for now,/dev/sda4 is not yet assign to any VG&lt;/p&gt;

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

&lt;ul&gt;
&lt;li&gt;We need to extend the Volume Group (VG) and assign the new partition /dev/sda4&lt;/li&gt;
&lt;/ul&gt;

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

&lt;ul&gt;
&lt;li&gt;We need to extend the Logical Volume (LV)&lt;/li&gt;
&lt;/ul&gt;

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

&lt;ul&gt;
&lt;li&gt;Now it will have new 8G available space&lt;/li&gt;
&lt;/ul&gt;

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

</description>
    </item>
    <item>
      <title>Does Django need a database?</title>
      <dc:creator>josnin</dc:creator>
      <pubDate>Sat, 24 Oct 2020 03:42:01 +0000</pubDate>
      <link>https://dev.to/josnin/does-django-need-a-database-55m1</link>
      <guid>https://dev.to/josnin/does-django-need-a-database-55m1</guid>
      <description>&lt;p&gt;Depends on what you are trying to build though in most cases it will require to set up a database if you want to store the data permanently&lt;/p&gt;

&lt;p&gt;Django supports a lighter version of database like SQLlite (out of the box) so it's easy to enable the database functionality&lt;/p&gt;

&lt;p&gt;To be honest, one of Django strength is handling database, they have an efficient way of handling it using their own ORM, so if your project does not require any database activity there is no point in using Django it may be overkill for your project&lt;/p&gt;

</description>
      <category>django</category>
      <category>database</category>
    </item>
    <item>
      <title>Is Django still good?</title>
      <dc:creator>josnin</dc:creator>
      <pubDate>Sat, 24 Oct 2020 03:39:01 +0000</pubDate>
      <link>https://dev.to/josnin/is-django-still-good-3o3k</link>
      <guid>https://dev.to/josnin/is-django-still-good-3o3k</guid>
      <description>&lt;p&gt;Yes Django still exciting to use especially now they are moving towards full async (though their own ORM and others are not yet in async)&lt;/p&gt;

&lt;p&gt;Django template system may not be that exciting after React, Angular, &amp;amp; Vue front end framework came but still, Django is a loosely coupled architecture that you can easily support any type of front end framework.&lt;/p&gt;

&lt;p&gt;Django has a huge community and the ecosystem keeps on growing that keep it at least with the current technology&lt;/p&gt;

</description>
      <category>django</category>
    </item>
    <item>
      <title>389ds in Fedora 31</title>
      <dc:creator>josnin</dc:creator>
      <pubDate>Mon, 21 Sep 2020 15:02:18 +0000</pubDate>
      <link>https://dev.to/josnin/389ds-in-fedora-31-3i76</link>
      <guid>https://dev.to/josnin/389ds-in-fedora-31-3i76</guid>
      <description>&lt;h1&gt;
  
  
  Installation
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[johnny2020@localhost Documents]$ sudo dnf install 389-ds-base
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://directory.fedoraproject.org/docs/389ds/releases/release-1-4-2-4.html"&gt;389ds docs&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  Local DNS
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;vim /etc/hosts

127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
192.168.1.74 myhost myhost.tech.com
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  Setup
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost Documents]# dscreate interactive
Install Directory Server (interactive mode)
===========================================

Enter system's hostname [myhost.tech.com]:

Enter the instance name [myhost]:

Enter port number [389]:

Create self-signed certificate database [yes]:

Enter secure port number [636]:

Enter Directory Manager DN [cn=Directory Manager]:

Enter the Directory Manager password:
Confirm the Directory Manager Password:

Enter the database suffix (or enter "none" to skip) [dc=myhost,dc=tech,dc=com]:

Create sample entries in the suffix [no]: yes

Do you want to start the instance after the installation? [yes]: 

Are you ready to install? [no]: yes
Starting installation...
Starting installation...
Completed installation for myhost

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Create Group (sn)
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Cant provide gidNumber

[root@papaitan Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" group create
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Enter value for cn : Family
Successfully created Family

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Create Posix Group
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Can provide gidNumber

[root@papaitan Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" posixgroup create
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Enter value for cn : Family2
Enter value for gidNumber : 1010
Successfully created Family2

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Modify PosixGroup gidNumber
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@papaitan Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" posixgroup modify Family2 replace:gidNumber:1011
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Successfully modified cn=Family2,ou=groups,dc=myhost,dc=tech,dc=com

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Create User
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" user create
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Enter value for uid : jonnny2020
Enter value for cn : jonnny2020
Enter value for displayName : Johnny
Enter value for uidNumber : 1010
Enter value for gidNumber : 1010
Enter value for homeDirectory : /home/johnny2020
Successfully created johnny2020

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Get User
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" user get johnny2020
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
dn: uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com
cn: johnny2020
displayName: Johnny
gidNumber: 1010
homeDirectory: /home/johnny2020
objectClass: top
objectClass: nsPerson
objectClass: nsAccount
objectClass: nsOrgPerson
objectClass: posixAccount
uid: johnny2020
uidNumber: 1010

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Adding Group to User
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" group add_member Family uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
added member: uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Adding PosixGroup to User
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" group add_member Family2 uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
added member: uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Removing Group to User
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" group remove_member Family uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
removed member: uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Reset Password
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" account reset_password uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Enter new password for uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com :
CONFIRM - Enter new password for uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com :
reset password for uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  LDAP search
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost Documents]# ldapsearch -x -b "dc=myhost,dc=tech,dc=com"

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Enable memberof plugin
&lt;/h1&gt;

&lt;h3&gt;
  
  
  Required for sssd enablement
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost Documents]# dsconf ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" plugin memberof status
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Plugin 'MemberOf Plugin' is disabled
[root@myhost Documents]# dsconf ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" plugin memberof enable
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Enabled plugin 'MemberOf Plugin'

[root@myhost Documents]# dsctl myhost restart
Instance "myhost" has been restarted

[root@myhost Documents]# dsconf ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" plugin memberof set --scope "dc=myhost,dc=tech,dc=com"
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Successfully changed the cn=MemberOf Plugin,cn=plugins,cn=config

[root@myhost Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" user modify kirsten add:objectclass:nsmemberof
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Successfully modified uid=kirsten,ou=people,dc=myhost,dc=tech,dc=com


[root@myhost Documents]# dsconf ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" plugin memberof fixup "dc=myhost,dc=tech,dc=com"
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Attempting to add task entry...
Successfully added task entry


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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Login Using 389-ds LDAP
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost Documents]# dnf install sssd
Last metadata expiration check: 1:40:56 ago on Sat 28 Mar 2020 09:31:30 PM +08.
Package sssd-2.2.3-13.fc31.x86_64 is already installed.
Dependencies resolved.
Nothing to do.
Complete!
[root@myhost Documents]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" client_config sssd.conf
389-admin-1.1.46-3.fc30.2.x86_64.rpm     -h                                       sfayn/
389-ds-console-1.2.16-8.fc30.noarch.rpm  --help                                   sfayn_gqlserver/
code/                                    ldap.ldif                                stunnel/
cookbook/                                .ldap.ldif.swp                           subscription.js
djcms_blogs/                             my-app/                                  test1/
docker-files/                            mysite/                                  test_api.py
env/                                     mysqld_kill_or_term.stp                  testdocker/
env3/                                    new_group.ldif                           test_r/
filereader/                              ng5/                                     test_sse/
flask_sse/                               ng-carpark/                              testvim
graphene-django/                         ng-reactive-forms/                       tmuxp_test.yaml
graphql/                                 out.csv
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  Add loginShell /bin/bash to user
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost jay2020]# dsidm ldap://myhost.tech.com:389 -b "dc=myhost,dc=tech,dc=com" user modify johnny2020 add:loginShell:/bin/bash
Enter Bind DN: cn=Directory Manager
Enter password for cn=Directory Manager on ldap://myhost.tech.com:389:
Successfully modified uid=johnny2020,ou=people,dc=myhost,dc=tech,dc=com

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Authselect if you want to auto-create home 
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;998  authselect select sssd with-mkhomedir --force
  999  systemctl enable oddjobd.service
 1000  systemctl start oddjobd.service



[root@myhost jay2020]# authselect apply-changes
Changes were successfully applied.

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Issue if you can't ssh 
&lt;/h1&gt;

&lt;h3&gt;
  
  
  Bec. it can't find the TLS certificate, meantime disable the TLS require cert by assign never
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[root@myhost jay2020]# systemctl restart sssd

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

&lt;/div&gt;



&lt;h1&gt;
  
  
  Reference
&lt;/h1&gt;

&lt;p&gt;&lt;a href="https://directory.fedoraproject.org/docs/389ds/howto/howto-users-and-groups.html"&gt;389ds-how-to-users-and-groups&lt;/a&gt;&lt;/p&gt;

</description>
      <category>linux</category>
      <category>opensource</category>
      <category>tutorial</category>
    </item>
    <item>
      <title>Podman $XDG_RUNTIME_DIR not set</title>
      <dc:creator>josnin</dc:creator>
      <pubDate>Mon, 21 Sep 2020 13:51:30 +0000</pubDate>
      <link>https://dev.to/josnin/podman-xdgruntimedir-not-set-2l2n</link>
      <guid>https://dev.to/josnin/podman-xdgruntimedir-not-set-2l2n</guid>
      <description>&lt;h1&gt;
  
  
  OS
&lt;/h1&gt;

&lt;p&gt;Fedora 31&lt;/p&gt;

&lt;h1&gt;
  
  
  Work around
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;To add the command
su root
vim /etc/bashrc
export XDG_RUNTIME_DIR=/run/user/$UID
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;su root
mkdir /run/user/1002
chown johnny2020:johnny2020 1002
chmod 700 1002
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h1&gt;
  
  
  Create storage.conf
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;su johnny2020
vim ~/.config/containers/storage.conf

[storage]
  driver = "overlay"
  runroot = "/run/user/1002/containers"
  graphroot = "/home/johnny2020/.local/share/containers/storage"
  [storage.options]
    size = ""
    remap-uids = ""
    remap-gids = ""
    ignore_chown_errors = ""
    remap-user = ""
    remap-group = ""
    skip_mount_home = ""
    mount_program = "/usr/bin/fuse-overlayfs"
    mountopt = ""
    [storage.options.aufs]
      mountopt = ""
    [storage.options.btrfs]
      min_space = ""
      size = ""
    [storage.options.thinpool]
      autoextend_percent = ""
      autoextend_threshold = ""
      basesize = ""
      blocksize = ""
      directlvm_device = ""
      directlvm_device_force = ""
      fs = ""
      log_level = ""
      min_free_space = ""
      mkfsarg = ""
      mountopt = ""
      size = ""
      use_deferred_deletion = ""
      use_deferred_removal = ""
      xfs_nospace_max_retries = ""
    [storage.options.overlay]
      ignore_chown_errors = ""
      mountopt = ""
      mount_program = ""
      size = ""
      skip_mount_home = ""
    [storage.options.vfs]
      ignore_chown_errors = ""
    [storage.options.zfs]
      mountopt = ""
      fsname = ""
      size = ""

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

&lt;/div&gt;



&lt;h3&gt;
  
  
  It will only create the directory /run/user/$UID  if you login via ssh
&lt;/h3&gt;

&lt;h1&gt;
  
  
  Networking
&lt;/h1&gt;

&lt;p&gt;&lt;a href="https://www.redhat.com/sysadmin/container-networking-podman"&gt;container-networking-podman&lt;/a&gt;&lt;/p&gt;

&lt;h1&gt;
  
  
  podman cp
&lt;/h1&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[johnny2020@localhost ~]$ podman cp --pause /home/jos/myfile testpo:/tmp/
Error: invalid arguments /home/johnny2020/myfile, testpo:/tmp/ you must use just one container
[johnny2020@localhost ~]$ podman cp --pause /home/johnny2020/emyfile testpo:/tmp/
Error: invalid arguments /home/johnny2020/emyfile, testpo:/tmp/ you must use just one container
[johnny2020@localhost ~]$ podman cp --pause /home/johnny2020/myfile testpo:/tmp/
Error: invalid arguments /home/johnny2020/myfile, testpo:/tmp/ you must use just one container
[johnny2020@localhost ~]$ podman cp --pause /home/johnny2020/myfile /tmp
Error: invalid arguments /home/johnny2020/myfile, /tmp you must use just one container
[johnny2020@localhost ~]$ podman ps
CONTAINER ID  IMAGE                           COMMAND               CREATED         STATUS             PORTS                  NAMES
b73dc0a99f2f  docker.io/library/nginx:latest  nginx -g daemon o...  17 minutes ago  Up 13 minutes ago  0.0.0.0:37895-&amp;gt;80/tcp  testpos
[johnny2020@localhost ~]$ podman cp --pause /home/johnny2020/myfile b73dc0a99f2f:/tmp/
Error: can not pause containers on rootless containers with cgroup V1: this container does not have a cgroup
[johnny2020@localhost ~]$ podman cp /home/johnny2020/myfile b73dc0a99f2f:/tmp/
[johnny2020@localhost ~]$

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

&lt;/div&gt;



</description>
      <category>devops</category>
      <category>linux</category>
      <category>tutorial</category>
    </item>
  </channel>
</rss>
