<?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: Ömer Çakmak</title>
    <description>The latest articles on DEV Community by Ömer Çakmak (@omercakmak).</description>
    <link>https://dev.to/omercakmak</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%2F407063%2Fe6e5bc95-9a5d-4be1-99cd-951adb9515c5.jpg</url>
      <title>DEV Community: Ömer Çakmak</title>
      <link>https://dev.to/omercakmak</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/omercakmak"/>
    <language>en</language>
    <item>
      <title>Ansible ile Nextcloud Kurulumu</title>
      <dc:creator>Ömer Çakmak</dc:creator>
      <pubDate>Thu, 03 Sep 2020 06:36:38 +0000</pubDate>
      <link>https://dev.to/omercakmak/ansible-ile-nextcloud-kurulumu-1i90</link>
      <guid>https://dev.to/omercakmak/ansible-ile-nextcloud-kurulumu-1i90</guid>
      <description>&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Pardus üzerine &lt;a href="https://dev.to/omercakmak/pardus-ansible-237g"&gt;&lt;strong&gt;Ansible&lt;/strong&gt;&lt;/a&gt; kurulum adımları&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Pardus üzerine &lt;a href="https://dev.to/omercakmak/pardus-19-server-uzerine-nextcloud-kurulumu-postgresql-veritabani-kullanilmistir-29o7"&gt;&lt;strong&gt;Nextcloud&lt;/strong&gt;&lt;/a&gt; kurulum adımları &lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Yukarıdaki makaleleri incelediyseniz şimdi ikisini birleştirerek &lt;strong&gt;Ansible&lt;/strong&gt; ile &lt;strong&gt;Nextcloud&lt;/strong&gt; kurulum hazırladım. &lt;a href="https://github.com/farukomercakmak/ansible-nap"&gt;github.com/farukomercakmak&lt;/a&gt; adresinden indirebilirsiniz.&lt;/p&gt;

&lt;p&gt;Kurulumu Pardus 19 sunucu sürümü üzerine;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Nextcloud 19&lt;/li&gt;
&lt;li&gt;Apache&lt;/li&gt;
&lt;li&gt;PostgreSQL&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;bileşenlerini kullanarak hazırladım. Umarım faydalı olur.&lt;/p&gt;

</description>
      <category>ansible</category>
      <category>pardus</category>
      <category>nextcloud</category>
      <category>postgres</category>
    </item>
    <item>
      <title>Pardus 19 Server üzerine Nextcloud Kurulumu</title>
      <dc:creator>Ömer Çakmak</dc:creator>
      <pubDate>Mon, 31 Aug 2020 09:48:51 +0000</pubDate>
      <link>https://dev.to/omercakmak/pardus-19-server-uzerine-nextcloud-kurulumu-49p9</link>
      <guid>https://dev.to/omercakmak/pardus-19-server-uzerine-nextcloud-kurulumu-49p9</guid>
      <description>&lt;p&gt;(MariaDB veritabanı kullanılmıştır)&lt;/p&gt;

&lt;h2&gt;
  
  
  Paketlerin  yüklenmesi
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo apt install apache2 php7.3 libapache2-mod-php mariadb-server php-xml php-cli php-cgi php-mysql php-mbstring php-gd php-curl php-zip wget unzip -y
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Yukarıdaki adım sonrasında sistemde yüklü olan PHP versiyonuna(7.2, 7.3 vs) ait ilgili paketler sisteme yüklenecektir.&lt;/p&gt;

&lt;h2&gt;
  
  
  Veritabanı ayarları
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo mysql -uroot -e "CREATE DATABASE nextcloud DEFAULT CHARACTER SET utf8 DEFAULT COLLATE utf8_general_ci"
sudo mysql -uroot -e "CREATE USER 'nextcloud'@'localhost' IDENTIFIED BY 'temp123'"
sudo mysql -uroot -e "GRANT ALL ON nextcloud.* TO 'nextcloud'@'localhost'";
sudo mysql -uroot -e "FLUSH PRIVILEGES";
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Yukarıdaki komutlar sonrası veritabanında;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Kullanıcı adı: nextcloud&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Parola:temp123&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Veritabanı adı:nextcloud_db&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;şeklinde oluşturulacaktır.&lt;/p&gt;

