Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*DS_Store
38 changes: 38 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
FROM node:18.2.0-bullseye

ARG USER_ID
ARG GROUP_ID

ENV USER_ID=${USER_ID}
ENV GROUP_ID=${GROUP_ID}
ENV USER_NAME=mysuer

ENV DEBIAN_FRONTEND noninteractive

RUN getent passwd 1000

RUN userdel -r $(id -u -n ${USER_ID})
RUN groupadd -g ${GROUP_ID} mygroup
RUN useradd -u ${USER_ID} -g ${GROUP_ID} -d /home/myuser -m myuser \
&& apt install ca-certificates bash

ADD apt.conf.d /etc/apt/apt.conf.d

RUN mkdir -p /usr/src/app

RUN apt update && apt install -y unzip git wget

RUN export PATH=/usr/lib/i386-linux-gnu/ImageMagick-6.8.9/bin-Q16:$PATH

ADD static /usr/src/app

RUN chown -R ${USER_ID}:${GROUP_ID} /usr/src/app

USER ${USER_ID}:${GROUP_ID}

WORKDIR /usr/src/app

RUN npm install

ENTRYPOINT [ "npm" ]
CMD [ "run build" ]
27 changes: 27 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
IMAGE_NAME="bitprepared/dvd-site-generator"
VERSION=bullseye

build-image:
docker buildx build --build-arg USER_ID=1000 --build-arg GROUP_ID=1000 -t $(IMAGE_NAME):$(VERSION) -t $(IMAGE_NAME):latest .

build-dvd:
docker run --rm -i -v "${PWD}/dvd:/usr/src/app/dvd" -v "${PWD}/dati:/usr/src/app/dati" -v "${PWD}/static/index.js:/usr/src/app/index.js" -v "${PWD}/lib:/usr/src/app/lib" -v "${PWD}/assets:/usr/src/app/assets" -v "${PWD}/build:/usr/src/app/build" -t $(IMAGE_NAME):$(VERSION) run build

build-dvd-mounted:
docker run --rm -i -v "${PWD}/dvd:/usr/src/app/dvd" -v "${PWD}/dati:/usr/src/app/dati" -v "${PWD}/static/index.js:/usr/src/app/index.js" -v "${PWD}/lib:/usr/src/app/lib" -v "${PWD}/assets:/usr/src/app/assets" -v "/home/yoghi/blackhole/dvd:/usr/src/app/build" -t $(IMAGE_NAME):$(VERSION) run build

riduci-foto:
$(shell ~/Script/convert_image_smp.sh dvd/diariofotografico/materiale/foto_originali 1600 dvd/diariofotografico/materiale/foto UPDATE)

jpg-rename:
$(shell find -name '*.JPG' -exec rename .JPG .jpg {} \;)

clean:
rm -rf build/*

outdated:
docker run --rm -i -v "${PWD}/dvd:/usr/src/app/dvd" -v "${PWD}/dati:/usr/src/app/dati" -v "${PWD}/static/index.js:/usr/src/app/index.js" -v "${PWD}/lib:/usr/src/app/lib" -v "${PWD}/assets:/usr/src/app/assets" -v "${PWD}/build:/usr/src/app/build" -t $(IMAGE_NAME):$(VERSION) outdated

open:
qutebrowser file://${PWD}/build/index.html &

9 changes: 0 additions & 9 deletions README.md

This file was deleted.

43 changes: 43 additions & 0 deletions Readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@

# Obiettivo
Creare un dvd/usb che possa essere consegnato a chi partecipa ad un evento, con tutti i documenti/applicazioni utilizzate in modo che rimanga un ricordo

# Build image
Creazione docker image

`make build-image`

## Build local on debian jessie x86 ##

Prima dell'installazione (npm install) controllare le dipendenze

~~~
curl -sL https://deb.nodesource.com/setup_8.x | bash
apt install libmagick++-dev
~~~

e alla fine eseguire

~~~
export PATH=/usr/lib/i386-linux-gnu/ImageMagick-6.8.9/bin-Q16:$PATH
~~~

# Build usb/dvd image

`make build-dvd`


## Alberatura Intranet ##
NOTA: (vedi .htaccess -> ~/www/intranet)

* http://local.bitprepared.it/sito/ -> ~/www/intranet/sito
* http://local.bitprepared.it/ -> ~/www/intranet/sito
* http://local.bitprepared.it/ -> ~/www/intranet/dashboard
* http://local.bitprepared.it/argh/web/login -> ~/www/intranet/argh/web/


## TODO
- [ ] serve da implementare l'ultimo comando in make per la sync su chiavetta usb
- [ ] serve comando per creare iso
- [ ] serve il reset della struttura dati
- [ ]
1 change: 1 addition & 0 deletions apt.conf.d/01proxy
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Acquire::http { Proxy "http://mirror.local.costigiola.net:3142"; };
269 changes: 269 additions & 0 deletions assets/css/inettuts.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,269 @@
body, img, p, h1, h2, h3, h4, h5, h6, ul, ol {
border: medium none;
list-style: none outside none;
margin: 0;
padding: 0;
}

body {
background-attachment: fixed;
/* background-color: #42AC88; */
background-color: white;
/*background-image: url("/css/sfondoStatico.gif");*/
/* background-position: center top; */
/* background-repeat: no-repeat; */


background-image: url("/img/sfondo.jpg");

