Skip to content

Commit

Permalink
chore: socket-extensions dependency fixed
Browse files Browse the repository at this point in the history
chore: updated .env

chore: fixed app name in package.json
  • Loading branch information
Ashish Kumar authored and Ashish Kumar committed Jun 8, 2020
1 parent 8f053f8 commit 8e0db2b
Show file tree
Hide file tree
Showing 12 changed files with 16 additions and 32 deletions.
7 changes: 5 additions & 2 deletions .env → .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,10 @@
# If you add multiple env files in docker-compose,
# default variables will be override

PORT=5000
TAG=latest
DOCKER_USERNAME=connectashishk
DOCKER_IMAGE_NAME=ssr-build-stream
DOCKER_IMAGE_NAME=ssr-build-stream

PORT=3000
API_URL=https://hn.algolia.com/
HOST_URL=http://localhost:3000
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/client-build
/server-build
/node_modules
__snapshots__
__snapshots__
.env
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@ cd ssr-stream-setup
```
3. Run the install `npm install`

4. To start the server run:
4. Create a new file `.env` and Copy .env.example into .env

5. To start the server run:
```
npm run dev
```
Expand Down
4 changes: 0 additions & 4 deletions env/dev.env

This file was deleted.

3 changes: 0 additions & 3 deletions env/prod.env

This file was deleted.

2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "hacker-new-test",
"name": "react-redux-isomorphic-boilerplate",
"version": "1.0.0",
"description": "",
"main": "index.js",
Expand Down
1 change: 1 addition & 0 deletions server/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import * as bodyParser from "body-parser";
import cookieParser from "cookie-parser";
import ServeWeb from "./helpers/ServeWeb";

require("dotenv").config();
const { createProxyMiddleware } = require("http-proxy-middleware");
const compression = require("compression");

Expand Down
2 changes: 1 addition & 1 deletion tools/build.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash
# env file
ENV_FILE_PATH=./env/prod.env
ENV_FILE_PATH=./.env

echo "[INFO] Using $ENV_FILE_PATH"

Expand Down
2 changes: 1 addition & 1 deletion tools/deploy.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

ENV_FILE_PATH=./env/prod.env
ENV_FILE_PATH=./.env

echo "[INFO] Using $ENV_FILE_PATH"

Expand Down
10 changes: 1 addition & 9 deletions webpack/dev/webpack.base.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
const Dotenv = require("dotenv-webpack");
const { CleanWebpackPlugin } = require("clean-webpack-plugin");
const LoadablePlugin = require("@loadable/webpack-plugin");

Expand All @@ -17,13 +16,6 @@ module.exports = {
},
plugins: [
new LoadablePlugin(),
new CleanWebpackPlugin(),
new Dotenv({
path: "./dev.env", // load this now instead of the ones in '.env'
safe: true, // load '.env.example' to verify the '.env' variables are all set. Can also be a string to a different file.
systemvars: true, // load all the predefined 'process.env' variables which will trump anything local per dotenv specs.
silent: true, // hide any errors
defaults: false // load '.env.defaults' as the default values if empty.
})
new CleanWebpackPlugin()
]
};
8 changes: 0 additions & 8 deletions webpack/production/webpack.base.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
const UglifyJsPlugin = require("uglifyjs-webpack-plugin");
const Dotenv = require("dotenv-webpack");
const LoadablePlugin = require("@loadable/webpack-plugin");
const BrotliPlugin = require("brotli-webpack-plugin");
const { CleanWebpackPlugin } = require("clean-webpack-plugin");
Expand All @@ -19,13 +18,6 @@ module.exports = {
plugins: [
new LoadablePlugin(),
new CleanWebpackPlugin(),
new Dotenv({
path: "./.env", // load this now instead of the ones in '.env'
safe: true, // load '.env.example' to verify the '.env' variables are all set. Can also be a string to a different file.
systemvars: true, // load all the predefined 'process.env' variables which will trump anything local per dotenv specs.
silent: true, // hide any errors
defaults: false // load '.env.defaults' as the default values if empty.
}),
new UglifyJsPlugin({
sourceMap: true,
uglifyOptions: {
Expand Down

0 comments on commit 8e0db2b

Please sign in to comment.