1. Halo Guest, pastikan Anda selalu menaati peraturan forum sebelum mengirimkan post atau thread baru.

[ASK] Masalah SSL Single Certificate pada WordPress Multisite

Discussion in 'Hosting & Domain' started by siprof, Sep 10, 2014.

  1. siprof

    siprof Reviewer

    Joined:
    Jun 4, 2011
    Messages:
    845
    Likes Received:
    28
    Gini gan, ane bikin blog kecil dual language, karena dual language ane pake WordPress Multisite.

    Lalu blog ane itu ane pasang SSL. Nah, masalahnya SSL wildcard mahal banget, so ane beli yg single certificate.

    Kemudian ane redirect semua HTTP ke HTTPS.

    Masalahnya muncul ketika subdomain.domain.com diakses muncul warning (krn memang SSL nya hanya untuk domain.com saja)

    Pertanyaan ane gmn caranya membuat khusus subdomain.domain.com bisa balik ke HTTP ya gan?

    Oh iya, ane pake NGINX
     
  2. be_honest

    be_honest Super Hero

    Joined:
    Jun 2, 2009
    Messages:
    1,836
    Likes Received:
    246
    Location:
    cockpit
    Itu di Dashboard > Setting , bagian WordPress Address (URL) dan Site Address (URL) , sudah di set http saja?
     
  3. markhard

    markhard Ads.id Pro

    Joined:
    Apr 20, 2008
    Messages:
    310
    Likes Received:
    9
    Location:
    RevTI.com Webhosting
    ini setting redirectnya pakai setting di nginx atau di wordpressnya? trus setting di nginx nya apakah untuk subdomainnya juga di wildcard?
     
  4. siprof

    siprof Reviewer

    Joined:
    Jun 4, 2011
    Messages:
    845
    Likes Received:
    28
    Uhhh bagian Setting > General kan maksud agan? Kok di WP MU settingan tsb ga ada ya?
     
  5. BurgerKiLL

    BurgerKiLL Ads.id Pro

    Joined:
    May 29, 2013
    Messages:
    476
    Likes Received:
    46
    Location:
    Just BurgerKill Fans
    maaf, saya masih bingung liat postingannya
    om pakai ssl premium darimana? trus input certificate dimana?
     
  6. aldhy

    aldhy Hosting Group _ ▂ ▃ ▅ ▆ █

    Joined:
    Mar 17, 2013
    Messages:
    1,731
    Likes Received:
    104
    Location:
    Cirebon
    untuk mengarahkan ke https sebenarnya cukup dari dashboard WP saja di halaman setting > generall , ganti urlnya dari http ke https
     
  7. siprof

    siprof Reviewer

    Joined:
    Jun 4, 2011
    Messages:
    845
    Likes Received:
    28
    Ane settingnya lewat nginx, karena di wordpressnya kalo pake multisite, ane liat settingan di general beda dgn wordpress biasa...

    Ane pake Positive SSL yg paling murah, input certificate nya di VPS

    Ini kode nginx ane:
    Code:
    server {
            listen 80;
            return 301 https://$host$request_uri;
    
            server_name *.example.com example.com;
            root /home/username/domains/example.com/public_html;
            access_log off;
            error_log off;
    
            index index.php index.html index.htm;
            error_page 404 /404.html;
    
            location / {
                try_files $uri $uri/ /index.php?$args;
            }
    
            [...]
    
            # Rewrite rules for WordPress Multi-site.
            if (!-e $request_filename) {
            rewrite /wp-admin$ $scheme://$host$uri/ permanent;
            rewrite ^/[_0-9a-zA-Z-]+(/wp-.*) $1 last;
            rewrite ^/[_0-9a-zA-Z-]+(/.*\.php)$ $1 last;
            }
    }
    
    
    server {
            listen 443 ssl spdy;
    
            server_name *.example.com example.com;
            root /home/username/domains/example.com/public_html;
            access_log off;
            error_log off;
    
            index index.php index.html index.htm;
            error_page 404 /404.html;
    
            ssl on;
            ssl_certificate /etc/ssl/certs/ssl-bundle.crt;
            ssl_certificate_key /etc/ssl/private/myserver.key;
    
            ssl_session_timeout 5m;
    
            ssl_protocols SSLv3 TLSv1 TLSv1.1 TLSv1.2;
            ssl_ciphers ALL:!aNULL:!MD5:!ADH:!eNULL:!LOW:!EXP:RC4+RSA:+HIGH:+MEDIUM;
            ssl_prefer_server_ciphers on;
    
            location / {
                try_files $uri $uri/ /index.php?$args;
            }
    
            [...]
    
            # Rewrite rules for WordPress Multi-site.
            if (!-e $request_filename) {
            rewrite /wp-admin$ $scheme://$host$uri/ permanent;
            rewrite ^/[_0-9a-zA-Z-]+(/wp-.*) $1 last;
            rewrite ^/[_0-9a-zA-Z-]+(/.*\.php)$ $1 last;
            }
    }
    
     
  8. BurgerKiLL

    BurgerKiLL Ads.id Pro

    Joined:
    May 29, 2013
    Messages:
    476
    Likes Received:
    46
    Location:
    Just BurgerKill Fans
    ya pantes ke gabung, wong ssl nya di input pada vhost yg notabene pakai wildcard

    monggo dipisah khusus untuk CN nya aja om
     
    siprof likes this.
  9. Altrisya03

    Altrisya03 The Doctor

    Joined:
    Feb 20, 2013
    Messages:
    531
    Likes Received:
    46
    Location:
    Pos Satpam KPK
    IDEM gan dgn yang ini.....
     
  10. siprof

    siprof Reviewer

    Joined:
    Jun 4, 2011
    Messages:
    845
    Likes Received:
    28
    Thanks gan! Setelah ane bikin vhost khusus buat subdomain.example.com akhirnya bisa. :gembira:

    Code:
    server {
            listen 80;
            return 301 https://$host$request_uri;
    
            server_name www.example.com example.com;
    
            [...]
    
    }
    
    server {
            listen 443 ssl spdy;
    
            server_name www.example.com example.com;
    
            [...]
    
    }
    
    server {
            listen 80;
    
            server_name subdomain.example.com;
    
            [...]
    
    }
    
     
  11. BurgerKiLL

    BurgerKiLL Ads.id Pro

    Joined:
    May 29, 2013
    Messages:
    476
    Likes Received:
    46
    Location:
    Just BurgerKill Fans
    seneng dengarnya, mantap om :)
     
  12. cloudmild

    cloudmild Newbie

    Joined:
    Aug 4, 2014
    Messages:
    28
    Likes Received:
    0
    Location:
    cloudmild.com
    misalkan ingin pasang SSL di 3 subdomain, gak ada salahnya beli lagi SSL jenis biasa, kecuali mau unlimited subdomain, baru pake SSL Wildcard
     
  13. BurgerKiLL

    BurgerKiLL Ads.id Pro

    Joined:
    May 29, 2013
    Messages:
    476
    Likes Received:
    46
    Location:
    Just BurgerKill Fans
    eh? ada om fuji jg dsini. maaf oot :D
     

Share This Page