> ## Documentation Index
> Fetch the complete documentation index at: https://ayakaleaf-pro.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# TeX Live 확장

> 지원되는 컴파일 환경을 위해 TeX Live Docker 이미지에 패키지와 글꼴을 추가합니다.

새 Dockerfile로 기존 TeX Live 이미지를 확장하고, 애플리케이션이 새 이미지를 사용하도록 구성할 수 있습니다.

여기서는 새 패키지나 글꼴을 설치하는 몇 가지 지침을 제공하지만, 사용자 지정 이미지의 구성은 지원 범위에 포함되지 않습니다.

TeX Live 이미지는 자주 업데이트되지 않습니다. Server Pro를 업그레이드할 때 사용자 지정 이미지를 다시 빌드하는 것을 권장합니다.

<Danger>
  다음 섹션은 Server Pro와 [샌드박스 컴파일](/ko/on-premises/configuration/overleaf-toolkit/sandboxed-compiles)에만 적용됩니다.
</Danger>

### 새 패키지 설치 및 업데이트

다음 예시처럼 `tlmgr install`, `tlmgr update` 등의 `tlmgr` 명령을 사용해 TeX Live 패키지를 관리할 수 있습니다.

```dockerfile theme={null}
FROM ghcr.io/ayaka-notes/texlive-full:2023.1

RUN tlmgr update --force ebproof
```

### 이전 TeX Live 이미지에서 `tlmgr` 사용

기본적으로 `tlmgr`는 최신 TeX Live 릴리스에서 리소스를 다운로드합니다. 이전 TeX Live 이미지를 패치할 때는 다운로드 위치를 해당 아카이브로 전환해야 합니다. 아카이브 미러 목록은 [https://www.tug.org/historic/](https://www.tug.org/historic/)에서 확인하세요.

```dockerfile theme={null}
FROM ghcr.io/ayaka-notes/texlive-full:2022.1

RUN tlmgr option repository <MIRROR>/systems/texlive/<YEAR>/tlnet-final
# e.g. RUN tlmgr option repository ftp://tug.org/historic/systems/texlive/2022/tlnet-final

RUN tlmgr update --force ebproof
```

### 새 글꼴 설치

TeX Live 배포판에 새 글꼴을 설치하는 방법은 여러 가지가 있으며, 사용자 지정 글꼴을 설치하려면 여러 단계가 필요할 수 있습니다. TeX Live 공식 문서의 [TeX 글꼴 설치 안내](https://tug.org/fonts/fontinstall.html)를 먼저 확인하는 것이 좋은 출발점입니다.

다음 `Dockerfile`은 기존 TeX Live 2022 이미지에 TrueType 글꼴을 설치하는 예시입니다.

```dockerfile theme={null}
FROM ghcr.io/ayaka-notes/texlive-full:2022.1

COPY ./myfonts/*.ttf /usr/share/fonts/truetype/myfont/

# rebuild font information cache
RUN fc-cache
```

### 새 이미지를 사용하도록 Server Pro 구성

다음과 같이 `ghcr.io/ayaka-notes/texlive-full` 이름과 사용자 지정 태그를 사용해 새 이미지를 빌드합니다.

```bash theme={null}
docker build -t ghcr.io/ayaka-notes/texlive-full:2023.1-custom
```

이제 `TEX_LIVE_DOCKER_IMAGE` 및 `ALL_TEX_LIVE_DOCKER_IMAGES` 환경 변수를 업데이트하여 Server Pro가 새 `2023.1-custom` 이미지를 사용하도록 구성할 수 있습니다.

```text wrap theme={null}
TEX_LIVE_DOCKER_IMAGE: "ghcr.io/ayaka-notes/texlive-full:2023.1-custom"
ALL_TEX_LIVE_DOCKER_IMAGES: "ghcr.io/ayaka-notes/texlive-full:2023.1,ghcr.io/ayaka-notes/texlive-full:2023.1-custom"
```

위 예시에서 새 프로젝트는 기본적으로 새 `2023.1-custom` 이미지를 사용하며, 필요할 때는 `2023.1`도 계속 사용할 수 있습니다.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.