Building multi arch docker image from linux host

Key concepts Container manager.There is an actor, a daemon, or something that pull and run the right image when instructucted to do that.That means, you can use docker, docker swarm mode, kubernetes, k3s, or whatever daemon to monitor or just run containerbased on image taken from some place, and that daemon need to understand what […]

Read More…

React server side rendering as a react based template engine

isomorphic javascript is a technology used to speedup rendering on browser, it can be used a pure version that is server-side-rendering (ssr) to generate template from a react app Motivation: Create a presentation template to be converted to pdf and configurable with data: produce formatted documents. Here:https://www.freecodecamp.org/news/server-side-rendering-your-react-app-in-three-simple-steps-7a82b95db82e/ This is the way the piece of server […]

Read More…

Docker in a Docker

Running a docker container from inside a docker container, I mean. Of course one can define an image that instanciate a container as its default command, and this would lead to an infinite loop of forks … let’s see The infinite containment docker run -v /var/run/docker.sock:/var/run/docker.sock -name whocare alwaysfork Ok, that is bad and I […]

Read More…

A matter of elegance

I need some moment to fully understand this: const compose = ( …fns ) => fns.reduce( ( f, g ) => ( …args ) => f( g( …args ) ) ); reduce method is trickly: when initialValue is not given, the first element of the array is taken as first argument of reduce’s callback parameter, […]

Read More…

Lo sporco lavoro del CI/CD e DevOps

Ora racconto una storia. Beh, la faccio breve, si è fatta una certa.   Da quando c’è bisogno di rilasciare il software in tempo reale sono stati scritti diversi software di supporto per fare lo sporco lavoro di: eseguire test, impacchettare, distribuire i pacchetti nei vari server di destinazioni. Uno di questi è Jenkins, scritto in […]

Read More…

E le Promise ritornano (risolvono in) function?

Stasera ero qui con un test (acceptance) cercando di accrocchiarlo alla meglio. In sostanza usando jsdom e jest ho del codice legacy che utilizza jquery (versione vecchissima) e il js è nella pagina. Lo incollo in un file separato, prepare.js. E visto che devo caricarlo tramite node lo metto dentro una funzione che chiamo con […]

Read More…

Observable. Prendo nota

Probabilmente in ritardo col resto del mondo, h chiarito un punto importante riguardo gli observable, e l’ho capita usando observable-redux. Prendo nota. Definendo un Epic, da uno stream di action$ si restituisce un’altro stream di action La Epic è eseguita dopo che il relativo reducer ha fatto il suo lavoro. È possibile, data una action, […]

Read More…