Update README.md
Added an example in the README file for setting up a fallback in case of a SPA setup.
This commit is contained in:
parent
72ed8fa4a9
commit
33ffeb9352
1 changed files with 9 additions and 1 deletions
10
README.md
10
README.md
|
@ -77,6 +77,14 @@ The fallback option is principally useful for single-page applications (SPAs) wh
|
|||
|
||||
The second case is useful if you have multiple SPAs within the one filesystem. e.g., */* and */admin*.
|
||||
|
||||
Example with a absolute path for a SPA setup :
|
||||
|
||||
```dockerfile
|
||||
FROM pierrezemb/gostatic:latest
|
||||
COPY ./your/dist/folder /srv/http
|
||||
EXPOSE 8043
|
||||
CMD [ "-fallback", "index.html" ]
|
||||
```
|
||||
|
||||
## Build
|
||||
|
||||
|
@ -84,4 +92,4 @@ The second case is useful if you have multiple SPAs within the one filesystem. e
|
|||
```bash
|
||||
docker buildx create --use --name=cross
|
||||
docker buildx build --platform=linux/amd64,linux/arm64,linux/arm/v5,linux/arm/v6,linux/arm/v7,darwin/amd64,darwin/arm64,windows/amd64 .
|
||||
```
|
||||
```
|
||||
|
|
Loading…
Reference in a new issue