Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Serve website using Hapi #751

Closed
taoeffect opened this issue Oct 29, 2019 · 0 comments · Fixed by #1020
Closed

Serve website using Hapi #751

taoeffect opened this issue Oct 29, 2019 · 0 comments · Fixed by #1020
Assignees
Labels
App:Backend Kind:Core Anything that changes or affects the fundamental core data structures & design of the application. Priority:High

Comments

@taoeffect
Copy link
Member

taoeffect commented Oct 29, 2019

Problem

Currently we use grunt dev which runs primitive grunt middleware to serve the website.

EDIT: also, copying from #852:

For example, in #780, @SebinSong was not able to sign up a user because the API is being served on "localhost:3000", which his client tries to connect to directly, instead of through the already existing HTTPS host connection on the ngrok domain. So placing the API on the same server will make it easier to proxy the connection using services like ngrok.

Solution

Write/use Hapi to serve files. Look into spazy and inert plugins.

Closing this issue will also probably involve moving off of Primus (#576) and switching to hapi-plugin-websocket.

It will also require replacing grunt-contrib-connect with our own homebrew solution. Have a look at some of these files:

@taoeffect taoeffect added App:Backend Priority:High Kind:Core Anything that changes or affects the fundamental core data structures & design of the application. labels Oct 29, 2019
@taoeffect taoeffect self-assigned this Oct 29, 2019
taoeffect added a commit that referenced this issue Nov 29, 2020
+ Now using browsersync to do livereload
+ Hapi serves SPA and static files

Remaining: Cleanup code + update dependencies and fix build-time warnings
taoeffect added a commit that referenced this issue Nov 30, 2020
* Closes #751 - serve website through Hapi.js

+ Now using browsersync to do livereload
+ Hapi serves SPA and static files

Remaining: Cleanup code + update dependencies and fix build-time warnings

* Updated dependencies:

+    "@hapi/hapi": "20.0.3",
+    "buffer": "6.0.3",
+    "form-data": "3.0.0",
+    "localforage": "1.9.0",
+    "primus": "8.0.0",
+    "systemjs": "6.8.0",
+    "tweetnacl": "1.0.3",
+    "tweetnacl-util": "0.15.1",
+    "vue": "2.6.12",
+    "vue-router": "3.4.9",
+    "vue-slider-component": "3.2.11",
+    "vuelidate": "0.7.6",
+    "vuex": "3.6.0",
+    "wicg-inert": "3.1.0",
+    "ws": "7.4.0"
+    "@babel/core": "7.12.9",
+    "@babel/plugin-proposal-class-properties": "7.12.1",
+    "@babel/plugin-proposal-object-rest-spread": "7.12.1",
+    "@babel/plugin-transform-runtime": "7.12.1",
+    "@babel/preset-env": "7.12.7",
+    "@babel/preset-flow": "7.12.1",
+    "@babel/register": "7.12.1",
+    "@babel/runtime": "7.12.5",
+    "@rollup/plugin-eslint": "8.0.0",
+    "node-fetch": "2.6.1",
+    "vue-template-compiler": "2.6.12"

* Updated dependencies and fixed new eslint errors.

+    "acorn": "8.0.4",
+    "babel-plugin-root-import": "6.6.0",
+    "chalk": "4.1.0",
+    "chokidar": "3.4.3",
+    "eslint": "7.14.0",
+    "eslint-config-standard": "16.0.2",
+    "eslint-plugin-flowtype": "5.2.0",
+    "eslint-plugin-import": "2.22.1",
+    "eslint-plugin-standard": "5.0.0",
+    "eslint-plugin-vue": "7.1.0",
+    "flow-bin": "0.138.0",
+    "flow-remove-types": "2.138.0",
+    "grunt": "1.3.0",
+    "mocha": "8.2.1",
+    "rollup": "2.33.3",
+    "rollup-plugin-vue": "5.1.9",
+    "sinon": "9.2.1",
+    "stylelint": "13.8.0",
+    "stylelint-config-standard": "20.0.0",
+    "vue-cli-plugin-pug": "2.0.0",

* Full Ngrok support (Closes #780) + Fixed SignupForm username blur behavior

SignupForm previously would fail to display validation error if
a valid username was supplied, deleted, the tab key was pressed.

* bump travis node to 14 + update readme to use port 3000

* added 'grunt dev --tunnel' - built-in tunnel!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
App:Backend Kind:Core Anything that changes or affects the fundamental core data structures & design of the application. Priority:High
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant