Skip to content

Commit

Permalink
docs: use correct publish directory for netlify deploy (#2741)
Browse files Browse the repository at this point in the history
* Use correct publish directory for netlify deploy

Netlify automatically sets the Publish directory as "dist," but the netlify admin app's `build` command outputs files to `public`.

* Update docs/content/deployments/admin/deploying-on-netlify.md

Co-authored-by: Shahed Nasser <shahednasser@gmail.com>

* Netlify CLI instructions updated to match UI

* Update docs/content/deployments/admin/deploying-on-netlify.md

* Update docs/content/deployments/admin/deploying-on-netlify.md

* Update deploying-on-netlify.md

Co-authored-by: Shahed Nasser <shahednasser@gmail.com>
  • Loading branch information
komali2 and shahednasser authored Dec 13, 2022
1 parent ae290a3 commit 9021037
Showing 1 changed file with 22 additions and 2 deletions.
24 changes: 22 additions & 2 deletions docs/content/deployments/admin/deploying-on-netlify.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,14 @@ After you authorize Netlify to use GitHub, you’ll be asked to pick the reposit

![Choose Repository](https://res.cloudinary.com/dza7lstvk/image/upload/v1668001871/Medusa%20Docs/Netlify/D0r6Q1e_th5uei.png)

In the form that shows, keep all fields the same and click on the “Show advanced” button before the “Deploy site” button.
In the "Basic build settings" section, make sure the fields have the following values:

- Base directory: (leave empty)
- Build command: yarn build
- Publish directory: public


Next, click the “Show advanced” button, which is above the “Deploy site” button.

![Show advanced Button](https://res.cloudinary.com/dza7lstvk/image/upload/v1668001884/Medusa%20Docs/Netlify/nUdwRbq_d2kmo6.png)

Expand Down Expand Up @@ -211,7 +218,20 @@ If you pick the second option, you’ll need to create a personal access token o

##### Last Step: Steps with Default Values

For the rest of the steps, you can keep the default values provided by Netlify and press the “Enter” key on your keyboard for each.
For the rest of the steps, you can keep most of the default values provided by Netlify, except for the following options:

1. Set build command to `yarn run build`

```
? Your build command (hugo build/yarn run build/etc): yarn run build
```

2. Set deploy directory to `public`

```
? Directory to deploy (blank for current dir): public
```


#### Set Environment Variables

Expand Down

0 comments on commit 9021037

Please sign in to comment.