Skip to content

Commit c292313

Browse files
committed
update README and src
1 parent 3436aa5 commit c292313

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ RUN rm -rf node_modules
1818

1919

2020

21-
# Our Second stage, that creates an image for production
21+
# Our Second stage, that creates the final image.
2222
FROM node:10-alpine
2323

2424
LABEL maintainer="Obinna Odirionye"

README.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ The Node-Typescript/Express Hackathon Starter Kit is production ready with authe
4444
- [Deployment](#deployment)
4545
- [Docker](#docker)
4646
- [Production](#production)
47+
- [Credits](#credits)
48+
- [Inspiration](#inspiration)
4749
- [Changelog](#changelog)
4850
- [Code of Conduct](#code-of-conduct)
4951
- [Contributing](#contributing)
@@ -571,6 +573,11 @@ I believe Serverless Containers are the future of deploying Containerized applic
571573
- [Enable billing](https://support.google.com/cloud/answer/6293499#enable-billing) for your project (there's a $300 free trial)
572574

573575
```bash
576+
577+
# Ensure that you have a Live MongoDB URL inside your variable.env [PROD_MONGODB]
578+
579+
# PROD_MONGODB=mongodb://<username>:<password>@<hostname>/<database name>
580+
574581
# Build the project for a production environment.
575582
npm run docker:build
576583

@@ -625,6 +632,9 @@ cp .env.variable.env variable.env
625632

626633
# To build and start the project for the first time.
627634
docker-compose -f "docker-compose.yml" up -d --build
635+
636+
# Run the project
637+
docker run -d -it --name hackathon -p 3000:3000 [name of the image or ID of the image]
628638
```
629639

630640
### Running hackathon-starter kit in Production

src/controllers/authController.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ export const loginForm = (req: Request, res: Response) => {
3636

3737
passport.authenticate("local", {
3838
failureRedirect: "/login",
39-
successReturnToOrRedirect: "/",
39+
successReturnToOrRedirect: "/posts",
4040
failureFlash: "Invalid Email or Password",
4141
successFlash: "You are now logged in!",
4242
})(req, res);

0 commit comments

Comments
 (0)