NebulaServices / Nebula

a stunning and sleek web proxy with support for hundreds of popular sites.
https://docs.nebulaproxy.io/
279 stars 3.75k forks source link

How do i deploy to github pages #145

Closed hankypoo7 closed 9 months ago

hankypoo7 commented 1 year ago

guys ngl im an idiot and I want to deploy this to my github pages site. how would i do it?

rifting commented 1 year ago

Set the UV config to an external bare server

hankypoo7 commented 1 year ago

Set the UV config to an external bare server

how

hankypoo7 commented 1 year ago

You can't, GH pages only allows static websites unfortunately oh thanks

rifting commented 1 year ago

Set the UV config to an external bare server

how

By editing the config. 7ht is wrong, it's possible

hankypoo7 commented 1 year ago

Set the UV config to an external bare server

how

By editing the config. 7ht is wrong, it's possible

What would I specifically do? this is the code so tell me what i can change it to:

self.__uv$config = { prefix: "/service/go/", bare: "/bare/", encodeUrl: Ultraviolet.codec.xor.encode, decodeUrl: Ultraviolet.codec.xor.decode, handler: "/uv/uv.handler.js", bundle: "/uv/uv.bundle.js", config: "/uv/uv.config.js", sw: "/uv/uv.sw.js" };

rifting commented 1 year ago

Change the bare to https://tomp.app or another bare server

hankypoo7 commented 1 year ago

Change the bare to https://tomp.app or another bare server

so:

self.__uv$config = { prefix: "/service/go/", bare: "https://tomp.app", encodeUrl: Ultraviolet.codec.xor.encode, decodeUrl: Ultraviolet.codec.xor.decode, handler: "/uv/uv.handler.js", bundle: "/uv/uv.bundle.js", config: "/uv/uv.config.js", sw: "/uv/uv.sw.js" };

right? im 13 so im still learning js

rifting commented 1 year ago

Yup

hankypoo7 commented 1 year ago

Yup

thanks. So i fork it, change that, then what? how do i deploy it to github pages also thank you so much for helping me i really appriciate it you cool asf sorry for being annyoing

rifting commented 1 year ago

I'm not sure, I've never deployed to GH pages before. You should be able to just upload the static files and then use the proxy

hankypoo7 commented 1 year ago

I'm not sure, I've never deployed to GH pages before. You should be able to just upload the static files and then use the proxy

ok thanks

ghost commented 11 months ago

Set the UV config to an external bare server

Where is the UV config? edit: nvm found itttt <3

ghost commented 11 months ago

Set the UV config to an external bare server

Where is the UV config? edit: nvm found itttt <3

did you ever find out how to do this? im too dumb

ghost commented 11 months ago

I'm not sure, I've never deployed to GH pages before. You should be able to just upload the static files and then use the proxy how would i upload the static files and what do i upload lol

tuta-amb commented 11 months ago

This thread is pretty confusing so let me explain it to anyone who's confused.

TL;DR No, you cannot deploy to Github Pages.

Can you deploy to Github Pages? Yes, but no. While technically you can deploy to Github Pages, Github Pages is a static site host. This means that it can only serve files, and it is not capable of running any backend server code.

The way proxies work is that the request is forwarded to a server. The server then grabs the data and sends it back to the client. Github Pages is only capable of the client part, not the server.

Someone (@Riftriot) said it could be done though! Their solution was to edit the client so that instead of expecting Github Pages to provide a server, it would use someone else's external server. The issue is that if that server is blocked (it probably is), the client is useless since it can't connect.

ghost commented 11 months ago

@tuta-amb do you have any suggestions to host this then? a lot of them like replit are blocked

tuta-amb commented 11 months ago

@Hankypoo7 Try render.com was a good one until it got blocked, it's free tier is generous and its a relatively newer one, so it shouldn't be blocked for you. Also, if you have access to a credit card, Google Cloud, AWS, IBM Cloud, and I think Cyclic are all good ones, they just require a credit card verification. Finally, you can also run the app on Github Codespaces, because it can expose ports to the public, but you only get 50 hours of usage per month.

Also on some blockers, no IP addresses are blocked at all, so if you start up a proxy on your home computer, you can connect to it with the IP address.

ghost commented 11 months ago

@Hankypoo7 Try render.com was a good one until it got blocked, it's free tier is generous and its a relatively newer one, so it shouldn't be blocked for you. Also, if you have access to a credit card, Google Cloud, AWS, IBM Cloud, and I think Cyclic are all good ones, they just require a credit card verification. Finally, you can also run the app on Github Codespaces, because it can expose ports to the public, but you only get 50 hours of usage per month.