&lt;h2&gt;
  
  
  PHP ayarları
&lt;/h2&gt;

&lt;p&gt;/etc/php/7.3/apache2/php.ini dosyasında aşağıdaki;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;memory_limit = 128M
upload_max_filesize = 2M
post_max_size = 8M
max_execution_time = 30
date.timezone =
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;değerleri değiştireceğiz;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sed -i 's/memory_limit = 128M/memory_limit = 512M/g' /etc/php/7.3/apache2/php.ini
sed -i 's/upload_max_filesize = 2M/upload_max_filesize = 500M/g' /etc/php/7.3/apache2/php.ini
sed -i 's/post_max_size = 8M/post_max_size = 500M/g' /etc/php/7.3/apache2/php.ini
sed -i 's/max_execution_time = 30/max_execution_time = 300/g' /etc/php/7.3/apache2/php.ini
sed -i 's/;date.timezone =/date.timezone = Europe\/Istanbul/g' /etc/php/7.3/apache2/php.ini
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Bu adımlar sonrası aşağıdaki değerlere çekilmiş olacaktır. &lt;strong&gt;sed&lt;/strong&gt; komutlarındaki değerleri değiştirerek farklı değerler verebilirsiniz.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;memory_limit = 512M
upload_max_filesize = 500M
post_max_size = 500M
max_execution_time = 300
date.timezone = Europe/Istanbul
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;h2&gt;
  
  
  Servislerin başlatılması
&lt;/h2&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;systemctl start apache2 &amp;amp;&amp;amp; systemctl start postgresql
systemctl enable apache2 &amp;amp;&amp;amp; systemctl enable postgresql
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Bu komutlar sonrası servisler sistem başlatılırken otomatik başlayacaktır. &lt;/p&gt;

&lt;h2&gt;
  
  
  Nextcloud'un indirilmesi
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;cd /var/www/html
wget https://download.nextcloud.com/server/releases/nextcloud-19.0.1.zip
unzip nextcloud-19.0.1.zip
chown -R www-data:www-data /var/www/html/nextcloud/
chmod -R 755 /var/www/html/nextcloud/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Yukarıdaki adımlar sonrası &lt;strong&gt;nextcloud-19.0.1&lt;/strong&gt; versiyonu sisteme indirlecektir. Eğer farklı bir versiyon indirmek isterseniz &lt;strong&gt;wget&lt;/strong&gt; komutu sonrası o versiyonu yazabilirsiniz.&lt;/p&gt;

&lt;h2&gt;
  
  
  Apache ayarları
&lt;/h2&gt;

&lt;p&gt;Aşağıdaki komut ile &lt;strong&gt;nextcloud.conf&lt;/strong&gt; dosyası oluşturulur ve açılır;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;nano /etc/apache2/sites-available/nextcloud.conf
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;daha sonra bu değerler içerisine yapıştırılır;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;VirtualHost *:80&amp;gt;
 ServerAdmin admin@example.com
 DocumentRoot /var/www/html/nextcloud/
 ServerName nextcloud.example.com

 Alias /nextcloud "/var/www/html/nextcloud/"

 &amp;lt;Directory /var/www/html/nextcloud/&amp;gt;
    Options +FollowSymlinks
    AllowOverride All
    Require all granted
      &amp;lt;IfModule mod_dav.c&amp;gt;
        Dav off
      &amp;lt;/IfModule&amp;gt;
    SetEnv HOME /var/www/html/nextcloud
    SetEnv HTTP_HOME /var/www/html/nextcloud
 &amp;lt;/Directory&amp;gt;

 ErrorLog ${APACHE_LOG_DIR}/error.log
 CustomLog ${APACHE_LOG_DIR}/access.log combined
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Daha sonra aşağıdaki komutlar sıra ile çalıştırılır;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;    a2ensite nextcloud.conf
    a2enmod rewrite
    a2enmod headers
    a2enmod env
    a2enmod dir
    a2enmod mime
    systemctl restart apache2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Artık arayüze geçebiliriz
&lt;/h2&gt;

&lt;p&gt;Kurulum yaptığınız sunucu ip adresi ile herhangi bir web tarayıcısında &lt;strong&gt;&lt;a href="http://ip_adres/nextcloud"&gt;http://ip_adres/nextcloud&lt;/a&gt;&lt;/strong&gt; adresi açılır. Nextcloud yetkili kullanıcı adı/parola ve yukarıda tanımlanan veritabanı bilgileri girilerek kurulum tamamlanır. &lt;/p&gt;

</description>
      <category>pardus</category>
      <category>nextcloud</category>
      <category>mariadb</category>
      <category>linux</category>
    </item>
    <item>
      <title>Pardus 19 Server üzerine Nextcloud Kurulumu

</title>
      <dc:creator>Ömer Çakmak</dc:creator>
      <pubDate>Mon, 31 Aug 2020 08:54:23 +0000</pubDate>
      <link>https://dev.to/omercakmak/pardus-19-server-uzerine-nextcloud-kurulumu-postgresql-veritabani-kullanilmistir-29o7</link>
      <guid>https://dev.to/omercakmak/pardus-19-server-uzerine-nextcloud-kurulumu-postgresql-veritabani-kullanilmistir-29o7</guid>
      <description>&lt;p&gt;(PostgreSQL veritabanı kullanılmıştır)&lt;/p&gt;

&lt;h2&gt;
  
  
  Paketlerin  yüklenmesi
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo apt install apache2 libapache2-mod-php postgresql php-pgsql php-xml php-cli php-cgi php-mbstring php-gd php-curl php-zip wget unzip -y
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Yukarıdaki adım sonrasında sistemde yüklü olan PHP versiyonuna(7.2, 7.3 vs) ait ilgili paketler sisteme yüklenecektir.&lt;/p&gt;

&lt;h2&gt;
  
  
  Veritabanı ayarları
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;su - postgres
psql
CREATE USER nextcloud WITH PASSWORD 'temp123';
CREATE DATABASE nextcloud_db;
GRANT ALL PRIVILEGES ON DATABASE nextcloud_db to nextcloud;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Yukarıdaki komutlar sonrası veritabanında;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Kullanıcı adı: nextcloud&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Parola:temp123&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Veritabanı adı:nextcloud_db&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;şeklinde oluşturulacaktır. Veritabanı oluşturulduktan sonra arzu ederseniz;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;select * from pg_database;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;komutu ile veritabanlarını listeleyebilirsiniz. Daha sonra;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;\q
exit
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;komutları ile Postgresql'den çıkabilirsiniz.&lt;/p&gt;

&lt;h2&gt;
  
  
  PHP ayarları
&lt;/h2&gt;

&lt;p&gt;/etc/php/7.3/apache2/php.ini dosyasında aşağıdaki;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;memory_limit = 128M
upload_max_filesize = 2M
post_max_size = 8M
max_execution_time = 30
date.timezone =
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;değerleri değiştireceğiz;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sed -i 's/memory_limit = 128M/memory_limit = 512M/g' /etc/php/7.3/apache2/php.ini
sed -i 's/upload_max_filesize = 2M/upload_max_filesize = 500M/g' /etc/php/7.3/apache2/php.ini
sed -i 's/post_max_size = 8M/post_max_size = 500M/g' /etc/php/7.3/apache2/php.ini
sed -i 's/max_execution_time = 30/max_execution_time = 300/g' /etc/php/7.3/apache2/php.ini
sed -i 's/;date.timezone =/date.timezone = Europe\/Istanbul/g' /etc/php/7.3/apache2/php.ini
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Bu adımlar sonrası aşağıdaki değerlere çekilmiş olacaktır. &lt;strong&gt;sed&lt;/strong&gt; komutlarındaki değerleri değiştirerek farklı değerler verebilirsiniz.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;memory_limit = 512M
upload_max_filesize = 500M
post_max_size = 500M
max_execution_time = 300
date.timezone = Europe/Istanbul
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;
&lt;h2&gt;
  
  
  Servislerin başlatılması
&lt;/h2&gt;


&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;systemctl start apache2 &amp;amp;&amp;amp; systemctl start postgresql
systemctl enable apache2 &amp;amp;&amp;amp; systemctl enable postgresql
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Bu komutlar sonrası servisler sistem açılırken otomatik başlayacaktır. &lt;/p&gt;

