Skip to content

Commit 51aeee3

Browse files
committed
Merge branch 'master' of https://github.com/raghavyuva/nixopus
2 parents 16ab031 + 9f34c28 commit 51aeee3

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+1306
-5574
lines changed

.github/workflows/build_container.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ jobs:
4040
4141
- name: Set up Docker Buildx
4242
uses: docker/setup-buildx-action@v3
43+
with:
44+
platforms: linux/amd64,linux/arm64
4345

4446
- name: Cache Docker layers
4547
uses: actions/cache@v4
@@ -72,6 +74,7 @@ jobs:
7274
with:
7375
context: ./api
7476
push: true
77+
platforms: linux/amd64,linux/arm64
7578
tags: ${{ steps.meta-api.outputs.tags }}
7679
labels: ${{ steps.meta-api.outputs.labels }}
7780
build-args: |
@@ -100,6 +103,7 @@ jobs:
100103
with:
101104
context: ./view
102105
push: true
106+
platforms: linux/amd64,linux/arm64
103107
tags: ${{ steps.meta-view.outputs.tags }}
104108
labels: ${{ steps.meta-view.outputs.labels }}
105109
build-args: |

CHANGELOG.md

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,76 @@
1+
# [0.1.0-alpha.65](https://github.com/raghavyuva/nixopus/compare/v0.1.0-alpha.64...v0.1.0-alpha.65) (2025-11-09)
2+
3+
4+
### Bug Fixes
5+
6+
* remove linux/arm/v7 support since no native support from postcss and Nextjs sharp ([#576](https://github.com/raghavyuva/nixopus/issues/576)) ([dc84f0e](https://github.com/raghavyuva/nixopus/commit/dc84f0ef1c1a2568885fdd02e144b91ebe19d8a1))
7+
8+
9+
10+
# [0.1.0-alpha.64](https://github.com/raghavyuva/nixopus/compare/v0.1.0-alpha.63...v0.1.0-alpha.64) (2025-11-08)
11+
12+
13+
### Bug Fixes
14+
15+
* update docker compose files to use internal ports for supertokens postgres connection ([9a23b2c](https://github.com/raghavyuva/nixopus/commit/9a23b2c4552b4f6905dd6d501ed0a40cddf362c0))
16+
17+
18+
19+
# [0.1.0-alpha.63](https://github.com/raghavyuva/nixopus/compare/v0.1.0-alpha.62...v0.1.0-alpha.63) (2025-11-08)
20+
21+
22+
### Bug Fixes
23+
24+
* malformed supertokens connection uri during ip based installations ([b6b1ad5](https://github.com/raghavyuva/nixopus/commit/b6b1ad5ec11b3eda9caac692c0cad3cba59adbc9))
25+
26+
27+
28+
# [0.1.0-alpha.62](https://github.com/raghavyuva/nixopus/compare/v0.1.0-alpha.61...v0.1.0-alpha.62) (2025-11-08)
29+
30+
31+
### Bug Fixes
32+
33+
* always binds predictable ports inside the container, and uses dynamic ports for the host ([#569](https://github.com/raghavyuva/nixopus/issues/569)) ([e5e637e](https://github.com/raghavyuva/nixopus/commit/e5e637eabddfa02ed03b32de338004ed5efcfaa8))
34+
35+
36+
### Features
37+
38+
* add support for linux/amd64 linux/arm54 linux/arm/v7 ([#570](https://github.com/raghavyuva/nixopus/issues/570)) ([59938ad](https://github.com/raghavyuva/nixopus/commit/59938ad28932854c9b0d2388b37ceeb28a8a1ab9))
39+
40+
41+
42+
# [0.1.0-alpha.61](https://github.com/raghavyuva/nixopus/compare/v0.1.0-alpha.60...v0.1.0-alpha.61) (2025-11-08)
43+
44+
45+
### Features
46+
47+
* add support for custom ports during nixopus install ([#567](https://github.com/raghavyuva/nixopus/issues/567)) ([01c4b1d](https://github.com/raghavyuva/nixopus/commit/01c4b1d8a116fde1cf992cef4face3728e55e039))
48+
49+
50+
51+
# [0.1.0-alpha.60](https://github.com/raghavyuva/nixopus/compare/v0.1.0-alpha.59...v0.1.0-alpha.60) (2025-11-05)
52+
53+
54+
### Bug Fixes
55+
56+
* nixopus uninstall hangs or silently asks for confirmation from user which is not identical ([#560](https://github.com/raghavyuva/nixopus/issues/560)) ([5a9c7f8](https://github.com/raghavyuva/nixopus/commit/5a9c7f8cb7ec347a907ba51de4a9e6bc59f707ec))
57+
58+
59+
### Features
60+
61+
* add support for custom config file during nixopus installation ([#561](https://github.com/raghavyuva/nixopus/issues/561)) ([0b34f84](https://github.com/raghavyuva/nixopus/commit/0b34f84e02345f2bb583be587c7f4676b72c6523))
62+
63+
64+
65+
# [0.1.0-alpha.59](https://github.com/raghavyuva/nixopus/compare/v0.1.0-alpha.58...v0.1.0-alpha.59) (2025-11-04)
66+
67+
68+
### Features
69+
70+
* add support for custom ip address deployments ([#554](https://github.com/raghavyuva/nixopus/issues/554)) ([d1fb0b4](https://github.com/raghavyuva/nixopus/commit/d1fb0b42fdfad3709180c0ffb1d4725d1e5c8e7b))
71+
72+
73+
174
# [0.1.0-alpha.58](https://github.com/raghavyuva/nixopus/compare/v0.1.0-alpha.57...v0.1.0-alpha.58) (2025-11-02)
275

376

README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,12 @@ This section will help you set up Nixopus on your VPS quickly.
4141
curl -sSL https://install.nixopus.com | bash
4242
```
4343

44+
**For custom ip setups:**
45+
46+
```bash
47+
curl -sSL https://install.nixopus.com | bash -s -- --host-ip 10.0.0.154
48+
```
49+
4450
**To install only the CLI tool without running `nixopus install`:**
4551

4652
```bash
@@ -53,6 +59,7 @@ You can customize your installation by providing the following optional paramete
5359

5460
- `--api-domain` or `-ad`: Specify the domain where the Nixopus API will be accessible (e.g., `nixopusapi.example.tld`)
5561
- `--view-domain` or `-vd`: Specify the domain where the Nixopus app will be accessible (e.g., `nixopus.example.tld`)
62+
- `--host-ip` or `-ip`: Specify the IP address of the server to use when no domains are provided (e.g., `10.0.0.154` or `192.168.1.100`). If not provided, the public IP will be automatically detected.
5663
- `--verbose` or `-v`: Show more details while installing
5764
- `--timeout` or `-t`: Set timeout for each step (default: 300 seconds)
5865
- `--force` or `-f`: Replace files if they already exist
@@ -69,6 +76,14 @@ nixopus install \
6976
--timeout 600
7077
```
7178

79+
Example for custom ip setup:
80+
81+
```bash
82+
nixopus install \
83+
--host-ip 10.0.0.154 \
84+
--verbose
85+
```
86+
7287
You can also install the CLI and run `nixopus install` with options in a single command, refer [installation documentation](https://docs.nixopus.com/install/#installation-options) for more details on options
7388

7489
## About the Name

api/internal/features/deploy/proxy/caddy.go

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import (
66
"fmt"
77
"io"
88
"net/http"
9+
"os"
910
"time"
1011

1112
"github.com/raghavyuva/nixopus-api/internal/config"
@@ -15,7 +16,11 @@ import (
1516
func NewCaddy(logger *logger.Logger, rootDir string, domain string, port string, fileServerType FileServerType) *Caddy {
1617
endpoint := config.AppConfig.Proxy.CaddyEndpoint
1718
if endpoint == "" {
18-
endpoint = "http://127.0.0.1:2019"
19+
caddyPort := os.Getenv("CADDY_ADMIN_PORT")
20+
if caddyPort == "" {
21+
caddyPort = "2019"
22+
}
23+
endpoint = "http://127.0.0.1:" + caddyPort
1924
}
2025
return &Caddy{
2126
Logger: logger,

cli/app/commands/conflict/conflict.py

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -289,20 +289,13 @@ def check_conflicts(self) -> List[ConflictCheckResult]:
289289

290290
def _load_user_config(self, config_path: Optional[str]) -> Dict[str, Any]:
291291
"""Load configuration.
292-
- If config_path is provided, load it as user config (overrides only what it contains).
292+
- If config_path is provided, load it as user config (replaces default config).
293293
- If None, fall back to the built-in config used by Config (same as install command).
294294
"""
295295
try:
296-
if not config_path:
297-
# Built-in config (nested dict) as default
298-
self.logger.debug("Loading built-in configuration (no --config-file provided)")
299-
return self.yaml_config.load_yaml_config()
300-
301-
# Load user config and unflatten to nested structure
302-
self.logger.debug(conflict_loading_config.format(path=config_path))
303-
flattened_config = self.yaml_config.load_user_config(config_path)
304-
self.logger.debug(conflict_config_loaded)
305-
return self.yaml_config.unflatten_config(flattened_config)
296+
self.yaml_config.load_user_config(config_path)
297+
self.logger.debug(conflict_loading_config.format(path=config_path) if config_path else "Loading built-in configuration (no --config-file provided)")
298+
return self.yaml_config.load_yaml_config()
306299

307300
except FileNotFoundError:
308301
raise FileNotFoundError(conflict_config_not_found.format(path=config_path))

cli/app/commands/install/base.py

Lines changed: 4 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -29,24 +29,14 @@ def __init__(
2929
self.config_file = config_file
3030
self.repo = repo
3131
self.branch = branch
32-
self._user_config = Config().load_user_config(self.config_file)
32+
self._config = Config()
33+
self._config.load_user_config(self.config_file)
3334
self.progress = None
3435
self.main_task = None
3536

36-
def _get_config(self, key: str, user_config: dict = None, defaults: dict = None):
37+
def _get_config(self, path: str):
3738
"""Base config getter - override in subclasses for specific behavior"""
38-
config = Config()
39-
40-
# Override repo_url and branch_name if provided via command line
41-
if key == "repo_url" and self.repo is not None:
42-
return self.repo
43-
if key == "branch_name" and self.branch is not None:
44-
return self.branch
45-
46-
try:
47-
return config.get_config_value(key, user_config or self._user_config, defaults or {})
48-
except ValueError:
49-
raise ValueError(configuration_key_has_no_default_value.format(key=key))
39+
return self._config.get(path)
5040

5141
def _validate_domains(self, api_domain: str = None, view_domain: str = None):
5242
"""Validate domain format"""

cli/app/commands/install/command.py

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,20 @@ def install_callback(
4545
"-vd",
4646
help="The domain where the nixopus view will be accessible (e.g. nixopus.com), if not provided you can use the ip address of the server and the port (e.g. 192.168.1.100:80)",
4747
),
48+
host_ip: str = typer.Option(
49+
None,
50+
"--host-ip",
51+
"-ip",
52+
help="The IP address of the server to use when no domains are provided (e.g. 10.0.0.154 or 192.168.1.100). If not provided, the public IP will be automatically detected.",
53+
),
54+
api_port: int = typer.Option(None, "--api-port", help="Port for the API service (default: 8443 for production, 8080 for development)"),
55+
view_port: int = typer.Option(None, "--view-port", help="Port for the View/Frontend service (default: 7443 for production, 3000 for development)"),
56+
db_port: int = typer.Option(None, "--db-port", help="Port for the PostgreSQL database (default: 5432)"),
57+
redis_port: int = typer.Option(None, "--redis-port", help="Port for the Redis service (default: 6379)"),
58+
caddy_admin_port: int = typer.Option(None, "--caddy-admin-port", help="Port for Caddy admin API (default: 2019)"),
59+
caddy_http_port: int = typer.Option(None, "--caddy-http-port", help="Port for Caddy HTTP traffic (default: 80)"),
60+
caddy_https_port: int = typer.Option(None, "--caddy-https-port", help="Port for Caddy HTTPS traffic (default: 443)"),
61+
supertokens_port: int = typer.Option(None, "--supertokens-port", help="Port for SuperTokens service (default: 3567)"),
4862
repo: str = typer.Option(None, "--repo", "-r", help="GitHub repository URL to clone (defaults to config value)"),
4963
branch: str = typer.Option(None, "--branch", "-b", help="Git branch to clone (defaults to config value)"),
5064
):
@@ -65,6 +79,14 @@ def install_callback(
6579
repo=repo,
6680
branch=branch,
6781
install_path=dev_path,
82+
api_port=api_port,
83+
view_port=view_port,
84+
db_port=db_port,
85+
redis_port=redis_port,
86+
caddy_admin_port=caddy_admin_port,
87+
caddy_http_port=caddy_http_port,
88+
caddy_https_port=caddy_https_port,
89+
supertokens_port=supertokens_port,
6890
)
6991
dev_install.run()
7092
else:
@@ -77,8 +99,17 @@ def install_callback(
7799
config_file=config_file,
78100
api_domain=api_domain,
79101
view_domain=view_domain,
102+
host_ip=host_ip,
80103
repo=repo,
81104
branch=branch,
105+
api_port=api_port,
106+
view_port=view_port,
107+
db_port=db_port,
108+
redis_port=redis_port,
109+
caddy_admin_port=caddy_admin_port,
110+
caddy_http_port=caddy_http_port,
111+
caddy_https_port=caddy_https_port,
112+
supertokens_port=supertokens_port,
82113
)
83114
install.run()
84115

@@ -110,6 +141,14 @@ def development(
110141
),
111142
repo: str = typer.Option(None, "--repo", "-r", help="GitHub repository URL to clone (defaults to config value)"),
112143
branch: str = typer.Option(None, "--branch", "-b", help="Git branch to clone (defaults to config value)"),
144+
api_port: int = typer.Option(None, "--api-port", help="Port for the API service (default: 8080)"),
145+
view_port: int = typer.Option(None, "--view-port", help="Port for the View/Frontend service (default: 3000)"),
146+
db_port: int = typer.Option(None, "--db-port", help="Port for the PostgreSQL database (default: 5432)"),
147+
redis_port: int = typer.Option(None, "--redis-port", help="Port for the Redis service (default: 6379)"),
148+
caddy_admin_port: int = typer.Option(None, "--caddy-admin-port", help="Port for Caddy admin API (default: 2019)"),
149+
caddy_http_port: int = typer.Option(None, "--caddy-http-port", help="Port for Caddy HTTP traffic (default: 80)"),
150+
caddy_https_port: int = typer.Option(None, "--caddy-https-port", help="Port for Caddy HTTPS traffic (default: 443)"),
151+
supertokens_port: int = typer.Option(None, "--supertokens-port", help="Port for SuperTokens service (default: 3567)"),
113152
):
114153
"""Install Nixopus for local development in specified or current directory"""
115154
logger = Logger(verbose=verbose)
@@ -123,6 +162,14 @@ def development(
123162
repo=repo,
124163
branch=branch,
125164
install_path=path,
165+
api_port=api_port,
166+
view_port=view_port,
167+
db_port=db_port,
168+
redis_port=redis_port,
169+
caddy_admin_port=caddy_admin_port,
170+
caddy_http_port=caddy_http_port,
171+
caddy_https_port=caddy_https_port,
172+
supertokens_port=supertokens_port,
126173
)
127174
install.run()
128175

0 commit comments

Comments
 (0)