Also on some blockers, no IP addresses are blocked at all, so if you start up a proxy on your home computer, you can connect to it with the IP address.

Yeah I have render and aws, I just am not sure how to fully deploy it. I select the repo and I have to enter build commands and other stuff. I do npm I and npm start and stuff,but it doesn't work. Also, I have the student plan on GitHub so I get 180 hours on codespaces per month, but when I open it up in codespaces nothing works and it always looks like css isn't working. Thank you a lot again.

tuta-amb commented 11 months ago

@Hankypoo7 Try render.com was a good one until it got blocked, it's free tier is generous and its a relatively newer one, so it shouldn't be blocked for you. Also, if you have access to a credit card, Google Cloud, AWS, IBM Cloud, and I think Cyclic are all good ones, they just require a credit card verification. Finally, you can also run the app on Github Codespaces, because it can expose ports to the public, but you only get 50 hours of usage per month. Also on some blockers, no IP addresses are blocked at all, so if you start up a proxy on your home computer, you can connect to it with the IP address.

Yeah I have render and aws, I just am not sure how to fully deploy it. I select the repo and I have to enter build commands and other stuff. I do npm I and npm start and stuff,but it doesn't work. Also, I have the student plan on GitHub so I get 180 hours on codespaces per month, but when I open it up in codespaces nothing works and it always looks like css isn't working. Thank you a lot again.

If you are running on a site such as Render, first you probably need to fork the repository to your own account. Then link your Github account in Render and create a new Web Service. Using instructions from here, we can see that you need to select Nodejs for the runtime, set the build command to npm ci and the start command to node . or npm start.

Similar, to deploy using Codespaces you should create a Codespaces using this repository. Then run:

# cd Nebula (if necessary)
$ npm install
$ npm ci
$ npm start

LMK if this works.

ghost commented 11 months ago

@Hankypoo7 Try render.com was a good one until it got blocked, it's free tier is generous and its a relatively newer one, so it shouldn't be blocked for you. Also, if you have access to a credit card, Google Cloud, AWS, IBM Cloud, and I think Cyclic are all good ones, they just require a credit card verification. Finally, you can also run the app on Github Codespaces, because it can expose ports to the public, but you only get 50 hours of usage per month. Also on some blockers, no IP addresses are blocked at all, so if you start up a proxy on your home computer, you can connect to it with the IP address.

Yeah I have render and aws, I just am not sure how to fully deploy it. I select the repo and I have to enter build commands and other stuff. I do npm I and npm start and stuff,but it doesn't work. Also, I have the student plan on GitHub so I get 180 hours on codespaces per month, but when I open it up in codespaces nothing works and it always looks like css isn't working. Thank you a lot again.

If you are running on a site such as Render, first you probably need to fork the repository to your own account. Then link your Github account in Render and create a new Web Service. Using instructions from here, we can see that you need to select Nodejs for the runtime, set the build command to npm ci and the start command to node . or npm start.

Similar, to deploy using Codespaces you should create a Codespaces using this repository. Then run:

# cd Nebula (if necessary)
$ npm install
$ npm ci
$ npm start

LMK if this works.

codespaces says "error processing your request" and render says "this action is not allowed"

ghost commented 11 months ago

@Hankypoo7 Try render.com was a good one until it got blocked, it's free tier is generous and its a relatively newer one, so it shouldn't be blocked for you. Also, if you have access to a credit card, Google Cloud, AWS, IBM Cloud, and I think Cyclic are all good ones, they just require a credit card verification. Finally, you can also run the app on Github Codespaces, because it can expose ports to the public, but you only get 50 hours of usage per month. Also on some blockers, no IP addresses are blocked at all, so if you start up a proxy on your home computer, you can connect to it with the IP address.

Yeah I have render and aws, I just am not sure how to fully deploy it. I select the repo and I have to enter build commands and other stuff. I do npm I and npm start and stuff,but it doesn't work. Also, I have the student plan on GitHub so I get 180 hours on codespaces per month, but when I open it up in codespaces nothing works and it always looks like css isn't working. Thank you a lot again.

If you are running on a site such as Render, first you probably need to fork the repository to your own account. Then link your Github account in Render and create a new Web Service. Using instructions from here, we can see that you need to select Nodejs for the runtime, set the build command to npm ci and the start command to node . or npm start.

Similar, to deploy using Codespaces you should create a Codespaces using this repository. Then run:

# cd Nebula (if necessary)
$ npm install
$ npm ci
$ npm start

LMK if this works.

image

ghost commented 11 months ago

just got codespaces to work