/* Full height */
height: 100%;

/* Center and scale the image nicely */
background-position: center;
background-repeat: no-repeat;
background-size: cover;


font-family: Arial,Verdana,Sans-Serif;
font-size: 0.8em;
}
a {
color: white;
}
.color-yellow {
background: none repeat scroll 0 0 #F2BC00;
}
.color-red {
background: none repeat scroll 0 0 #DD0000;
}
.color-blue {
background: none repeat scroll 0 0 #148EA4;
}
.color-white {
background: none repeat scroll 0 0 #DFDFDF;
}
.color-orange {
background: none repeat scroll 0 0 #F66E00;
}
.color-green {
background: none repeat scroll 0 0 #8DC100;
}
.color-yellow h3, .color-white h3, .color-green h3 {
color: #000000;
}
.color-red h3, .color-blue h3, .color-orange h3 {
color: #FFFFFF;
}
#head {
/*background: url("/css/head-bg.png") repeat-x scroll 0 0 #000000;*/
height: 100px;
}
#head h1 {
/* color: #FFFFFF; */
color: #000000;
line-height: 100px;
text-align: center;
}
#navigation {
text-align: right;
}
#columns .column {
float: left;
height: auto !important;
min-height: 400px;
width: 33.3%;
min-width: 400px;
}
#columns .column-small {
float: left;
height: auto !important;
min-height: 400px;
width: 20%;
min-width: 200px;
}
#columns #column1 {
/* background: url("/css/column-bg-left.png") no-repeat scroll right top transparent; */
}
#columns #column3 {
/* background: url("/css/column-bg-right.png") no-repeat scroll left top transparent; */
}
#columns #column1 .widget {
margin: 30px 35px 0 25px;
}
#columns #column3 .widget {
margin: 30px 25px 0 35px;
}
#columns .widget {
border-radius: 4px 4px 4px 4px;
margin: 30px 20px 0;
padding: 2px;
}
#columns .widget .widget-head {
color: #000000;
height: 30px;
line-height: 30px;
overflow: hidden;
width: 100%;
}
#columns .widget .widget-head h3 {
float: left;
padding: 0 5px;
}
#columns .widget .widget-content {
background: url("/img/widget-content-bg.png") repeat-x scroll 0 0 #333333;
border-bottom-left-radius: 2px;
border-bottom-right-radius: 2px;
color: #DDDDDD;
line-height: 1.2em;
overflow: hidden;
padding: 0 5px;
}
#columns .widget .widget-content p {
border-bottom: 1px solid #666666;
padding: 0.8em 0;
}
#columns .widget .widget-content img {
/* border: 1px solid #FFFFFF; */
float: right;
margin: 10px;
}
#columns .widget .widget-content pre {
color: #EEEEEE;
font-size: 12px;
padding: 0.5em 5px;
}
#columns .widget .widget-content ul {
list-style: disc outside none;
padding: 5px 0 5px 20px;
}
#columns .widget .widget-content ul li {
padding: 3px 0;
}
#columns .widget .widget-content ul.images {
height: 1%;
list-style: none outside none;
padding: 7px 0 0;
}
#columns .widget .widget-content ul.images li {
display: inline;
float: left;
}
#columns .widget .widget-content ul.images img {
display: inline;
float: left;
margin: 0 0 7px 7px;
}



/** MENUBAR */

#board {
margin: 0 auto;
}

.module {
float: left;
text-align: center;
margin: 10px;
}

#bargraph>div {
}

.bar {
position: relative;
height: auto;
float: left;
padding: 0 12px;
}
.bars {
border-bottom: 1px solid #999;
float: left;
}
.bar-title {
margin-top: 12px;
float: left;
}

.bar .header {
top: -8px;
position:relative;
font-size: 36px;
font-weight: thin;
letter-spacing: -0.08em;
}
.bar .total {
color: #fff;
font-weight: bold;
}
.bar .remaining {
color: #6cdaff;
}

.bar .view {
border-width: 3px;
border-style: solid;
-moz-border-radius-topright: 3px;
-webkit-border-top-right-radius: 3px;
-moz-border-radius-topleft: 3px;
-webkit-border-top-left-radius: 3px;
border-bottom: 0px;
}

#bar_1 {
background: #FFDF00;
border-color: #FFDF00;
border-left-color: #f3f35b;
border-top-color: #f3f35B;
border-right-color: #d5a110;
}

#bar_2 {
background: #0000FF;
border-color: #0000FF;
border-left-color: #2151E3;
border-top-color: #2151E3;
border-right-color: #0000AD;
}

#bar_3 {
background: #FD3B15;
border-color: #FD3B15;
border-left-color: #ff4c21;
border-top-color: #ff4c21;
border-right-color: #cd2e14;
}

#bar_4 {
background: #FFA500;
border-color: #FFA500;
border-left-color: #F2B125;
border-top-color: #F2B125;
border-right-color: #FF8C00;
}

#bar_5 {
background: #107CF8;
border-color: #107CF8;
/* border-left-color: #3368d7; */
border-left-color: #1288ff;
border-top-color: #1288ff;
border-right-color: #3368d7;
}

#bar_6 {
background: #d8d309;
border-color: #d8d309;
/* border-left-color: #beba06; */
border-left-color: #ede80a;
border-top-color: #ede80a;
border-right-color: #beba06;
}


.gaibrush_logo {
text-align: center;
}

Loading