Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 1 addition & 27 deletions guides/installation/setups/docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -202,33 +202,7 @@

## Proxy Production Images

Typically, you import for local development a copy of the production database to your local environment. This allows you to test changes with production similar data. However, this can lead to issues that all images are missing in the local environment. To avoid this, you can download all images from the production environment and import them into your local environment. Or set up a proxy server that serves the images from the production environment.

To do this, you can add a `imageproxy` service to your `compose.override.yaml`:

```yaml
services:
imageproxy:
image: ghcr.io/shopwarelabs/devcontainer/image-proxy
ports:
- "8050:80"
environment:
# Your production URL.
REMOTE_SERVER_HOST: shopware.com
```

This will start a proxy server that serves all images from the production environment. In this case if we request `http://localhost:8050/assets/images.png`, it will load `https://[REMOTE_SERVER_HOST]/assets/images.png` and serve it to the local environment, it will also cache the images locally.

Next, we need to configure Shopware to use the proxy server. To do this, create a new YAML file `config/packages/media-proxy.yaml`

```yaml
shopware:
filesystem:
public:
url: "http://localhost:8050"
```

This will tell Shopware to use the proxy server URL for all images.
<PageRef page="../../../products/cli/project-commands/image-proxy" />

Check warning on line 205 in guides/installation/setups/docker.md

View workflow job for this annotation

GitHub Actions / LanguageTool

[LanguageTool] guides/installation/setups/docker.md#L205

Unpaired symbol: ‘"’ seems to be missing (EN_UNPAIRED_QUOTES) URL: https://languagetool.org/insights/post/punctuation-guide/#what-are-parentheses Rule: https://community.languagetool.org/rule/show/EN_UNPAIRED_QUOTES?lang=en-US Category: PUNCTUATION
Raw output
guides/installation/setups/docker.md:205:14: Unpaired symbol: ‘"’ seems to be missing (EN_UNPAIRED_QUOTES)
 URL: https://languagetool.org/insights/post/punctuation-guide/#what-are-parentheses 
 Rule: https://community.languagetool.org/rule/show/EN_UNPAIRED_QUOTES?lang=en-US
 Category: PUNCTUATION

Check warning on line 205 in guides/installation/setups/docker.md

View workflow job for this annotation

GitHub Actions / LanguageTool

[LanguageTool] guides/installation/setups/docker.md#L205

Unpaired symbol: ‘"’ seems to be missing (EN_UNPAIRED_QUOTES) URL: https://languagetool.org/insights/post/punctuation-guide/#what-are-parentheses Rule: https://community.languagetool.org/rule/show/EN_UNPAIRED_QUOTES?lang=en-US Category: PUNCTUATION
Raw output
guides/installation/setups/docker.md:205:65: Unpaired symbol: ‘"’ seems to be missing (EN_UNPAIRED_QUOTES)
 URL: https://languagetool.org/insights/post/punctuation-guide/#what-are-parentheses 
 Rule: https://community.languagetool.org/rule/show/EN_UNPAIRED_QUOTES?lang=en-US
 Category: PUNCTUATION

## Known issues

Expand Down