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

Running Multiple Services on Same Host: Change Netbird Port from 443 (Self-Hosting) #1786

Open
abulazif opened this issue Apr 2, 2024 · 8 comments

Comments

@abulazif
Copy link

abulazif commented Apr 2, 2024

I've been utilizing your self-hosting script, which currently serves on port 443. My aim is to run another WordPress instance alongside the existing service on the same host. Despite attempting various methods, I haven't succeeded in making the necessary changes. Specifically, I need guidance on changing the port of the Netbird service from 443 to another available port to facilitate this setup. My setup is simple, suitable for a small environment. Any assistance on how to accomplish this adjustment effectively would be greatly appreciated. Additionally, here's the command I've been using to deploy Netbird: export NETBIRD_DOMAIN=netbird.example.com; curl -fsSL https://github.com/netbirdio/netbird/releases/latest/download/getting-started-with-zitadel.sh | bash. Thank you for your support. It would greatly benefit from assistance in transitioning from CockroachDB to PostgreSQL for database management within the self-hosting environment

@jiangslee
Copy link

I have a script for changing ports here, maybe it can help you.

#1410 (comment)

curl -fsSL https://raw.githubusercontent.com/jiangslee/netbird/main-jsl/infrastructure_files/getting-started-with-zitadel.sh | bash

@rqi14
Copy link
Contributor

rqi14 commented Apr 2, 2024

You can use reverse proxy and docker container. Check linuxserver/swag. They have a working config.

@bcmmbaga
Copy link
Contributor

bcmmbaga commented Apr 3, 2024

It would greatly benefit from assistance in transitioning from CockroachDB to PostgreSQL for database management within the self-hosting environment

The default database for ZITADEL is CockroachDB, but in case you need to change to PostgreSQL, please take a look at their documentation at https://zitadel.com/docs/self-hosting/manage/database.

@abulazif
Copy link
Author

abulazif commented Apr 3, 2024

WARN[0000] /root/nbird03/docker-compose.yml: version is obsolete.

My comments:

The script is working great, but there is an issue with the docker-compose.yml file: version is obsolete. I've double-checked my Docker version, and it seems up-to-date. How can I resolve this?

I initially attempted to run the script using a self-signed certificate, which led to several failures.

I successfully generated a Let's Encrypt certificate for my domain using the OpenLiteSpeed Docker version. However, I'm unsure how to automate the renewal process and which tool to use for certificate creation.
Why is the script utilizing SSL certificates in PEM format when Let's Encrypt certificates are not typically provided in that format? Additionally, how can I automate the conversion of Let's Encrypt certificates to PEM format? I am aware that this can be achieved through a cron job, but I'm seeking a tool that facilitates this process. Any recommendations or suggestions to address this certificate-related issue would be greatly appreciated.

Could anybody suggest a tool for managing SSL certificates easily without relying on a web server?

I've tested Zitadel with PostgreSQL manually. Can someone provide guidance on where I need to make adjustments in the script, particularly regarding ports?

If Zitadel is utilizing CockroachDB, is there any Docker-compatible web GUI available?

Thank you all very much. Happy coding.

@abulazif abulazif changed the title How Modifying Self-Hosting Script for Multiple Services on Same Host" Running Multiple Services on Same Host: Change Netbird Port from 443 (Self-Hosting) Apr 3, 2024
@xcstatus
Copy link

xcstatus commented Apr 5, 2024

WARN[0000] /root/nbird03/docker-compose.yml: version is obsolete.

My comments:

The script is working great, but there is an issue with the docker-compose.yml file: version is obsolete. I've double-checked my Docker version, and it seems up-to-date. How can I resolve this?

I initially attempted to run the script using a self-signed certificate, which led to several failures.

I successfully generated a Let's Encrypt certificate for my domain using the OpenLiteSpeed Docker version. However, I'm unsure how to automate the renewal process and which tool to use for certificate creation. Why is the script utilizing SSL certificates in PEM format when Let's Encrypt certificates are not typically provided in that format? Additionally, how can I automate the conversion of Let's Encrypt certificates to PEM format? I am aware that this can be achieved through a cron job, but I'm seeking a tool that facilitates this process. Any recommendations or suggestions to address this certificate-related issue would be greatly appreciated.

Could anybody suggest a tool for managing SSL certificates easily without relying on a web server?

I've tested Zitadel with PostgreSQL manually. Can someone provide guidance on where I need to make adjustments in the script, particularly regarding ports?

If Zitadel is utilizing CockroachDB, is there any Docker-compatible web GUI available?

Thank you all very much. Happy coding.

delete docker-compose.yml first row。 The "version" parameter is obsolete

@rqi14
Copy link
Contributor

rqi14 commented Apr 5, 2024

Why making it difficult for yourself? Just look at linuxserver/swag. It handles nginx configs and let's encrypt certificate renewal for you. You dont even need to configure anything except enabling the config for your netbird and setting some parameters like your domain name

@abulazif
Copy link
Author

abulazif commented Apr 5, 2024

Why making it difficult for yourself? Just look at linuxserver/swag. It handles nginx configs and let's encrypt certificate renewal for you. You dont even need to configure anything except enabling the config for your netbird and setting some parameters like your domain name

Did you check how Netbird is installed using a bash script? Can you explain how to use SWAG with Netbird? As per my understanding, it is difficult with a bash script under SWAG. I also do not want to use an API for DNS. I neither want to reserve port 443 for SWAG nor want to use third-party DNS. There are better options available. Insha'Allah.

@rqi14
Copy link
Contributor

rqi14 commented Apr 5, 2024

Why making it difficult for yourself? Just look at linuxserver/swag. It handles nginx configs and let's encrypt certificate renewal for you. You dont even need to configure anything except enabling the config for your netbird and setting some parameters like your domain name

Did you check how Netbird is installed using a bash script? Can you explain how to use SWAG with Netbird? As per my understanding, it is difficult with a bash script under SWAG. I also do not want to use an API for DNS. I neither want to reserve port 443 for SWAG nor want to use third-party DNS. There are better options available. Insha'Allah.

I don't think you will have to reserve 443 for swag. I think you can set it to use DNS challenge mode. If you don't want to use container for your netbitd instance, I think you can point the url to your host in swag. But in that case, it is true that you will still need to solve the changing port issue. I am mentioning the swag thing because you asked how to get pem certificate and automate the renewal process. Swag gives you pem version of certificate, and automates the renewal for you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants
@bcmmbaga @rqi14 @jiangslee @xcstatus @abulazif and others