> For the complete documentation index, see [llms.txt](https://cocktailcloud.gitbook.io/cocktail-cloud-online/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cocktailcloud.gitbook.io/cocktail-cloud-online/advanced-course/login-session-ingress.md).

# 서비스 웹 페이지 Login Session 유지 불가 시 Ingress 설정

## 1. Ingress에 upstream-hash-by 설정 <a href="#id-1.-ingress-upstream-hash-by" id="id-1.-ingress-upstream-hash-by"></a>

1\) \[애플리케이션] - \[서비스] 탭에서 \[워크로드 명] - \[인그레스] 탭 클릭 후 아래 \[설정] 탭을 선택합니다.

2\) 주석 항목에 "+" 버튼을 클릭하여 주석을 아래와 같이 작성 후 "적용" 버튼을 클릭합니다.

<figure><img src="/files/y1Oq346qtCD6pqA75W7b" alt=""><figcaption><p> [화면] 인그레스 주석</p></figcaption></figure>

<figure><img src="/files/EfpnEjV9RPSolouG30u4" alt=""><figcaption><p>[화면] 주석 입력</p></figcaption></figure>

```yaml
nginx.ingress.kubernetes.io/upstream-hash-by
$host
```

3\) 작성이 완료되면 우측 상단의 "저장" 버튼을 클릭합니다.

4\) 정상적으로 반영이 되었는지 확인하기 위해 주석 항목을 확인합니다.

<figure><img src="/files/Mob4VPFcXoOnXGlClU1l" alt=""><figcaption><p>[화면] 인그레스 설정 확인</p></figcaption></figure>
