Skip to content
This repository has been archived by the owner on Feb 13, 2023. It is now read-only.

[fix] fixed wrong env example #36

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

[fix] fixed wrong env example #36

wants to merge 2 commits into from

Conversation

skirianov
Copy link

@skirianov skirianov commented Jan 19, 2023

Fixed wrong ENV variable example. It was breaking newly installed application.

Related Issue: #35

.env.example Outdated
@@ -4,7 +4,7 @@ VSF_NUXT_APP_HOST=localhost

VSF_STORE_URL=https://localhost:3000
VSF_MIDDLEWARE_URL=https://localhost:3000/api/
VSF_SSR_MIDDLEWARE_URL=http://localhost:3000/api/
VSF_SSR_MIDDLEWARE_URL=https://localhost:3000/api/
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@skirianov
Hello, thank you for your PR. However, there are no wrong or good examples when it comes to the used protocol. In fact, 99% of local setups will not use HTTPS in their Nuxt application, it should be more like https=>http for middleware_url than http=>https for ssr_middleware_url

Copy link
Author

@skirianov skirianov Jan 20, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Following our documentation https://docs.vuestorefront.io/magento/installation-setup/configure-integration.html#_5-using-https-configuration-for-a-local-development setting up the HTTPS seems like a part of the process. Hence, our users may get confused and run into issues (I've got confused and got stuck for a while because of it). That's why we need to fix it according to docs or change docs to remove Step 5 and make it optional @mattmaribojoc


Sergii Kirianov
Developer Advocate
Vue Storefront

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It should be optional, ppl do not understand how and why to configure a secure connection for local development. I thought that the title makes it obvious it is optional, but that was the wrong assumption.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we have already a few people struggling with it. So, what do you suggest? Keep it http and change docs to make it optional?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it was already configured by default to use https and I had 1000question/day on how to setup it. Then I decided to make it unsecure by default (which is actually the very basic thing for the nuxt, security connection for the nuxt is always optional)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

VSF_STORE_URL=https://localhost:3000
VSF_MIDDLEWARE_URL=https://localhost:3000/api/
VSF_STORE_URL=http://localhost:3000
VSF_MIDDLEWARE_URL=http://localhost:3000/api/
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed all to http

VSF_SSR_MIDDLEWARE_URL=http://localhost:3000/api/

VSF_MAGENTO_BASE_URL={YOUR_SITE_FRONT_URL}
VSF_MAGENTO_GRAPHQL_URL=https://{YOUR_SITE_FRONT_URL}/graphql
VSF_MAGENTO_GRAPHQL_URL={YOUR_SITE_FRONT_URL}/graphql
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all {YOUR_SITE_FRONT_URL} consistent throughout the env file

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants