System/OS
2022.02.03 04:20

[apache2] Redirect HTTP to HTTPS

조회 수 833 추천 수 0 댓글 0
Atachment
첨부 '1'
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄

apache01.jpg




<VirtualHost *:80> 
  ServerName example.com
  ServerAlias www.example.com

  Redirect permanent / https://example.com/
</VirtualHost>

<VirtualHost *:443>
  ServerName example.com
  ServerAlias www.example.com

  Protocols h2 http/1.1

  # SSL Configuration

  # Other Apache Configuration

</VirtualHost>



<VirtualHost *:80> 
  ServerName example.com
  ServerAlias www.example.com

  Redirect permanent / https://example.com/
</VirtualHost>

<VirtualHost *:443>
  ServerName example.com
  ServerAlias www.example.com

  Protocols h2 http/1.1

  <If "%{HTTP_HOST} == 'www.example.com'">
    Redirect permanent / https://example.com/
  </If>

  # SSL Configuration

  # Other Apache Configuration

</VirtualHost>




[출처] https://linuxize.com/post/redirect-http-to-https-in-apache/




?

List of Articles
번호 분류 제목 글쓴이 날짜 조회 수
26 System/OS [windows] 원격 데스크탑(터미널 서비스) 포트 변경 hooni 2013.04.23 16359
25 System/OS [windows] 윈도우 사용자 계정 로그인 암호 분실, 암호 변경하는 방법 file hooni 2015.07.09 21525
24 System/OS [windows] 윈도우즈 콘솔에서 정품인증 하는 방법 hooni 2017.05.24 5585
23 System/OS [windows] 인터넷 익스플로러(IE) 도구모음 표시줄에 아이콘 추가 file hooni 2013.04.23 18286
22 System/OS [windows] 종료, 재시작, 로그아웃 아이콘 만들기 hooni 2013.04.23 18196
21 System/OS [windows] 최근 열어본 문서목록 안나오게 하는 방법 hooni 2013.04.23 25559
20 System/OS [windows] 패스워드를 잊어먹었을때.. hooni 2003.04.23 17359
19 System/OS [펌] 마이크로서비스, 모노리포, SRE, ... 덮어놓고 구글 따라하면 안 되는 기술들 file hooni 2020.10.15 1102
18 System/OS 개인적으로 쓰고 있는 bash_profile hooni 2015.01.16 981
17 System/OS 개인적으로 쓰고 있는 zshrc 파일 hooni 2022.02.25 995
16 System/OS 나중에 해봐야지.. libconv 설치.. ㅡ,.ㅡ; hooni 2013.04.23 19336
15 System/OS 네트워크 용어 정리 file hooni 2022.11.20 1578
14 System/OS 네트워크별 MTU(최대 전송 단위) hooni 2013.04.23 17707
13 System/OS 라우팅 경로 결정 영향 요소 ㅋㅋ file hooni 2013.04.23 15929
12 System/OS 맥 OS X 에서 스크린 화면 캡쳐 단축키 (Mac Print Screen) hooni 2015.07.21 2031
11 System/OS 맥북에서 MAC/윈도우 멀티부팅시 시간 설정 file hooni 2013.04.23 29862
Board Pagination Prev 1 ... 9 10 11 12 13 Next
/ 13