Comments (10)
How would you feel about adding something like docker compose for development as it makes i easy to spin up all the different services an still allows for hot reloading and such.
Docker of course also be used for hosting, this might be interesting if docker is used in development and could also streamline the system for self hosting (as mentioned in #60) as many services provider docker container hosting.
from stamhoofd.
I'm pro Docker, but for javascript I don't think there are a lot of dependencies that clutter your system and you can make use of nvm. It should be optional as I think the current build time is already very long and inside Docker this will be worse. Feel free to add a Dockerfile / compose file.
from stamhoofd.
The backend is an exception, it will be very useful for setting up MySQL etc.
from stamhoofd.
I'm currently working on a docker compose build system for the backend, with multistage builds I have managed to include all dependencies. Multistage builds should be faster as only the changed stage should be build.
from stamhoofd.
I have made a PR #61 that is still WIP with a proposal of a structure to dokerize the application with docker and docker-compose.
from stamhoofd.
I have been trying to complete the docker scripts @WardToulet had previously created. I made some progress and the following things are working:
- Start mysql server
- Build all of the shared dependencies
- run migrations
- start backed
Running caddy as a reverse proxy is the final step but I have to do some more tinkering to make caddy work correctly inside of a container and expose the correct domain and ports outside of the container so that the frontend kan access them. I think there are also some issues with the certifications, but I'm still figuring out how it all works locally 😛
from stamhoofd.
There is no reason that local development actually needs HTTPS, right?
If so, we could skip caddy and make sure that all communication runs over HTTP.
I was searching the place where the backend host is created and found this ->
We could add a conditional here so that it uses http when NODE_ENV=development. Would this be a possible fix?
from stamhoofd.
You could use the current window.location to check if it already is using HTTP or HTTPS. Or like you said, check for development (but I'm using HTTPS in development, so it is not guaranteed to always be HTTP).
The main reason for HTTPS atm is because I use the .dev TLD in development, which requires HTTPS. But this shouldn't be a requirement. If needed I can setup a domain with a wildcard that alwasy points to localhost. Or we could include a DNS server in the development setup.
from stamhoofd.
Is there a reason you hardcode the hostname to "0.0.0.0" in the RouterServer? https://github.com/SimonBackx/simple-endpoints/blob/455f01dd16eb44fd04e268a9c56eefb9bcd83575/src/RouterServer.ts#L138
I would propose changing it so that you can pass the hostname as a parameter and configure it in your index.ts
.
from stamhoofd.
Is there a reason you hardcode the hostname to "0.0.0.0" in the RouterServer? https://github.com/SimonBackx/simple-endpoints/blob/455f01dd16eb44fd04e268a9c56eefb9bcd83575/src/RouterServer.ts#L138
I would propose changing it so that you can pass the hostname as a parameter and configure it in your
index.ts
.
0.0.0.0 is used just to accept all connections. Caddy or any other reverse proxy should handle domain names and HTTPS and route them to the API. We could remove the obligation for a reverse proxy. Still, the problem is that we use the domain name to determine which organization you are making certain API requests to (the organization ID is in the URL). So domain names are really needed.
from stamhoofd.
Related Issues (20)
- [Feature] Mobile application HOT 5
- Join our developer chat HOT 3
- Setting free contributions might create multiple extra values
- Splitting application and platform code HOT 1
- [Feature] "Verzekerd" of "Ingeschreven" toevoegen aan lid HOT 3
- Beheerder invitelink downgrade hoofdbeheerder account HOT 1
- Option to ask for code in section "Financiële ondersteuning"
- Broken functionality in mobile app HOT 2
- GUI bug when confirming payments HOT 1
- Filteren op betaalmethode "ter plaatse" niet mogelijk
- Build our own external login provider HOT 3
- Add "Bus" to csv import. HOT 2
- Allow for importing bank transfer logs for checking manual transfers HOT 3
- More general registration page HOT 2
- Automatically re register HOT 5
- [BUG] Selecting a time before 10:00 doesn't work HOT 3
- [Feature] Duplicate button for groups HOT 1
- [Feature] Confirmation mail after signing up a member to a group HOT 5
- [Feature] Ticket sale HOT 2
- [Feature] Becoming the all-in-one platform for organisations
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from stamhoofd.