{"componentChunkName":"component---src-templates-blog-template-js","path":"/docs/new-store","result":{"data":{"markdownRemark":{"html":"<h2>Clone The Repo</h2>\n<pre><code>git clone git@github.com:binx/beluga.git\n</code></pre>\n<h2>IMPORTANT: Create your config.env file</h2>\n<p>Open your text editor and create a file titled <code>config.env</code> in the root <code>/</code> directory of the project. Add the the following items:</p>\n<pre><code>STRIPE_KEY={Secret API key from Stripe}\nADMIN_PW={your password to log in to the admin view}\nSESSION_SECRET={secret session key, just make a long string of random characters}\n</code></pre>\n<p>You will need to get your secret API key from Stripe. See <a href=\"/docs/stripe\">Setting Up Stripe</a> to learn how to get your Secret API key.</p>\n<h3>Passwords</h3>\n<p>You'll notice that in your initial <code>config.env</code> file, you are writing your password in plain-text. This will be converted to a salted hash of your password, the first time that you log in to an admin route. Code to salt and hash the password is <a href=\"https://github.com/binx/beluga/blob/master/server/admin.js#L12\">here</a>. Once the password has been hashed, you will see a new line in your <code>config.env</code> file, </p>\n<pre><code>PASSWORD_IS_HASHED=true\n</code></pre>\n<p>If you wish to change you password at a future time, type in a new plain-text password to <code>ADMIN_PW</code>, and delete the <code>PASSWORD_IS_HASHED</code> line (or set to <code>false</code>).</p>\n<h2>Installing all the dependencies</h2>\n<pre><code>yarn\n</code></pre>\n<h2>Start the development server</h2>\n<p>First, start your node server with the following command:</p>\n<pre><code>yarn server\n</code></pre>\n<p>In a second terminal window, start your react development server:</p>\n<pre><code>yarn start\n</code></pre>\n<h2>View your Store locally</h2>\n<p>Open up a new tab in your browser and navigate to <code>http://localhost:3000</code>.</p>\n<p>Congrats! This is the beginning of your very first Store!</p>\n<p>You’ll be able to visit the site locally for as long as your development server is running. To stop running that process go back to your terminal window, press (ctrl-c).</p>","frontmatter":{"path":"/docs/new-store","date":"2020-01-03T17:12:33.962Z","header":"Introduction","title":"Creating a New Store 🛍"}}},"pageContext":{"pages":[{"path":"/docs/changelog","title":"Changelog & To Do's 📝","header":"Beluga Next Steps","date":"2020-01-11T17:12:33.962Z"},{"path":"/docs/seo-social","title":"SEO and Social Media 💻","header":"Launching Your Store","date":"2020-01-10T17:12:33.962Z"},{"path":"/docs/deploy-to-heroku","title":"Deploying To Heroku 🚀","header":"Launching Your Store","date":"2020-01-09T17:12:33.962Z"},{"path":"/docs/gmail-oauth","title":"Setting up Gmail Oauth2 📬","header":"Managing Orders","date":"2020-01-07T19:12:33.962Z"},{"path":"/docs/email-templates","title":"Email Templates 🧾","header":"Managing Orders","date":"2020-01-07T18:12:33.962Z"},{"path":"/docs/managing-orders","title":"Order Admin 📦","header":"Managing Orders","date":"2020-01-07T16:12:33.962Z"},{"path":"/docs/custom-products","title":"Advanced: Custom Product Data 💫","header":"Store Configuration","date":"2020-01-06T22:12:33.962Z"},{"path":"/docs/shipping","title":"Checkout & Shipping 🛒","header":"Store Configuration","date":"2020-01-06T21:12:33.962Z"},{"path":"/docs/additional-pages","title":"Adding Pages 📄","header":"Store Configuration","date":"2020-01-06T20:12:33.962Z"},{"path":"/docs/adding-collections","title":"Adding Collections 📂","header":"Store Configuration","date":"2020-01-06T19:12:33.962Z"},{"path":"/docs/adding-products","title":"Adding Products 🎁","header":"Store Configuration","date":"2020-01-06T18:12:33.962Z"},{"path":"/docs/theming-design","title":"Theming & Design 🎨","header":"Store Configuration","date":"2020-01-06T17:12:33.962Z"},{"path":"/docs/store-config","title":"Store Settings 🛠","header":"Store Configuration","date":"2020-01-05T16:12:33.962Z"},{"path":"/docs/stripe","title":"Setting up Stripe 💵","header":"Introduction","date":"2020-01-04T17:12:33.962Z"},{"path":"/docs/new-store","title":"Creating a New Store 🛍","header":"Introduction","date":"2020-01-03T17:12:33.962Z"},{"path":"/docs/dev-environment","title":"Setting up the Dev Environment 🧪","header":"Introduction","date":"2020-01-02T17:12:33.962Z"},{"path":"/docs/project-structure","title":"Overview of Project Structure 🏗","header":"Introduction","date":"2020-01-01T17:12:33.962Z"}]}},"staticQueryHashes":["45326706"]}