tuta-amb commented 11 months ago

just got codespaces to work

nice

tuta-amb commented 11 months ago

@Hankypoo7 Try render.com was a good one until it got blocked, it's free tier is generous and its a relatively newer one, so it shouldn't be blocked for you. Also, if you have access to a credit card, Google Cloud, AWS, IBM Cloud, and I think Cyclic are all good ones, they just require a credit card verification. Finally, you can also run the app on Github Codespaces, because it can expose ports to the public, but you only get 50 hours of usage per month. Also on some blockers, no IP addresses are blocked at all, so if you start up a proxy on your home computer, you can connect to it with the IP address.

Yeah I have render and aws, I just am not sure how to fully deploy it. I select the repo and I have to enter build commands and other stuff. I do npm I and npm start and stuff,but it doesn't work. Also, I have the student plan on GitHub so I get 180 hours on codespaces per month, but when I open it up in codespaces nothing works and it always looks like css isn't working. Thank you a lot again.

If you are running on a site such as Render, first you probably need to fork the repository to your own account. Then link your Github account in Render and create a new Web Service. Using instructions from here, we can see that you need to select Nodejs for the runtime, set the build command to npm ci and the start command to node . or npm start. Similar, to deploy using Codespaces you should create a Codespaces using this repository. Then run:

# cd Nebula (if necessary)
$ npm install
$ npm ci
$ npm start

LMK if this works.

image

Most likely your account is flagged as "suspicious".

ghost commented 11 months ago

@Hankypoo7 Try render.com was a good one until it got blocked, it's free tier is generous and its a relatively newer one, so it shouldn't be blocked for you. Also, if you have access to a credit card, Google Cloud, AWS, IBM Cloud, and I think Cyclic are all good ones, they just require a credit card verification. Finally, you can also run the app on Github Codespaces, because it can expose ports to the public, but you only get 50 hours of usage per month.

Also on some blockers, no IP addresses are blocked at all, so if you start up a proxy on your home computer, you can connect to it with the IP address.

Yeah I have render and aws, I just am not sure how to fully deploy it. I select the repo and I have to enter build commands and other stuff. I do npm I and npm start and stuff,but it doesn't work. Also, I have the student plan on GitHub so I get 180 hours on codespaces per month, but when I open it up in codespaces nothing works and it always looks like css isn't working. Thank you a lot again.

If you are running on a site such as Render, first you probably need to fork the repository to your own account. Then link your Github account in Render and create a new Web Service. Using instructions from here, we can see that you need to select Nodejs for the runtime, set the build command to npm ci and the start command to node . or npm start.

Similar, to deploy using Codespaces you should create a Codespaces using this repository. Then run:


# cd Nebula (if necessary)

$ npm install

$ npm ci

$ npm start

LMK if this works.

image

Most likely your account is flagged as "suspicious".

Oh. Why do you think that would be?

tuta-amb commented 11 months ago

@Hankypoo7 What kind of email are you using? Using a disposable email such as from mail.com or a temporary email such as 10MinuteMail most likely would get you flagged.

ghost commented 11 months ago

@tuta-amb school email

ghost commented 11 months ago

i just tryed a icloud one too. Im gonna try a yahoo now

tuta-amb commented 11 months ago

@Hankypoo7 Oh wait sorry. It seems that Render has implemented anti-proxy detection, as proxies are against their TOS. 🤷‍♂️

But, try this version: https://github.com/tuta-amb/uv/tree/main, which includes renamed packages so it might bypass their detection filter. See if using that repo works.

tuta-amb commented 11 months ago

If Render doesn't work, I guess just stick to Codespaces then.

ghost commented 11 months ago

it didnt work, but i took your repo and deployed it to cyclic here, and it just shows me this image It doesnt even let me do the captcha. When i look at yours here, it works perfectly. how do i do that? image

tuta-amb commented 11 months ago

@Hankypoo7real What do you mean? What are you doing differently in each scenario?

ghost commented 11 months ago

@tuta-amb i took your deployed link (on cyclic) and that worked, but when I forked your project and deployed it to cyclic, it gave me that

tuta-amb commented 11 months ago

@Hankypoo7real Are you able to complete the reCaptcha? Also, is @Hankypoo7 and @Hankypoo7real the same person.

ghost commented 11 months ago

@Hankypoo7real Are you able to complete the reCaptcha? Also, is @Hankypoo7 and @Hankypoo7real the same person.

No, it doesn't let me do the captcha and yes, this is my school acc the other is my personal account

tuta-amb commented 11 months ago

@Hankypoo7real I'm not sure. If the deploy link is working though, is there any problem with that?