> For the complete documentation index, see [llms.txt](https://commandbox.ortusbooks.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://commandbox.ortusbooks.com/embedded-server/install-lucee-core-lex-files.md).

# Install Lucee core/lex files

The `install` command will automatically find a local Lucee Server when installing a package that is a Lex file. There is also now a command called `server lucee-deploy` to help with installing Lex files (Lucee Extensions) and LCO files (Lucee Core).

It will accept an absolute or relative local file path:

```bash
server lucee-deploy myFile.lex
```

or an HTTP URL to download

```bash
server lucee-deploy https://domain.com/path/to/Lucee-core-patch.lco
```

You can also override the name of the CommandBox server to install into, regardless of what working directory the shell is in:

```bash
server lucee-deploy myFile.lex myServer
```

The command will copy the lex or lco file to the deploy folder of the chosen Lucee server following these rules

* If server name is passed as second arg, use that server name (providing it’s a Lucee server)
* Otherwise, if this command is being run inside of a server-related interceptor, capture the name of the server from the intercept data and use that server
* otherwise, look for any Lucee server whose webroot points to the current working directory of the shell and use the first found
* Otherwise, look for a `LUCEE_DEPLOY_DIRECTORY` env var and use this as the deploy directory (can be relative or absolute)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://commandbox.ortusbooks.com/embedded-server/install-lucee-core-lex-files.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
