diff --git a/figures/Atos-logo-880x660.png b/figures/Atos-logo-880x660.png new file mode 100644 index 0000000000000000000000000000000000000000..749b882b824d1e47f9b07a0b40b51f07e746f935 Binary files /dev/null and b/figures/Atos-logo-880x660.png differ diff --git a/figures/atos-logo.png b/figures/atos-logo.png new file mode 100644 index 0000000000000000000000000000000000000000..395abdce9b65535c2d3a08a89cf32f3aa588d111 Binary files /dev/null and b/figures/atos-logo.png differ diff --git a/slides.pdf b/slides.pdf index 2d07d4bb9aec089a2aa2db48beea062be838b15c..94dc9faa18e9375f390b9106492d510f42bc1e9b 100644 Binary files a/slides.pdf and b/slides.pdf differ diff --git a/slides.tex b/slides.tex index 52de98bda738e20634d1c39cab45d085bc71d66f..f018ec769d6f3aa4926c3659a2aeef6a97806f38 100644 --- a/slides.tex +++ b/slides.tex @@ -14,7 +14,7 @@ \usepackage{array,booktabs} \usepackage{pgfpages} \usepackage{listings} -\setbeameroption{show notes on second screen=right} +%\setbeameroption{show notes on second screen=right} \lstset{language=Bash} \definecolor{identifiercolor}{rgb}{0,0,0} @@ -74,13 +74,14 @@ \date{Rennes 2019, \today} \author{ \underline{Adrien Faure}, Millian Poquet\\ - \vspace{1cm} - % \includegraphics[height=1cm]{figures/logo-inp.png} - \hspace{0.1cm} + \vspace{0.9cm} + % \includegraphics[height=1cm]{figureslogo-inp.png} \includegraphics[height=1cm]{figures/logo-inria.jpg} + \hspace{0.3cm} + \includegraphics[height=1cm]{./figures/atos-logo.png} % \hspace{0.1cm} % \includegraphics[height=1cm]{figures/logo-cnrs} - \hspace{0.1cm} + \hspace{0.4cm} \includegraphics[height=1cm]{./figures/logo-lig.jpg} % \hspace{0.1cm} % \includegraphics[height=1cm]{figures/logo-uga @@ -213,6 +214,7 @@ The running environment should be explicit: \end{tcolorbox} Satellites: + \only<1>{ \begin{tcolorbox}[colframe=black,colback=gray!10,coltext=black] NixOS - The Purely Functional Linux Distribution @@ -225,8 +227,23 @@ The running environment should be explicit: \begin{tcolorbox}[colframe=black,colback=gray!10,coltext=black] NixOps - The NixOS Deployment Tool (2011) \end{tcolorbox} + } + \only<2>{ + \begin{tcolorbox}[colframe=gray!50,colback=gray!1,coltext=gray!100] + NixOS - The Purely Functional Linux Distribution + \end{tcolorbox} + + \begin{tcolorbox}[colframe=gray!50,colback=gray!1,coltext=gray!100] + Hydra - Nix-based continuous build system (2008) + \end{tcolorbox} + + \begin{tcolorbox}[colframe=gray!50,colback=gray!1,coltext=gray!100] + NixOps - The NixOS Deployment Tool (2011) + \end{tcolorbox} + } \end{frame} + \subsection{Expression Language} \begin{frame}{} @@ -275,65 +292,67 @@ The running environment should be explicit: \end{itemize} \end{frame} -\begin{frame}{} - All \emph{official} packages are defined into the repository: - \begin{tcolorbox}[colframe=black,colback=gray!10,coltext=black]{Nixpkgs - \textcolor{red}{\url{https://github.com/NixOS/nixpkgs}}} - \end{tcolorbox} - \begin{columns} - \begin{column}{0.5\textwidth} - \begin{itemize} - \item First commit: Mar 2003 - \item \textbf{$>$22 000} packages - \item \textbf{$>$2 100} contributors - \end{itemize} - \end{column} - \begin{column}{0.5\textwidth} - \begin{itemize} - \item \textbf{$>$183 600} commits - \end{itemize} - \end{column} - \end{columns} -\end{frame} - -\section{How Does it Work ?} +% \begin{frame}{} +% All \emph{official} packages are defined into the repository: +% \begin{tcolorbox}[colframe=black,colback=gray!10,coltext=black]{Nixpkgs - \textcolor{red}{\url{https://github.com/NixOS/nixpkgs}}} +% \end{tcolorbox} +% \begin{columns} +% \begin{column}{0.5\textwidth} +% \begin{itemize} +% \item First commit: Mar 2003 +% \item \textbf{$>$22 000} packages +% \item \textbf{$>$2 100} contributors +% \end{itemize} +% \end{column} +% \begin{column}{0.5\textwidth} +% \begin{itemize} +% \item \textbf{$>$183 600} commits +% \end{itemize} +% \end{column} +% \end{columns} +% \end{frame} + +\section{Nix Structure} + +\begin{frame}{Main Concept} + + % Nix borrows its concept from Functional Languages. \\ + \begin{tcolorbox}[colframe=black,colback=gray!10,coltext=black] + Nix applies the concept of functional programming languages to packages management. + \end{tcolorbox} + \vspace{1em} -\begin{frame} + Each software building action is described through functions. + \note{Function into the Functional paradigm point of view} - How does it works / How can we use it ? + \vspace{1em} + Packages dependencies are also functions given as inputs. \end{frame} \begin{frame}[fragile]{Derivations} - \begin{onlyenv}<1> - \note{https://nixos.org/nixos/nix-pills/our-first-derivation.html\\} - Nix refers to \textbf{derivation} instead of package. \\ - - \vspace{1em} - From the Nix point of view, a derivation is a build action, \\ - described by a Nix set. + \note{https://nixos.org/nixos/nix-pills/our-first-derivation.html\\} + % Nix refers to \textbf{derivation} instead of package. \\ + % A package is a defined by a \textbf{derivation}. \\ - \vspace{1em} - Once built, a derivation is located into a common place\\ - the \textbf{Nix store}. - - \vspace{1em} - - A derivation is identified with a unique hash as follows: - - \begin{lstlisting}[language=Nix,basicstyle=\small] - /nix/store/hash-name - \end{lstlisting} + % It can be build with the command \textit{nix-build}. + \begin{tcolorbox}[colframe=black,colback=gray!10,coltext=black] + A derivation is a Nix build action. + \end{tcolorbox} + \begin{onlyenv}<2> - \note{A derivation is a set of attributes describing a building process \\} + \vspace{1em} + It is an attribute set describing how to build a package. \end{onlyenv} + \pause - \begin{onlyenv}<2> - %\begin{adjustbox}{width=\textwidth,height=\textheight,keepaspectratio} \vspace{-1em} + \begin{onlyenv}<3> + \begin{lstlisting}[language=Nix,basicstyle=\small] -{ +stdenv.mkDerivation { name = "chord"; src = fetchurl { @@ -341,24 +360,25 @@ The running environment should be explicit: sha256 = "1h2jgq5pspyiskffq777nhi5rf0y8h..."; }; - builder = "build.sh"; buildInputs = [ simgrid boost cmake ]; meta = ..; } +\end{lstlisting} - \end{lstlisting} - \end{onlyenv} -\end{frame} +\end{onlyenv} +\end{frame} \begin{frame}[fragile]{Store} - All build derivations are stored in the nix store: \texttt{/nix/store}.\\ +\begin{tcolorbox}[colframe=black,colback=gray!10,coltext=black] +Nix uses a single directory to store every packages. +\end{tcolorbox} \vspace{1em} - They are identified with a sha-256 hash of the source nix file and + A packagesr is identified with a sha-256 hash of the source nix file and its "inputs". \begin{lstlisting}[basicstyle=\small] @@ -376,6 +396,24 @@ The running environment should be explicit: \end{frame} +\begin{frame}[plain]{Nixpkgs} + +\begin{tcolorbox}[colframe=black,colback=gray!10,coltext=black] + \center + NixPkgs is an open source git repository. +\end{tcolorbox} + + \only<1>{ + \vspace{1em} + It contains the derivations of all application (and libraries) \emph{officialy} available with Nix. + } + \only<1>{ + \vspace{1em} + Packages are distributed as Nix expression (the so called derivations). + } + +\end{frame} + \begin{frame}[plain]{Channels} \only<1>{