alpinux.site.2026/admin/static/admin.css
Cédrix 60eb8bc952 feat: interface admin portail.alpinux.org/admin/ — déclencher mkdocs build
Mini-app Flask (admin/) accessible à https://portail.alpinux.org/admin/ :
- Authentification AlpID OIDC, accès restreint au groupe « admins » Keycloak
- Bouton « Lancer mkdocs build » avec confirmation
- Exécution de deploy-wiki.sh en arrière-plan (thread), log capturé en direct
- Polling JS toutes les 2s pendant le build (status + log + historique)
- Affichage du journal en terminal sombre avec suivi automatique
- Historique des 20 derniers builds (date, déclencheur, résultat, durée)
- ProxyFix pour X-Forwarded-Proto / X-Script-Name (Apache reverse proxy)

Infrastructure :
- scripts/portail.alpinux.org.admin.conf : bloc ProxyPass pour ISPConfig
- scripts/alpinux-admin.service : systemd Gunicorn port 5002
- admin/.env.example, admin/requirements.txt

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-03 12:34:18 +02:00

71 lines
4.4 KiB
CSS

:root {
--blue: #1a6bbf;
--blue-dark: #0f4e8f;
--blue-light:#e8f1fb;
--bg: #f3f6fb;
--text: #1a1a2e;
--muted: #666;
--radius: 10px;
--shadow: 0 2px 12px rgba(26,107,191,.1);
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: 'Segoe UI', system-ui, sans-serif; background: var(--bg); color: var(--text); min-height: 100vh; }
code { background: #e8eef7; padding: .1rem .4rem; border-radius: 4px; font-size: .88em; }
a { color: var(--blue); }
/* ── Header ── */
header { background: var(--blue-dark); color: #fff; }
.header-inner { max-width: 900px; margin: 0 auto; padding: .8rem 1.5rem; display: flex; align-items: center; gap: 1rem; }
.brand { display: flex; align-items: center; gap: .6rem; color: #fff; font-size: 1.1rem; text-decoration: none; }
.brand strong { font-weight: 800; }
.brand-sub { opacity: .7; font-weight: 300; }
.brand img { border-radius: 5px; }
.header-user { margin-left: auto; display: flex; align-items: center; gap: 1rem; color: rgba(255,255,255,.85); font-size: .9rem; }
.btn-logout { color: rgba(255,255,255,.75); font-size: .85rem; border: 1px solid rgba(255,255,255,.4); border-radius: 4px; padding: .3rem .7rem; text-decoration: none; }
.btn-logout:hover { background: rgba(255,255,255,.1); color: #fff; }
/* ── Main ── */
main { max-width: 900px; margin: 2rem auto; padding: 0 1.5rem 3rem; display: flex; flex-direction: column; gap: 1.5rem; }
/* ── Build card ── */
.build-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.8rem 2rem; }
.build-card-header { display: flex; align-items: flex-start; gap: 1rem; justify-content: space-between; flex-wrap: wrap; margin-bottom: .8rem; }
.build-card-header h2 { font-size: 1.1rem; margin-bottom: .2rem; }
.subtitle { font-size: .85rem; color: var(--muted); }
.build-meta { display: flex; gap: 1.5rem; font-size: .85rem; color: var(--muted); margin-bottom: 1.2rem; flex-wrap: wrap; }
.btn { display: inline-flex; align-items: center; gap: .5rem; padding: .65rem 1.6rem; border-radius: 6px; font-size: .95rem; font-weight: 600; cursor: pointer; border: none; transition: all .15s; }
.btn-build { background: var(--blue); color: #fff; font-size: 1rem; }
.btn-build:hover:not(:disabled) { background: var(--blue-dark); }
.btn-build:disabled { opacity: .55; cursor: not-allowed; }
/* ── Status badges ── */
.status-badge { display: inline-block; padding: .25rem .7rem; border-radius: 20px; font-size: .82rem; font-weight: 700; white-space: nowrap; }
.status-badge.running { background: #fff3d4; color: #8a5c00; }
.status-badge.success { background: #d4f0dc; color: #1a6b35; }
.status-badge.failure { background: #fde8e8; color: #8a0000; }
.status-badge.idle { background: var(--blue-light); color: var(--blue-dark); }
/* ── Log ── */
.log-section { background: #111827; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.log-header { display: flex; align-items: center; justify-content: space-between; padding: .7rem 1.2rem; background: #1f2937; color: #d1d5db; }
.log-header h3 { font-size: .9rem; font-weight: 600; }
.scroll-toggle { display: flex; align-items: center; gap: .4rem; font-size: .82rem; color: #9ca3af; cursor: pointer; }
.scroll-toggle input { cursor: pointer; accent-color: var(--blue); }
.log-output { color: #a3e635; font-family: 'Courier New', monospace; font-size: .82rem; line-height: 1.55; padding: 1rem 1.2rem; max-height: 400px; overflow-y: auto; white-space: pre-wrap; word-break: break-word; }
/* ── History ── */
.history-section { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.5rem 1.8rem; }
.history-section h3 { font-size: 1rem; margin-bottom: 1rem; color: var(--blue-dark); }
.history-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.history-table th { text-align: left; padding: .5rem .8rem; background: var(--blue-light); color: var(--blue-dark); font-weight: 600; }
.history-table td { padding: .5rem .8rem; border-bottom: 1px solid var(--blue-light); }
.history-table tr:last-child td { border-bottom: none; }
.empty { text-align: center; color: var(--muted); padding: 1.2rem; }
@media (max-width: 600px) {
.build-card-header { flex-direction: column; }
.header-inner { flex-wrap: wrap; }
.history-table th:nth-child(4), .history-table td:nth-child(4) { display: none; }
}