Reputation: 1
I have used git to clone pwa-studio theme, but still unable to run commands like yarn install. Tried installing node.js/npm but couldn't because I am on a dedicated server. From where do I install the pwa-studio theme without any error and how?
Upvotes: 0
Views: 934
Reputation: 725
I hope this will help you,
You will see the pwa-studio directory in /var/www/html/mage0. Enter into this directoy:
cd pwa-studio/
Run
yarn install
Specify the Magento backend server in .env file.
cp packages/venia-concept/.env.dist packages/venia-concept/.env
Open this .env file and find MAGENTO_BACKEND_URL.
MAGENTO_BACKEND_URL="https://magento-2-local/" # your local path
Find the deployVeniaSampleData.sh file in /var/www/html/mage0/pwa-studio/packages/venia-concept/ directory. and copy this file in your Magento root directory. Now it must look like /var/www/html/mage0/deployVeniaSampleData.sh Now run:
bash deployVeniaSampleData.sh
After successful installation run:
bin/magento setup:upgrade bin/magento
indexer:reindex bin/magento
cache:flush
Now go back to pwa-studio directory /var/www/html/mage0/pwa-studio and start Server.
yarn run build or sudo yarn run build
Run server, Use any of the following commands from the project root directory to start the server:
yarn run watch:venia
yarn run watch:all
yarn run build && npm run stage:venia
Now browse the application, you will the application url on terminal like:
PWADevServer ready at https://magento-venia.local.pwadev:8001
Thanks,
Upvotes: 0