05.12.2022 günün özeti

 wsl2 üzerinde kullanıcı şifresini resetlemek

https://itsfoss.com/reset-linux-password-wsl/

wsl üzerinde nodejs kurmak

https://learn.microsoft.com/en-us/windows/dev-environment/javascript/nodejs-on-wsl

nginx ayarlar hakkında detaylı anlatım



wsl üzerinde nginx kurulumu

https://www.cloudbooklet.com/how-to-install-node-js-with-nvm-and-nginx-on-ubuntu-22-04/

wsl üzerinde nginx çalıştırma

https://www.ntweekly.com/2017/09/08/run-linux-nginx-windows-server-insider-wsl/

wsl üzerinde diske erişmek için

https://linuxnightly.com/mount-and-access-hard-drives-in-windows-subsystem-for-linux-wsl/

\\wsl$

alternatif

https://devblogs.microsoft.com/commandline/access-linux-filesystems-in-windows-and-wsl-2/

nginx çalıştıktan sonra localhost yazarak kendi sunucumuza erişiyoruz

burada sudo chmod 777 /var/www/index.nginx-debian.html editledim ve değişiklik hemen yansıdı

aktif servisleri listele

https://www.configserverfirewall.com/ubuntu-linux/ubuntu-list-services-command/

wsl networking

https://learn.microsoft.com/en-us/windows/wsl/networking

alternatif ubuntu üzerinde nodejs kurmak

https://linuxize.com/post/how-to-install-node-js-on-ubuntu-20-04/

Burada etc/nginx/sites-enabled/yourdomainname.conf 



server {
     listen [::]:80;
     listen 80;

     server_name localhost yourdomainname.com www.yourdomainname.com;

     location / {
         proxy_pass http://backendserver;
         proxy_http_version 1.1;
         proxy_set_header Upgrade $http_upgrade;
         proxy_set_header Connection 'upgrade';
         proxy_set_header Host $host;
         proxy_cache_bypass $http_upgrade;
    }
}

Burada /etc/nginx.conf 

user www-data;
#burada görülen kavramlar bir adet directivetir ve key value olarak adland
worker_processes auto;
pid /run/nginx.pid;
include /etc/nginx/modules-enabled/*.conf;
#curly braces arasında kalan değerler ise context olarak adlandırılır.

events {
    worker_connections 768;
    # multi_accept on;
}

http {

    ##
    # Basic Settings
    ##

    sendfile on;
    tcp_nopush on;
    tcp_nodelay on;
    keepalive_timeout 65;
    types_hash_max_size 2048;
    # server_tokens off;

    # server_names_hash_bucket_size 64;
    # server_name_in_redirect off;

    include /etc/nginx/mime.types;
    default_type application/octet-stream;

    ##
    # SSL Settings
    ##

    ssl_protocols TLSv1 TLSv1.1 TLSv1.2 TLSv1.3; # Dropping SSLv3, ref: POODLE
    ssl_prefer_server_ciphers on;

    ##
    # Logging Settings
    ##

    access_log /var/log/nginx/access.log;
    error_log /var/log/nginx/error.log;

    ##
    # Gzip Settings
    ##

    gzip on;

    # gzip_vary on;
    # gzip_proxied any;
    # gzip_comp_level 6;
    # gzip_buffers 16 8k;
    # gzip_http_version 1.1;
    # gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;

    ##
    # Virtual Host Configs
    ##
    upstream backendserver {
          server 127.0.0.1:7777;
          server 127.0.0.1:7778;
    }

    include /etc/nginx/conf.d/*.conf;
    include /etc/nginx/sites-enabled/*;
}


#mail {
#   # See sample authentication script at:
#   # http://wiki.nginx.org/ImapAuthenticateWithApachePhpScript
#
#   # auth_http localhost/auth.php;
#   # pop3_capabilities "TOP" "USER";
#   # imap_capabilities "IMAP4rev1" "UIDPLUS";
#
#   server {
#       listen     localhost:110;
#       protocol   pop3;
#       proxy      on;
#   }
#
#   server {
#       listen     localhost:143;
#       protocol   imap;
#       proxy      on;
#   }
#}

Yorumlar

Bu blogdaki popüler yayınlar

22.06.2020 - 26.06.2020 arası işler

Asp.net RestSharp ile data post etmek

List Box Item içindeki elemanları aşağı veya yukarı taşımak