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

Add documentation on how to run the app #5

Open
RetryingOOS opened this issue Sep 3, 2020 · 8 comments
Open

Add documentation on how to run the app #5

RetryingOOS opened this issue Sep 3, 2020 · 8 comments

Comments

@RetryingOOS
Copy link

No description provided.

@RetryingOOS
Copy link
Author

on dev environment, running deno run -A main.ts doesn't work. In localhost:8000 it shows os error 3. Can you help? Thanks

@LTSENG01
Copy link
Owner

LTSENG01 commented Sep 3, 2020

There are three security flags that must be allowed for Deno: --allow-net --allow-read --allow-env. Also make sure that your environment has the correct secrets set and that all custom features and strings (for my server) are modified.

@RetryingOOS
Copy link
Author

Oh I didnt remove any of the features yet but I was just testing. Doesn't the -A flag allow for everything. I also have the .env set up already.

@LTSENG01
Copy link
Owner

LTSENG01 commented Sep 4, 2020

Ah right, you are correct. -A does allow for everything. You actually need to set DEBUG = true on line 9 of main.ts. I was having issues with serving static files from two different environments, but you can change it on line 332.

@RetryingOOS
Copy link
Author

Oh I didn't notice line 9. Sorry for the dumb question but how do I host this on my own website. Do I need to deploy to Heroku or can I just do that on local command line?

@RetryingOOS
Copy link
Author

Nvm got that done and I configured the buildpacks already. But the website is still not working. What do I need to do to get it ready for Heroku? Thanks a lot!

@RetryingOOS
Copy link
Author

And since Heroku does not support the binding of one specific port, how do I change it so that it's not only port 8000.

@RetryingOOS
Copy link
Author

I added the following code const {args, exit} = Deno; const DEFAULT_PORT = 8000; const argPort = flags.parse(args).port; const port = argPort ? Number(argPort) : DEFAULT_PORT; await app.listen({port: port});

@LTSENG01 LTSENG01 added this to To do in Ongoing Projects Nov 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

No branches or pull requests

2 participants