Bouts de Code
Petits morceaux de code écrits après de longues recherches, mais que j’ai finalement dû enlever et que je ne veux pas perdre. Principalement ceux ou j’ai du fouiller la documentation et que j’aimerai garder en mémoire.
2024
- Insert ESM Module as custom script tag with contents with Nuxt v2 Need to inject custom ESM modules into your Nuxt v2 pages? This guide shows how to properly add client-side ECMAScript modules during build time, going beyond simple static file loading. Perfect for integrating Web Components or other external modules while maintaining full control over script contents and build variables.Tags
nuxt configuration javascript esm - 📁 snippet
2015
- Add OpenStack instance meta-data info in your salt grains Ever wanted to target salt states based on data only the underlying OpenStack cluster knows. Here’s how I did it.Tags
linux operations salt-stack cloud-computing open-source - 📁 snippet
- A few useful GNU/Linux truth tests while creating salt states A common task while writing server configuration management manifests is to make sure that some enforcements are run in specific situations.Tags
linux salt-stack cloud-computing procedures - 📁 snippet
2013
- Encapsulate a LDAP DN string using Arrays in PHP While I was writing an authentication and privileges assignation mechanism using information provided by an ActiveDirectory's LDAP DN string into my project's web application, I realized that there was no documented way to extract information from it. This snippet is about reading a complex DN string, and "explode" it into a manageable PHP Array.Tags
techniques php web - 📁 snippet