Compare commits
8 Commits
v1.1.1
...
fix/argon2
| Author | SHA1 | Date | |
|---|---|---|---|
| b293d6631b | |||
| 54763bd583 | |||
| 2bdbc8af5a | |||
| 87bd5d2162 | |||
| 836d409e3b | |||
| e17b740415 | |||
| 0d151d36b9 | |||
| 4fbcf3d35a |
3
.github/workflows/ci.yml
vendored
3
.github/workflows/ci.yml
vendored
@ -135,6 +135,7 @@ jobs:
|
|||||||
needs: [rust-format, clippy, rust-test, security-audit, frontend-lint]
|
needs: [rust-format, clippy, rust-test, security-audit, frontend-lint]
|
||||||
if: startsWith(github.ref, 'refs/tags/v')
|
if: startsWith(github.ref, 'refs/tags/v')
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
timeout-minutes: 60
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
@ -166,7 +167,7 @@ jobs:
|
|||||||
uses: docker/build-push-action@v6
|
uses: docker/build-push-action@v6
|
||||||
with:
|
with:
|
||||||
context: .
|
context: .
|
||||||
platforms: linux/amd64,linux/arm64
|
platforms: linux/amd64
|
||||||
push: true
|
push: true
|
||||||
tags: ${{ steps.meta.outputs.tags }}
|
tags: ${{ steps.meta.outputs.tags }}
|
||||||
labels: ${{ steps.meta.outputs.labels }}
|
labels: ${{ steps.meta.outputs.labels }}
|
||||||
|
|||||||
@ -12,7 +12,7 @@ members = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
[workspace.package]
|
[workspace.package]
|
||||||
version = "1.1.1"
|
version = "1.1.5"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
authors = ["Echo <echo@moon-dragon.us>"]
|
authors = ["Echo <echo@moon-dragon.us>"]
|
||||||
license = "MIT"
|
license = "MIT"
|
||||||
|
|||||||
38
Dockerfile
38
Dockerfile
@ -6,20 +6,36 @@
|
|||||||
# =============================================================================
|
# =============================================================================
|
||||||
|
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Stage 1: Rust build
|
# Stage 1: Rust build (Ubuntu 24.04 + rustup)
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
FROM rust:1.82-bookworm AS rust-builder
|
FROM ubuntu:24.04 AS rust-builder
|
||||||
|
|
||||||
|
ENV DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
RUN apt-get update && apt-get install -y \
|
RUN apt-get update && apt-get install -y \
|
||||||
|
build-essential \
|
||||||
|
curl \
|
||||||
pkg-config \
|
pkg-config \
|
||||||
libssl-dev \
|
libssl-dev \
|
||||||
libfontconfig1-dev \
|
libfontconfig1-dev \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
# Install Rust via rustup (stable channel, provides 1.85+)
|
||||||
|
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain stable
|
||||||
|
ENV PATH="/root/.cargo/bin:${PATH}"
|
||||||
|
|
||||||
WORKDIR /usr/src/app
|
WORKDIR /usr/src/app
|
||||||
|
|
||||||
# Cache dependencies by building a dummy project first
|
# Cache dependencies by building a dummy project first
|
||||||
COPY Cargo.toml Cargo.lock ./
|
COPY Cargo.toml Cargo.lock ./
|
||||||
|
COPY crates/pm-web/Cargo.toml crates/pm-web/Cargo.toml
|
||||||
|
COPY crates/pm-worker/Cargo.toml crates/pm-worker/Cargo.toml
|
||||||
|
COPY crates/pm-core/Cargo.toml crates/pm-core/Cargo.toml
|
||||||
|
COPY crates/pm-agent-client/Cargo.toml crates/pm-agent-client/Cargo.toml
|
||||||
|
COPY crates/pm-auth/Cargo.toml crates/pm-auth/Cargo.toml
|
||||||
|
COPY crates/pm-ca/Cargo.toml crates/pm-ca/Cargo.toml
|
||||||
|
COPY crates/pm-reports/Cargo.toml crates/pm-reports/Cargo.toml
|
||||||
|
COPY crates/migrate-secrets/Cargo.toml crates/migrate-secrets/Cargo.toml
|
||||||
RUN mkdir -p crates/pm-web/src crates/pm-worker/src crates/pm-core/src \
|
RUN mkdir -p crates/pm-web/src crates/pm-worker/src crates/pm-core/src \
|
||||||
crates/pm-agent-client/src crates/pm-auth/src crates/pm-ca/src \
|
crates/pm-agent-client/src crates/pm-auth/src crates/pm-ca/src \
|
||||||
crates/pm-reports/src crates/migrate-secrets/src
|
crates/pm-reports/src crates/migrate-secrets/src
|
||||||
@ -35,6 +51,7 @@ RUN cargo build --release 2>/dev/null || true
|
|||||||
|
|
||||||
# Now build the real project
|
# Now build the real project
|
||||||
COPY crates/ crates/
|
COPY crates/ crates/
|
||||||
|
COPY migrations/ migrations/
|
||||||
RUN cargo build --release
|
RUN cargo build --release
|
||||||
|
|
||||||
# Verify binaries exist
|
# Verify binaries exist
|
||||||
@ -44,9 +61,21 @@ RUN ls -la target/release/pm-web target/release/pm-worker
|
|||||||
RUN strip target/release/pm-web target/release/pm-worker
|
RUN strip target/release/pm-web target/release/pm-worker
|
||||||
|
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
# Stage 2: Frontend build
|
# Stage 2: Frontend build (Ubuntu 24.04 + Node.js 20)
|
||||||
# ---------------------------------------------------------------------------
|
# ---------------------------------------------------------------------------
|
||||||
FROM node:20-bookworm-slim AS frontend-builder
|
FROM ubuntu:24.04 AS frontend-builder
|
||||||
|
|
||||||
|
ENV DEBIAN_FRONTEND=noninteractive
|
||||||
|
|
||||||
|
RUN apt-get update && apt-get install -y \
|
||||||
|
curl \
|
||||||
|
ca-certificates \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
# Install Node.js 20 via NodeSource
|
||||||
|
RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - \
|
||||||
|
&& apt-get install -y nodejs \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
WORKDIR /usr/src/app/frontend
|
WORKDIR /usr/src/app/frontend
|
||||||
COPY frontend/package.json frontend/package-lock.json ./
|
COPY frontend/package.json frontend/package-lock.json ./
|
||||||
@ -64,6 +93,7 @@ RUN apt-get update && apt-get install -y \
|
|||||||
ca-certificates \
|
ca-certificates \
|
||||||
libssl3t64 \
|
libssl3t64 \
|
||||||
libfontconfig1 \
|
libfontconfig1 \
|
||||||
|
openssl \
|
||||||
postgresql-client-16 \
|
postgresql-client-16 \
|
||||||
argon2 \
|
argon2 \
|
||||||
curl \
|
curl \
|
||||||
|
|||||||
18
debian/changelog
vendored
18
debian/changelog
vendored
@ -1,3 +1,21 @@
|
|||||||
|
linux-patch-manager (1.1.5-1) unstable; urgency=low
|
||||||
|
|
||||||
|
* Release v1.1.5
|
||||||
|
|
||||||
|
-- git-echo <git-echo@moon-dragon.us> Mon, 08 Jun 2026 20:15:50 -0500
|
||||||
|
|
||||||
|
linux-patch-manager (1.1.4-1) unstable; urgency=low
|
||||||
|
|
||||||
|
* Release v1.1.4
|
||||||
|
|
||||||
|
-- git-echo <git-echo@moon-dragon.us> Mon, 08 Jun 2026 17:30:35 -0500
|
||||||
|
|
||||||
|
linux-patch-manager (1.1.2-1) unstable; urgency=low
|
||||||
|
|
||||||
|
* Release v1.1.2
|
||||||
|
|
||||||
|
-- git-echo <git-echo@moon-dragon.us> Sun, 07 Jun 2026 21:19:18 -0500
|
||||||
|
|
||||||
linux-patch-manager (1.1.1-1) unstable; urgency=low
|
linux-patch-manager (1.1.1-1) unstable; urgency=low
|
||||||
|
|
||||||
* Release v1.1.1
|
* Release v1.1.1
|
||||||
|
|||||||
2
debian/control
vendored
2
debian/control
vendored
@ -1,5 +1,5 @@
|
|||||||
Package: linux-patch-manager
|
Package: linux-patch-manager
|
||||||
Version: 1.1.1-1
|
Version: 1.1.5-1
|
||||||
Architecture: amd64
|
Architecture: amd64
|
||||||
Maintainer: Moon Dragon <echo@moon-dragon.us>
|
Maintainer: Moon Dragon <echo@moon-dragon.us>
|
||||||
Installed-Size: 45000
|
Installed-Size: 45000
|
||||||
|
|||||||
2
debian/postinst
vendored
Executable file → Normal file
2
debian/postinst
vendored
Executable file → Normal file
@ -208,7 +208,7 @@ generate_admin_password() {
|
|||||||
|
|
||||||
# Hash with argon2 (PHC format, compatible with the application)
|
# Hash with argon2 (PHC format, compatible with the application)
|
||||||
local password_hash
|
local password_hash
|
||||||
password_hash=$(echo -n "${admin_password}" | argon2 salt -id -t 3 -m 65536 -p 1 -l 32 -e)
|
password_hash=$(echo -n "${admin_password}" | argon2 salt -id -t 3 -m 16 -p 1 -l 32 -e)
|
||||||
|
|
||||||
# Update admin user password in database
|
# Update admin user password in database
|
||||||
# Only update if the placeholder hash is still present
|
# Only update if the placeholder hash is still present
|
||||||
|
|||||||
@ -8,7 +8,7 @@
|
|||||||
|
|
||||||
services:
|
services:
|
||||||
db:
|
db:
|
||||||
image: postgres:16-bookworm
|
image: postgres:16
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
environment:
|
environment:
|
||||||
POSTGRES_USER: patch_manager
|
POSTGRES_USER: patch_manager
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "patch-manager-ui",
|
"name": "patch-manager-ui",
|
||||||
"private": true,
|
"private": true,
|
||||||
"version": "1.1.1",
|
"version": "1.1.5",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite",
|
"dev": "vite",
|
||||||
|
|||||||
@ -22,7 +22,7 @@ warn() { echo -e "${YELLOW}[WARN]${NC} $*"; }
|
|||||||
error() { echo -e "${RED}[ERROR]${NC} $*" >&2; exit 1; }
|
error() { echo -e "${RED}[ERROR]${NC} $*" >&2; exit 1; }
|
||||||
|
|
||||||
PROJECT_ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
PROJECT_ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)"
|
||||||
VERSION="1.1.1"
|
VERSION="1.1.5"
|
||||||
RELEASE="1"
|
RELEASE="1"
|
||||||
PKG_NAME="linux-patch-manager"
|
PKG_NAME="linux-patch-manager"
|
||||||
DEB_NAME="${PKG_NAME}_${VERSION}-${RELEASE}_amd64.deb"
|
DEB_NAME="${PKG_NAME}_${VERSION}-${RELEASE}_amd64.deb"
|
||||||
|
|||||||
Reference in New Issue
Block a user