| 1 |
<!-- SPDX-License-Identifier: LGPL-2.1+ --> |
| 2 |
|
| 3 |
<!DOCTYPE refentry PUBLIC @docdtd@ [ |
| 4 |
|
| 5 |
<!ENTITY commonoptions SYSTEM "@builddir@/common_options.sgml"> |
| 6 |
<!ENTITY seealso SYSTEM "@builddir@/see_also.sgml"> |
| 7 |
]> |
| 8 |
|
| 9 |
<refentry> |
| 10 |
|
| 11 |
<docinfo><date>@LXC_GENERATE_DATE@</date></docinfo> |
| 12 |
|
| 13 |
<refmeta> |
| 14 |
<refentrytitle>lxc-execute</refentrytitle> |
| 15 |
<manvolnum>1</manvolnum> |
| 16 |
</refmeta> |
| 17 |
|
| 18 |
<refnamediv> |
| 19 |
<refname>lxc-execute</refname> |
| 20 |
|
| 21 |
<refpurpose> |
| 22 |
<!-- |
| 23 |
run an application inside a container. |
| 24 |
--> |
| 25 |
컨테이너 내부로 응용 프로그램 실행 |
| 26 |
</refpurpose> |
| 27 |
</refnamediv> |
| 28 |
|
| 29 |
<refsynopsisdiv> |
| 30 |
<cmdsynopsis> |
| 31 |
<command>lxc-execute</command> |
| 32 |
<arg choice="req">-n <replaceable>name</replaceable></arg> |
| 33 |
<arg choice="opt">-d</arg> |
| 34 |
<arg choice="opt">-f <replaceable>config_file</replaceable></arg> |
| 35 |
<arg choice="opt">-s KEY=VAL</arg> |
| 36 |
<arg choice="opt">-u, --uid <replaceable>uid</replaceable></arg> |
| 37 |
<arg choice="opt">-g, --gid <replaceable>gid</replaceable></arg> |
| 38 |
<arg choice="opt">-- <replaceable>command</replaceable></arg> |
| 39 |
</cmdsynopsis> |
| 40 |
</refsynopsisdiv> |
| 41 |
|
| 42 |
<refsect1> |
| 43 |
<title><!-- Description -->설명</title> |
| 44 |
|
| 45 |
<para> |
| 46 |
<!-- |
| 47 |
<command>lxc-execute</command> runs the specified |
| 48 |
<replaceable>command</replaceable> inside the container |
| 49 |
specified by <replaceable>name</replaceable>. |
| 50 |
--> |
| 51 |
<command>lxc-execute</command>는 지정한 <replaceable>command</replaceable>를 <replaceable>name</replaceable>라는 이름의 컨테이너 내부에서 실행한다. |
| 52 |
</para> |
| 53 |
<para> |
| 54 |
<!-- |
| 55 |
It will setup the container |
| 56 |
according to the configuration previously defined with the |
| 57 |
lxc-create command or with the configuration file parameter. |
| 58 |
If no configuration is |
| 59 |
defined, the default isolation is used. |
| 60 |
--> |
| 61 |
이 명령어는 <command>lxc-create</command> 정의했던 설정을 토대로 또는 인수 |
| 62 |
를 통해 넘긴 설정파일을 토대로 컨테이너를 세팅한다. |
| 63 |
만약 정의된 설정이 없다면, 기본 고립 환경을 사용한다. |
| 64 |
</para> |
| 65 |
<para> |
| 66 |
<!-- |
| 67 |
This command is mainly used when you want to quickly launch an |
| 68 |
application in an isolated environment. |
| 69 |
--> |
| 70 |
이 명령어들은 고립된 환경에서 응용 프로그램을 빠르게 실행해보고 싶을 때, 주로 사용한다. |
| 71 |
</para> |
| 72 |
<para> |
| 73 |
<!-- |
| 74 |
<command>lxc-execute</command> command will run the |
| 75 |
specified command into the container via an intermediate |
| 76 |
process, <command>lxc-init</command>. |
| 77 |
This lxc-init after launching the specified command, |
| 78 |
will wait for its end and all other reparented processes. |
| 79 |
(to support daemons in the container). |
| 80 |
In other words, in the |
| 81 |
container, <command>lxc-init</command> has the pid 1 and the |
| 82 |
first process of the application has the pid 2. |
| 83 |
--> |
| 84 |
<command>lxc-execute</command>명령어는 컨테이너 내부에서 <command>lxc-init</command> 프로세스를 통해 지정한 명령어를 실행한다. |
| 85 |
<command>lxc-init</command>은 지정한 명령어를 실행한 뒤에, 해당 명령어 및 그 명령어에서 실행된 모든 프로세스들을 기다린다(컨테이너 내에서 데몬을 지원하기 위한 것). |
| 86 |
즉, 컨테이너내에서 <command>lxc-init</command>는 pid는 1이 되고, 그 다음으로 실행되는 응용 프로그램은 pid가 2가 된다. |
| 87 |
</para> |
| 88 |
<para> |
| 89 |
<!-- |
| 90 |
The above <command>lxc-init</command> is designed to forward received |
| 91 |
signals to the started command. |
| 92 |
--> |
| 93 |
<command>lxc-init</command>는 시그널들을 받아서 시작한 명령어에게 보내주도록 되어 있다. |
| 94 |
</para> |
| 95 |
</refsect1> |
| 96 |
|
| 97 |
<refsect1> |
| 98 |
<title><!-- Options -->옵션</title> |
| 99 |
|
| 100 |
<variablelist> |
| 101 |
|
| 102 |
<varlistentry> |
| 103 |
<term> |
| 104 |
<option>-f, --rcfile <replaceable>config_file</replaceable></option> |
| 105 |
</term> |
| 106 |
<listitem> |
| 107 |
<para> |
| 108 |
<!-- |
| 109 |
Specify the configuration file to configure the virtualization |
| 110 |
and isolation functionalities for the container. |
| 111 |
--> |
| 112 |
컨테이너의 가상화나 고립 기능을 설정할 때 쓰일 설정파일을 지정한다. |
| 113 |
</para> |
| 114 |
<para> |
| 115 |
<!-- |
| 116 |
This configuration file if present will be used even if there is |
| 117 |
already a configuration file present in the previously created |
| 118 |
container (via lxc-create). |
| 119 |
--> |
| 120 |
지정한 설정파일이 존재한다면, 이전에 생성된(lxc-create를 통해) 컨테이너에 설정파일이 이미 존재한다고 하더라도 지정한 설정파일을 사용한다. |
| 121 |
</para> |
| 122 |
</listitem> |
| 123 |
</varlistentry> |
| 124 |
|
| 125 |
<varlistentry> |
| 126 |
<term> |
| 127 |
<option>-s, --define <replaceable>KEY=VAL</replaceable></option> |
| 128 |
</term> |
| 129 |
<listitem> |
| 130 |
<para> |
| 131 |
<!-- |
| 132 |
Assign value <replaceable>VAL</replaceable> to configuration |
| 133 |
variable <replaceable>KEY</replaceable>. This overrides any |
| 134 |
assignment done in <replaceable>config_file</replaceable>. |
| 135 |
--> |
| 136 |
<replaceable>VAL</replaceable> 값을 <replaceable>KEY</replaceable> 설정변수에 넣는다. |
| 137 |
이는 <replaceable>config_file</replaceable>에서의 설정을 덮어쓴다. |
| 138 |
</para> |
| 139 |
</listitem> |
| 140 |
</varlistentry> |
| 141 |
|
| 142 |
<varlistentry> |
| 143 |
<term> |
| 144 |
<option>-d, --daemon</option> |
| 145 |
</term> |
| 146 |
<listitem> |
| 147 |
<para> |
| 148 |
컨테이너를 데몬으로 실행한다. |
| 149 |
컨테이너는 tty를 가지고 있지 않기 때문에, 에러가 발생하더라도 화면에 아무것도 표시되지 않는다. |
| 150 |
에러를 확인하기 위해 로그 파일을 사용할 수 있다. |
| 151 |
</para> |
| 152 |
</listitem> |
| 153 |
</varlistentry> |
| 154 |
|
| 155 |
<varlistentry> |
| 156 |
<term> |
| 157 |
<option>-u, --uid <replaceable>uid</replaceable></option> |
| 158 |
</term> |
| 159 |
<listitem> |
| 160 |
<para> |
| 161 |
<!-- |
| 162 |
Executes the <replaceable>command</replaceable> with user ID |
| 163 |
<replaceable>uid</replaceable> inside the container. |
| 164 |
--> |
| 165 |
지정된 사용자 ID <replaceable>uid</replaceable>로 <replaceable>command</replaceable>를 |
| 166 |
container 내부에 실행한다. |
| 167 |
</para> |
| 168 |
</listitem> |
| 169 |
</varlistentry> |
| 170 |
|
| 171 |
<varlistentry> |
| 172 |
<term> |
| 173 |
<option>--g, --gid <replaceable>gid</replaceable></option> |
| 174 |
</term> |
| 175 |
<listitem> |
| 176 |
<para> |
| 177 |
<!-- |
| 178 |
Executes the <replaceable>command</replaceable> with group ID |
| 179 |
<replaceable>gid</replaceable> inside the container. |
| 180 |
--> |
| 181 |
지정된 그룹 ID <replaceable>gid</replaceable>로 <replaceable>command</replaceable>를 |
| 182 |
container 내부에 실행한다. |
| 183 |
</para> |
| 184 |
</listitem> |
| 185 |
</varlistentry> |
| 186 |
|
| 187 |
<varlistentry> |
| 188 |
<term><option>--</option></term> |
| 189 |
<listitem> |
| 190 |
<para> |
| 191 |
<!-- |
| 192 |
Signal the end of options and disables further option |
| 193 |
processing. Any arguments after the -- are treated as |
| 194 |
arguments to <replaceable>command</replaceable>. |
| 195 |
--> |
| 196 |
옵션이 끝임을 지정하고 더이상 옵션에 대한 처리를 하지 않는다. |
| 197 |
-- 이후에 오는 모든 인수는 <replaceable>command</replaceable>의 인수로서 처리된다. |
| 198 |
</para> |
| 199 |
<para> |
| 200 |
<!-- |
| 201 |
This option is useful when you want specify options |
| 202 |
to <replaceable>command</replaceable> and don't want |
| 203 |
<command>lxc-execute</command> to interpret them. |
| 204 |
--> |
| 205 |
이것은 <replaceable>command</replaceable>에게 옵션을 지정하고, <command>lxc-execute</command>가 그 옵션을 처리하지 않게 하는데 유용하게 사용된다. |
| 206 |
</para> |
| 207 |
</listitem> |
| 208 |
</varlistentry> |
| 209 |
|
| 210 |
</variablelist> |
| 211 |
|
| 212 |
</refsect1> |
| 213 |
|
| 214 |
&commonoptions; |
| 215 |
|
| 216 |
<refsect1> |
| 217 |
<title><!-- Diagnostic -->진단</title> |
| 218 |
|
| 219 |
<variablelist> |
| 220 |
|
| 221 |
<varlistentry> |
| 222 |
<term>The container is busy</term> |
| 223 |
<listitem> |
| 224 |
<para> |
| 225 |
<!-- |
| 226 |
The specified container is already running an |
| 227 |
application. You should stop it before reuse this |
| 228 |
container or create a new one. |
| 229 |
--> |
| 230 |
지정한 컨테이너가 이미 실행중인 경우이다. 컨테이너를 사용하고 싶다면 컨테이너를 중지시켜야 한다. 또는 새로운 컨테이너를 만들 수도 있다. |
| 231 |
</para> |
| 232 |
</listitem> |
| 233 |
</varlistentry> |
| 234 |
|
| 235 |
</variablelist> |
| 236 |
|
| 237 |
</refsect1> |
| 238 |
|
| 239 |
&seealso; |
| 240 |
|
| 241 |
</refentry> |
| 242 |
|
| 243 |
<!-- Keep this comment at the end of the file |
| 244 |
Local variables: |
| 245 |
mode: sgml |
| 246 |
sgml-omittag:t |
| 247 |
sgml-shorttag:t |
| 248 |
sgml-minimize-attributes:nil |
| 249 |
sgml-always-quote-attributes:t |
| 250 |
sgml-indent-step:2 |
| 251 |
sgml-indent-data:t |
| 252 |
sgml-parent-document:nil |
| 253 |
sgml-default-dtd-file:nil |
| 254 |
sgml-exposed-tags:nil |
| 255 |
sgml-local-catalogs:nil |
| 256 |
sgml-local-ecat-files:nil |
| 257 |
End: |
| 258 |
--> |