&lt;h2&gt;
  
  
  Nextcloud'un indirilmesi
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;cd /var/www/html
wget https://download.nextcloud.com/server/releases/nextcloud-19.0.1.zip
unzip nextcloud-19.0.1.zip
chown -R www-data:www-data /var/www/html/nextcloud/
chmod -R 755 /var/www/html/nextcloud/
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Yukarıdaki adımlar sonrası &lt;strong&gt;nextcloud-19.0.1&lt;/strong&gt; versiyonu sisteme indirlecektir. Eğer farklı bir versiyon indirmek isterseniz &lt;strong&gt;wget&lt;/strong&gt; komutu sonrası o versiyonu yazabilirsiniz.&lt;/p&gt;

&lt;h2&gt;
  
  
  Apache ayarları
&lt;/h2&gt;

&lt;p&gt;Aşağıdaki komut ile &lt;strong&gt;nextcloud.conf&lt;/strong&gt; dosyası oluşturulur ve açılır;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;nano /etc/apache2/sites-available/nextcloud.conf
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;daha sonra bu değerler içerisine yapıştırılır;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;VirtualHost *:80&amp;gt;
 ServerAdmin admin@example.com
 DocumentRoot /var/www/html/nextcloud/
 ServerName nextcloud.example.com

 Alias /nextcloud "/var/www/html/nextcloud/"

 &amp;lt;Directory /var/www/html/nextcloud/&amp;gt;
    Options +FollowSymlinks
    AllowOverride All
    Require all granted
      &amp;lt;IfModule mod_dav.c&amp;gt;
        Dav off
      &amp;lt;/IfModule&amp;gt;
    SetEnv HOME /var/www/html/nextcloud
    SetEnv HTTP_HOME /var/www/html/nextcloud
 &amp;lt;/Directory&amp;gt;

 ErrorLog ${APACHE_LOG_DIR}/error.log
 CustomLog ${APACHE_LOG_DIR}/access.log combined
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Daha sonra aşağıdaki komutlar sıra ile çalıştırılır;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;a2ensite nextcloud.conf
a2enmod rewrite
a2enmod headers
a2enmod env
a2enmod dir
a2enmod mime
systemctl restart apache2
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Artık arayüze geçebiliriz
&lt;/h2&gt;

&lt;p&gt;Kurulum yaptığınız sunucu ip adresi ile herhangi bir web tarayıcısında &lt;strong&gt;&lt;a href="http://ip_adres/nextcloud"&gt;http://ip_adres/nextcloud&lt;/a&gt;&lt;/strong&gt; adresi açılır. Nextcloud yetkili kullanıcı adı/parola ve yukarıda tanımlanan veritabanı bilgileri girilerek kurulum tamamlanır. &lt;/p&gt;

</description>
      <category>pardus</category>
      <category>nextcloud</category>
      <category>postgres</category>
      <category>linux</category>
    </item>
    <item>
      <title>
Pardus’ta VPN ile Giriş Ekranına Düşmek</title>
      <dc:creator>Ömer Çakmak</dc:creator>
      <pubDate>Thu, 20 Aug 2020 10:33:30 +0000</pubDate>
      <link>https://dev.to/omercakmak/pardus-ta-vpn-ile-giris-ekranina-dusmek-4fnn</link>
      <guid>https://dev.to/omercakmak/pardus-ta-vpn-ile-giris-ekranina-dusmek-4fnn</guid>
      <description>&lt;p&gt;Sistem güncellenir ve vnc için gerekli olan paket kurulur.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo apt-get update
sudo apt-get install tightvncserver
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Daha sonra Lightdm konfigurasyon dosyası açılarak aşağıdaki satırlar açılır ve enable değeri true olarak değiştirilir;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo vi /etc/lightdm/lightdm.conf

[VNCServer]
enabled=true
command=Xvnc
port=5900
width=1024
height=768
depth=8
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Lightdm servisi yeniden başlatılır;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo systemctl restart lightdm.service
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Yukarıdaki adımlardan sonra vpn ile gelerek oturum açma ekranına(Lightdm) düşebilirsiniz.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Pardus &amp; Ansible</title>
      <dc:creator>Ömer Çakmak</dc:creator>
      <pubDate>Thu, 20 Aug 2020 10:31:31 +0000</pubDate>
      <link>https://dev.to/omercakmak/pardus-ansible-237g</link>
      <guid>https://dev.to/omercakmak/pardus-ansible-237g</guid>
      <description>&lt;p&gt;Ansible’ı yüklemek için(Debian,Pardus);&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;sudo apt update -y

