Compare commits
18 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| d3b78054ad | |||
| d2ae35f0ce | |||
| a605477663 | |||
| ba98086548 | |||
| 0b3c22556b | |||
| 069e6e6c8f | |||
| 10598520d8 | |||
| 075b7946b1 | |||
| f47fca3304 | |||
| 575e010a6b | |||
| 60a5dc4663 | |||
| 36d80b1e27 | |||
| 465cf0ee72 | |||
| bd5cd5c0cb | |||
| b622565e34 | |||
| 56376121ab | |||
| e3359d1235 | |||
| f1eeec6922 |
43
changelog.md
43
changelog.md
@@ -1,5 +1,48 @@
|
||||
# Changelog
|
||||
|
||||
## 2026-03-16 - 1.14.4 - fix(repo)
|
||||
no changes to commit
|
||||
|
||||
|
||||
## 2026-03-16 - 1.14.3 - fix(repo)
|
||||
no changes to commit
|
||||
|
||||
|
||||
## 2026-03-16 - 1.14.2 - fix(repo)
|
||||
no changes to commit
|
||||
|
||||
|
||||
## 2026-03-16 - 1.14.1 - fix(repo)
|
||||
no changes to commit
|
||||
|
||||
|
||||
## 2026-03-16 - 1.14.0 - feat(daemon)
|
||||
auto-install Docker and initialize Swarm during daemon service setup
|
||||
|
||||
- Adds a Docker availability check before installing the Onebox daemon service
|
||||
- Installs Docker automatically when it is missing using the standard installation script
|
||||
- Attempts to initialize Docker Swarm after installation and handles already-initialized environments gracefully
|
||||
|
||||
## 2026-03-16 - 1.13.17 - fix(ci)
|
||||
remove forced container image pulling from Gitea workflow jobs
|
||||
|
||||
- Drops the `--pull always` container option from CI, npm publish, and release workflows.
|
||||
- Keeps workflow container images unchanged while avoiding forced pulls on every job run.
|
||||
|
||||
## 2026-03-16 - 1.13.16 - fix(ci)
|
||||
refresh workflow container images on every run and bump @apiclient.xyz/docker to ^5.1.1
|
||||
|
||||
- add --pull always to CI, release, and npm publish workflow containers to avoid stale images
|
||||
- update @apiclient.xyz/docker from ^5.1.0 to ^5.1.1 in deno.json
|
||||
|
||||
## 2026-03-15 - 1.13.15 - fix(repo)
|
||||
no changes to commit
|
||||
|
||||
|
||||
## 2026-03-15 - 1.13.14 - fix(repo)
|
||||
no changes to commit
|
||||
|
||||
|
||||
## 2026-03-15 - 1.13.13 - fix(repo)
|
||||
no changes to commit
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@serve.zone/onebox",
|
||||
"version": "1.13.13",
|
||||
"version": "1.14.4",
|
||||
"exports": "./mod.ts",
|
||||
"tasks": {
|
||||
"test": "deno test --allow-all test/",
|
||||
@@ -16,7 +16,7 @@
|
||||
"@std/encoding": "jsr:@std/encoding@^1.0.10",
|
||||
"@db/sqlite": "jsr:@db/sqlite@0.12.0",
|
||||
"@push.rocks/smartdaemon": "npm:@push.rocks/smartdaemon@^2.1.0",
|
||||
"@apiclient.xyz/docker": "npm:@apiclient.xyz/docker@^5.1.0",
|
||||
"@apiclient.xyz/docker": "npm:@apiclient.xyz/docker@^5.1.1",
|
||||
"@apiclient.xyz/cloudflare": "npm:@apiclient.xyz/cloudflare@6.4.3",
|
||||
"@push.rocks/smartacme": "npm:@push.rocks/smartacme@^8.0.0",
|
||||
"@push.rocks/smartregistry": "npm:@push.rocks/smartregistry@^2.2.0",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@serve.zone/onebox",
|
||||
"version": "1.13.13",
|
||||
"version": "1.14.4",
|
||||
"description": "Self-hosted container platform with automatic SSL and DNS - a mini Heroku for single servers",
|
||||
"main": "mod.ts",
|
||||
"type": "module",
|
||||
|
||||
@@ -3,6 +3,6 @@
|
||||
*/
|
||||
export const commitinfo = {
|
||||
name: '@serve.zone/onebox',
|
||||
version: '1.13.13',
|
||||
version: '1.14.4',
|
||||
description: 'Self-hosted container platform with automatic SSL and DNS - a mini Heroku for single servers'
|
||||
}
|
||||
|
||||
@@ -46,6 +46,59 @@ export class OneboxDaemon {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Ensure Docker is installed, installing it if necessary
|
||||
*/
|
||||
private async ensureDocker(): Promise<void> {
|
||||
try {
|
||||
const cmd = new Deno.Command('docker', {
|
||||
args: ['--version'],
|
||||
stdout: 'piped',
|
||||
stderr: 'piped',
|
||||
});
|
||||
const result = await cmd.output();
|
||||
if (result.success) {
|
||||
const version = new TextDecoder().decode(result.stdout).trim();
|
||||
logger.info(`Docker found: ${version}`);
|
||||
return;
|
||||
}
|
||||
} catch {
|
||||
// docker command not found
|
||||
}
|
||||
|
||||
logger.info('Docker not found. Installing Docker...');
|
||||
const installCmd = new Deno.Command('bash', {
|
||||
args: ['-c', 'curl -fsSL https://get.docker.com | sh'],
|
||||
stdin: 'inherit',
|
||||
stdout: 'inherit',
|
||||
stderr: 'inherit',
|
||||
});
|
||||
const installResult = await installCmd.output();
|
||||
if (!installResult.success) {
|
||||
throw new Error('Failed to install Docker. Please install it manually: curl -fsSL https://get.docker.com | sh');
|
||||
}
|
||||
logger.success('Docker installed successfully');
|
||||
|
||||
// Initialize Docker Swarm
|
||||
logger.info('Initializing Docker Swarm...');
|
||||
const swarmCmd = new Deno.Command('docker', {
|
||||
args: ['swarm', 'init'],
|
||||
stdout: 'piped',
|
||||
stderr: 'piped',
|
||||
});
|
||||
const swarmResult = await swarmCmd.output();
|
||||
if (swarmResult.success) {
|
||||
logger.success('Docker Swarm initialized');
|
||||
} else {
|
||||
const stderr = new TextDecoder().decode(swarmResult.stderr);
|
||||
if (stderr.includes('already part of a swarm')) {
|
||||
logger.info('Docker Swarm already initialized');
|
||||
} else {
|
||||
logger.warn(`Docker Swarm init warning: ${stderr.trim()}`);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Install systemd service
|
||||
*/
|
||||
@@ -53,6 +106,9 @@ export class OneboxDaemon {
|
||||
try {
|
||||
logger.info('Installing Onebox daemon service...');
|
||||
|
||||
// Ensure Docker is installed
|
||||
await this.ensureDocker();
|
||||
|
||||
// Initialize smartdaemon if needed
|
||||
if (!this.smartdaemon) {
|
||||
this.smartdaemon = new plugins.smartdaemon.SmartDaemon();
|
||||
|
||||
@@ -3,6 +3,6 @@
|
||||
*/
|
||||
export const commitinfo = {
|
||||
name: '@serve.zone/onebox',
|
||||
version: '1.13.13',
|
||||
version: '1.14.4',
|
||||
description: 'Self-hosted container platform with automatic SSL and DNS - a mini Heroku for single servers'
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user