10 Commits

Author SHA1 Message Date
Stephen Simpson
c5651d6926 Improve README.md: Update command-line options for clarity and add new arguments
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
2025-12-05 09:28:41 -06:00
Stephen Simpson
70414a552d CUSP-1346 - Add support for existing-folders
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
2025-12-05 09:19:52 -06:00
Stephen Simpson
1c6fa0e98c CUSP-1344 - Fix version layout on homepage
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
2025-12-04 16:22:57 -06:00
Stephen Simpson
68b9310862 CUSP-1345 CUSP-1343 CUSP-1344 - Add older version ability
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
2025-12-04 15:49:42 -06:00
Stephen Simpson
890d7fc8f9 CUSP-1342 - Fix See Also
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
2025-12-04 12:40:26 -06:00
Stephen Simpson
907d92bb16 CUSP-1339 -- Fixed another usecase
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
2025-12-04 12:15:33 -06:00
Stephen Simpson
ffc0d11bbb CUSP-1339 -- Remove TM
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
2025-12-04 12:01:57 -06:00
Stephen Simpson
fc2f024d60 CUSP-1341 - Fix man pages that link to other pages
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
2025-12-04 11:53:39 -06:00
Stephen Simpson
47db0185c5 Remove open source attribution notice from footer
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
2025-12-04 11:46:14 -06:00
Stephen Simpson
f474c238dc CUSP-1340
Signed-off-by: Stephen Simpson <ssimpson89@users.noreply.github.com>
2025-12-04 09:52:19 -06:00
5 changed files with 35 additions and 167 deletions

View File

@@ -25,26 +25,39 @@ on:
jobs:
build:
runs-on: ubuntu-latest
container:
image: rockylinux:9
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Build Docker image
- name: Install system dependencies
run: |
docker build -t rocky-man:latest .
dnf install -y \
python3.11 \
python3.11-pip \
mandoc \
rpm-build \
dnf-plugins-core \
git
- name: Create output directories
- name: Install UV
run: |
mkdir -p ./html ./tmp
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Build man pages in container
- name: Install Python dependencies
run: |
docker run --rm \
-v "$(pwd)/html:/data/html" \
-v "$(pwd)/tmp:/data/tmp" \
rocky-man:latest \
--versions ${{ github.event.inputs.versions || '8.10 9.6 10.0' }} \
uv pip install --system -e .
- name: Build man pages
run: |
python3.11 -m rocky_man.main \
--versions ${{ github.event.inputs.versions || '8.10 9.5' }} \
--output-dir ./html \
--download-dir ./tmp/downloads \
--extract-dir ./tmp/extracts \
--verbose
env:
PYTHONUNBUFFERED: 1
@@ -55,3 +68,11 @@ jobs:
name: rocky-man-pages
path: html/
retention-days: 30
- name: Deploy to GitHub Pages
if: github.ref == 'refs/heads/main'
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./html
force_orphan: true

154
Jenkinsfile vendored
View File

@@ -1,154 +0,0 @@
// Jenkinsfile for Rocky Man
pipeline {
agent {
kubernetes {
yaml """
apiVersion: v1
kind: Pod
metadata:
labels:
jenkins: agent
spec:
containers:
- name: docker
image: docker:24-dind
securityContext:
privileged: true
volumeMounts:
- name: docker-sock
mountPath: /var/run
command:
- dockerd-entrypoint.sh
- name: docker-cli
image: docker:24-cli
command:
- cat
tty: true
volumeMounts:
- name: docker-sock
mountPath: /var/run
- name: b2
image: backblazeit/b2:latest
command:
- cat
tty: true
volumes:
- name: docker-sock
emptyDir: {}
"""
}
}
parameters {
string(
name: 'VERSIONS',
defaultValue: '8.10 9.7 10.1',
description: 'Rocky Linux versions to build (space-separated)'
)
string(
name: 'B2_BUCKET_NAME',
defaultValue: 'rockyman',
description: 'B2 bucket name for uploads'
)
string(
name: 'EXISTING_VERSIONS',
defaultValue: '',
description: 'Existing versions already built (space-separated)'
)
string(
name: 'PARALLEL_DOWNLOADS',
defaultValue: '5',
description: 'Number of parallel downloads'
)
string(
name: 'PARALLEL_CONVERSIONS',
defaultValue: '10',
description: 'Number of parallel conversions'
)
}
options {
buildDiscarder(logRotator(numToKeepStr: '10'))
timeout(time: 2, unit: 'HOURS')
}
stages {
stage('Checkout') {
steps {
checkout scm
}
}
stage('Build Docker Image') {
steps {
container('docker-cli') {
sh '''
docker build -t rocky-man:${BUILD_NUMBER} .
docker tag rocky-man:${BUILD_NUMBER} rocky-man:latest
'''
}
}
}
stage('Build Man Pages') {
steps {
container('docker-cli') {
sh '''
# Create output directories
mkdir -p ./html ./tmp
# Run the container to build man pages
docker run --rm \
-v "$(pwd)/html:/app/html" \
-v "$(pwd)/tmp:/data/tmp" \
rocky-man:${BUILD_NUMBER} \
--versions ${VERSIONS} \
--parallel-downloads ${PARALLEL_DOWNLOADS} \
--parallel-conversions ${PARALLEL_CONVERSIONS} \
--existing-versions ${EXISTING_VERSIONS}
'''
}
}
}
stage('Upload to B2') {
when {
expression { return params.B2_BUCKET_NAME != "" }
}
steps {
container('docker-cli') {
withCredentials([
string(credentialsId: 'b2-app-id', variable: 'B2_APPLICATION_KEY_ID'),
string(credentialsId: 'b2-app-key', variable: 'B2_APPLICATION_KEY')
]) {
sh '''
docker run --rm \
-v "$(pwd)/html:/workspace/html" \
-e B2_APPLICATION_KEY \
-e B2_APPLICATION_KEY_ID \
backblazeit/b2:latest \
b2v4 sync --compare-versions size /workspace/html/ "b2://${B2_BUCKET_NAME}/"
'''
}
}
}
}
}
post {
success {
echo 'Build completed and uploaded to B2!'
}
failure {
echo 'Build failed!'
}
cleanup {
container('docker-cli') {
sh '''
docker rmi rocky-man:${BUILD_NUMBER} || true
docker rmi rocky-man:latest || true
'''
}
}
}
}

View File

@@ -284,8 +284,7 @@ class WebGenerator:
max_minors = max(len(major_to_minors[major]) for major in sorted_majors)
num_columns = len(sorted_majors)
# Create rows for grid layout (each row has one version from each major)
# This creates the data structure for proper column grouping
# Create rows of versions for side-by-side display
version_rows = []
for minor_idx in range(max_minors):
row = []
@@ -294,7 +293,7 @@ class WebGenerator:
if minor_idx < len(minors_list):
row.append((major, minors_list[minor_idx]))
else:
row.append(None) # Placeholder for empty cells
row.append(None) # Empty cell placeholder
version_rows.append(row)
html = template.render(

View File

@@ -174,6 +174,8 @@
<div class="version-browse">Browse man pages →</div>
{% endif %}
</a>
{% else %}
<div></div>
{% endif %}
{% endfor %}
{% endfor %}