sudo apt install ansible -y
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;daha sonra bu bilgisayar ssh-key üretip istemcilere bu ssh-key’i ileteceğiz.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ssh-keygen -t rsa

Enter file in which to save the key (/home/pardus/.ssh/id_rsa):
/home/pardus/.ssh/id_rsa already exists.
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /home/pardus/.ssh/id_rsa.
Your public key has been saved in /home/pardus/.ssh/id_rsa.pub.
The key fingerprint is:
SHA256:EgUoPrRq9lFTNoWfVnm9MC+gGPOQnXHhJ4voCOiEq+s pardus@ansible-server
The key’s randomart image is:
+—[RSA 2048]—-+
| …*oooo . |
| o . @ oo+ + . |
| o o + O +oo.+ .|
|. = o o.*. +. o |
|.+ o. o.S. . . |
|++ .. o. |
|+.. .. . |
|. . |
|+E |
+—-[SHA256]—–+
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;“/home/pardus/.ssh/id_rsa” ile ssh-key’in oluşturulacağı yer belirlenir, standardına dokunmadan ilerliyoruz. “passphrase” sorusuna herhangi bir parola girmeden devam edelim, key göndereceğimiz için parola ile bağlantı yapmayacağız.&lt;/p&gt;

&lt;p&gt;Daha sonra bu oluşturulan keyi istemciye göndermemiz gerekiyor, bunu için;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ssh-copy-id istemci@ip_adresi
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;ile gönderim sağlanır.&lt;/p&gt;

&lt;p&gt;Not: Daha önce gönderim yapıldı ve yenilenmesi isteniyorsa -f parametresi kullanılır, yani;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ssh-copy-id -f istemci@ip_adresi
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;şeklinde kullanılır.&lt;/p&gt;

&lt;p&gt;Ansbible standart dosyalarını /etc/ansible/ dizini altında tutar, biz ise ile çalışmak için bir dizin oluşturacağız;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;cd ~

mkdir ansible &amp;amp;&amp;amp; cd ansible

cp -rf /etc/ansible/* .

pardus@ansible-server:~/ansible$ ls -la
total 32
drwxr-xr-x 2 root root 4096 Aug 13 18:58 .
drwxr-xr-x 6 pardus pardus 4096 Aug 14 06:05 ..
-rw-r–r– 1 root root 20265 Aug 13 18:54 ansible.cfg
-rw-r–r– 1 root root 1022 Aug 13 18:58 hosts
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;ansible.cfg dosyasında “inventory” değerini;&lt;/p&gt;

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

&lt;/div&gt;

&lt;p&gt;şeklinde değiştiriyoruz.&lt;/p&gt;

&lt;p&gt;Daha sonra “hosts” dosyasına;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[parduslar]
192.168.122.86
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;şeklinde hostları ekliyoruz. Birden fazla istemci alt alta ip veya hostname şeklinde eklenebilir. Aynı şekilde benzer istemciler gruplanabilir. Örneğin Centos istemciler;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[centos]
192.168.122.42
192.168.122.14
192.168.122.57
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;şeklinde eklenebilir. Bu sayede gönderilecek görev bu gruplamaya göre iletilebilir. Yani centos istemcilere ayrı, ubuntu istemcilere ayrı veya all seçeneği ile tüm istemcilere aynı görev gönderilebilir.&lt;/p&gt;

&lt;p&gt;Gelelim görev göndermeye, bunun için ansible dizininde iken;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ansible -i hosts -m ping all
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;komutu ile ping atabiliriz. Bu komutun çıktısı;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;192.168.122.86 | SUCCESS =&amp;gt; {
“changed”: false,
“ping”: “pong”
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;şeklinde olacaktır.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ansible -i hosts -a “ip a” all
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;şeklinde “-a” parametresi ile karşıdaki istemcilerde komut çalıştırışabilir. “all” parametresi yerine;&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;ansible -i hosts -a “ip a” parduslar
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;şeklinde sadece parduslar grubunda olan istemcilere uygulanır.&lt;/p&gt;

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