이 콘텐츠는 선택한 언어로 제공되지 않습니다.

Chapter 2. Managed Files


Managed files are files that have non-default settings, or that require special handling by OpenShift Enterprise.
The $cartridge_name/metadata/managed_files.yml file lists managed files and strings that OpenShift Enterprise uses during different stages of the cartridge life cycle.
File Patterns

Most entries in the managed_files.yml file use file patterns. OpenShift Enterprise treats these patterns like shell globs. Dir.glob processes entries that contain asterisk (*) symbols using the File::FNM_DOTMATCH flag. It treats entries that end in a forward slash (/) as directories, and other entries as files. For more information on globs, see http://ruby-doc.org/core-1.9.3/Dir.html#method-c-glob.

Entries that begin with ~/ start at the gear directory. All other entries start at the cartridge directory.
Strings

Some entries allow string values. These values return directly without any modification.

Allowed Entries

OpenShift Enterprise supports the following entries:

Expand
Table 2.1. Managed File Entries
Entry Type Usage Reference
locked_files File Pattern Files that the application developer can read but not update. Chapter 3, Locking Cartridges
snapshot_exclusions File Pattern Array of file names not to backup from the gear when rhc snapshot runs. Chapter 10, Backing Up and Restoring Cartridges
setup_rewritten File Pattern Files that OpenShift Enterprise removes before running setup. Section 6.2, “setup Script”
process_templates File Pattern ERB templates OpenShift Enterprise renders after running setup. Section 6.1, “Embedded Ruby (ERB) Processing”
restore_transforms Strings Set of regex transforms for rewriting file names when rhc restore runs. Chapter 10, Backing Up and Restoring Cartridges
The following example demonstrates the structure of a basic managed_files.yml file:

Example 2.1. managed_files.yml

locked_files:
- env/
- ~/.foorc
snapshot_exclusions:
- mydir/*
restore_transforms:
- s|${OPENSHIFT_GEAR_NAME}/data|app-root/data|
process_templates:
- **/*.erb
setup_rewritten:
- conf/*
Copy to Clipboard Toggle word wrap
맨 위로 이동
Red Hat logoGithubredditYoutubeTwitter

자세한 정보

평가판, 구매 및 판매

커뮤니티

Red Hat 문서 정보

Red Hat을 사용하는 고객은 신뢰할 수 있는 콘텐츠가 포함된 제품과 서비스를 통해 혁신하고 목표를 달성할 수 있습니다. 최신 업데이트를 확인하세요.

보다 포괄적 수용을 위한 오픈 소스 용어 교체

Red Hat은 코드, 문서, 웹 속성에서 문제가 있는 언어를 교체하기 위해 최선을 다하고 있습니다. 자세한 내용은 다음을 참조하세요.Red Hat 블로그.

Red Hat 소개

Red Hat은 기업이 핵심 데이터 센터에서 네트워크 에지에 이르기까지 플랫폼과 환경 전반에서 더 쉽게 작업할 수 있도록 강화된 솔루션을 제공합니다.

Theme

© 2025 Red Hat