9 Commits
1.0.0 ... BUG-2

Author SHA1 Message Date
fccview
b267fb9ce6 Fix scripts not working if description is empty 2025-08-26 09:30:58 +01:00
fccview
032c63cfbd build legacy branches 2025-08-26 08:04:39 +01:00
fccview
89fed1f1b4 Merge branch 'feature/ARM64' 2025-08-25 17:43:43 +01:00
fccview
129f4d8464 trigger workflow 2025-08-25 14:04:00 +01:00
fccview
9d42a99c71 publish without dockerfile hardcoded platform 2025-08-25 13:57:51 +01:00
fccview
5eef50aeb9 fix docker publish 2025-08-25 13:42:05 +01:00
fccview
47ad6d764c update default docker-compose 2025-08-25 13:17:15 +01:00
fccview
185afc0022 Add support for arm64 2025-08-25 13:09:07 +01:00
fccview
0b4ebe7240 Add support for arm64 2025-08-25 13:05:45 +01:00
5 changed files with 52 additions and 10 deletions

View File

@@ -2,7 +2,7 @@ name: Docker
on:
push:
branches: ["main"]
branches: ["main", "legacy", "feature/*", "bugfix/*"]
tags: ["v*.*.*"]
pull_request:
branches: ["main"]
@@ -22,6 +22,12 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Log in to the Container registry
uses: docker/login-action@v3
with:
@@ -45,6 +51,7 @@ jobs:
uses: docker/build-push-action@v5
with:
context: .
platforms: linux/amd64,linux/arm64
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}

View File

@@ -75,8 +75,24 @@ services:
- ./snippets:/app/snippets
restart: unless-stopped
init: true
# Default platform is set to amd64, can be overridden by using arm64.
#platform: linux/arm64
```
### ARM64 Support
The application supports both AMD64 and ARM64 architectures:
**For AMD64 users**: No changes needed - the default configuration works out of the box.
**For ARM64 users**: Uncomment the platform line in your `docker-compose.yml`:
```yaml
platform: linux/arm64
```
**Note**: Multi-platform Docker images are automatically built for both architectures. The image will automatically use the correct architecture for your platform.
2. Build and run with Docker Compose:
```bash
@@ -85,7 +101,7 @@ docker compose up --build
3. Open your browser and navigate to `http://localhost:40123`
**Note**: The Docker implementation uses direct file access to read and write crontab files, ensuring real-time synchronization with the host system's cron jobs. This approach bypasses the traditional `crontab` command limitations in containerized environments.
**Note**: The Docker implementation uses direct file access to read and write crontab files, ensuring real-time synchronization with the host system's cron jobs. This approach bypasses the traditional `crontab` command limitations in containerized environments
### Local Development

View File

@@ -39,10 +39,21 @@ export function ScriptModal({
}: ScriptModalProps) {
const handleSubmit = async (e: React.FormEvent) => {
e.preventDefault();
if (!form.name.trim()) {
showToast("error", "Validation Error", "Script name is required");
return;
}
if (!form.content.trim()) {
showToast("error", "Validation Error", "Script content is required");
return;
}
const formData = new FormData();
formData.append("name", form.name);
formData.append("description", form.description);
formData.append("content", form.content);
formData.append("name", form.name.trim());
formData.append("description", form.description.trim());
formData.append("content", form.content.trim());
Object.entries(additionalFormData).forEach(([key, value]) => {
formData.append(key, value);
@@ -66,18 +77,24 @@ export function ScriptModal({
<div className="grid grid-cols-1 md:grid-cols-2 gap-4">
<div>
<label className="block text-sm font-medium text-foreground mb-2">
Script Name
Script Name <span className="text-red-500">*</span>
</label>
<Input
value={form.name}
onChange={(e) => onFormChange({ name: e.target.value })}
placeholder="My Script"
required
className={
!form.name.trim()
? "border-red-300 focus:border-red-500 focus:ring-red-500"
: ""
}
/>
</div>
<div>
<label className="block text-sm font-medium text-foreground mb-2">
Description
Description{" "}
<span className="text-muted-foreground text-xs">(optional)</span>
</label>
<Input
value={form.description}
@@ -102,7 +119,7 @@ export function ScriptModal({
<div className="flex items-center gap-2 mb-4 flex-shrink-0">
<FileText className="h-4 w-4 text-primary" />
<h3 className="text-sm font-medium text-foreground">
Script Content
Script Content <span className="text-red-500">*</span>
</h3>
</div>
<div className="flex-1 min-h-0">

View File

@@ -46,13 +46,13 @@ async function scanScriptsDirectory(dirPath: string): Promise<Script[]> {
const content = await fs.readFile(filePath, "utf-8");
const metadata = parseMetadata(content);
if (metadata.id && metadata.title && metadata.description) {
if (metadata.id && metadata.title) {
const stats = await fs.stat(filePath);
scripts.push({
id: metadata.id,
name: metadata.title,
description: metadata.description,
description: metadata.description || "",
filename: file,
createdAt: stats.birthtime.toISOString(),
});

View File

@@ -38,3 +38,5 @@ services:
- ./snippets:/app/snippets
restart: unless-stopped
init: true
# Default platform is set to amd64, can be overridden by using arm64.
#platform: linux/arm64