# How do I deploy an application to a Stack?

To deploy your application, follow these steps:

* Enter the directory of your Stack:\
  \
  `cd stack/<Language>/<Stack>/`

{% hint style="info" %}
The path to the chosen Stack in the menu will always be:

`stack/<Language>/<Stack>/`\\

**Example**:\
`stack/python/flask-redis/`

`stack/java/tomcat-mysql/`
{% endhint %}

* Stop the currently deployed Stack with this command:\
  \
  `docker compose down`\\
* Upload your application to the **/app** directory either by pulling from Git, using Wget, or your preferred method.
* Then deploy your application or its updates with the command:\
  \
  `docker compose up --build`

That's it. These steps should be followed when deploying your application for the first time or when updating it.


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.sitioshispanos.com/menu-principal/guias/docker-hosting/como-despliego-una-aplicacion-en-un-stack.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
