talks/archive/working-with-workspace/slides.rst

223 lines
3.9 KiB
ReStructuredText
Raw Normal View History

2021-01-02 04:03:14 +00:00
.. footer:: @opdavies
Working with Workspace
######################
|
.. class:: titleslideinfo
Oliver Davies, Inviqa
.. raw:: pdf
2021-02-01 02:21:44 +00:00
TextAnnotation "Full stack Developer and Systems Administrator"
TextAnnotation "Organiser of PHP South Wales"
2021-01-02 04:03:14 +00:00
2021-02-01 02:21:44 +00:00
.. page:: standardPage
2021-01-02 04:03:14 +00:00
What is Workspace?
==================
* A tool that we use and maintain at Inviqa
2021-02-01 02:21:44 +00:00
* Primarily for building and managing Docker Compose environments
* Built on Symfony
2021-01-02 04:03:14 +00:00
* Create custom commands for your project environments
* Alternative to a bash script or a Makefile
2021-02-01 02:21:44 +00:00
* And more...
2021-01-02 04:03:14 +00:00
.. raw:: pdf
2021-02-01 02:21:44 +00:00
TextAnnotation "Available on GitHub, MIT licensed."
TextAnnotation "Uses Config, Console, Dependency Injection, Expression Language, Finder and YAML components, as well as Twig."
TextAnnotation "Replacement for commands like 'make build'"
TextAnnotation "Useful for simplifying long, complicated commands, e.g. Docker, Ansible."
2021-01-02 04:03:14 +00:00
Features
========
* Commands
* Functions
* Attributes
2021-02-01 02:21:44 +00:00
* Encrypting/decrypting secrets
* Generating configuration files
* Global services: logging, mail, proxy
.. raw:: pdf
TextAnnotation "Generating settings.php files, Dockerfiles and Docker Compose from a central set of attributes."
TextAnnotation "Logging with kibana, mailhog, Traefik proxy."
Installation
============
.. code-block:: bash
:include: code/installation.txt
.. page:: imagePage
.. image:: images/output-simple.png
:width: 15cm
.. page:: titlePage
.. class:: centredtitle
Replacing your Makefile
.. page:: standardPage
Running simple commands
=======================
.. code-block:: yaml
:include: code/simple-command.txt
:linenos:
.. page:: imagePage
.. image:: images/output-command.png
:width: 15cm
.. page:: standardPage
'run' vs. 'passthru'
====================
.. code-block:: yaml
:include: code/run-passthru.txt
.. image:: images/helper-run.png
:width: 20cm
.. image:: images/helper-passthru.png
:width: 20cm
Attributes
==========
.. code-block:: yaml
:include: code/attributes.txt
:linenos:
Arguments
=========
.. code-block:: yaml
:include: code/arguments.txt
:linenos:
Environment variables
=====================
.. code-block:: yaml
:include: code/environment-variables.txt
:linenos:
Managing secrets
================
.. code-block:: yaml
:include: code/secrets.txt
2021-01-02 04:03:14 +00:00
.. raw:: pdf
2021-02-01 02:21:44 +00:00
TextAnnotation "Shortened for slides"
TextAnnotation "Store default key in an overrides file that's ignored from Git, and somewhere secure like a password manager."
2021-01-02 04:03:14 +00:00
2021-02-01 02:21:44 +00:00
.. page:: titlePage
.. class:: centredtitle
Example: building slides from rst2pdf
.. page:: standardPage
Attributes
==========
.. code-block:: yaml
:include: code/workspace-talks.txt
:end-before: command('pdf generate <talk>'): |
Generating PDFs
===============
.. code-block:: yaml
:include: code/workspace-talks.txt
:start-at: command('pdf generate <talk>'): |
:end-before: command('thumbnail <talk>'):
Generating thumbnails
=====================
.. code-block:: yaml
:include: code/workspace-talks.txt
:start-at: command('thumbnail <talk>'):
.. page:: titlePage
.. class:: centredtitle
Configuration files
.. page:: standardPage
Using confd
===========
.. code-block:: yaml
:include: code/confd.txt
:linenos:
2021-01-02 04:03:14 +00:00
.. raw:: pdf
2021-02-01 02:21:44 +00:00
TextAnnotation ".twig file extension is assumed."
vhost.conf.twig
===============
The source file.
|
.. code-block:: twig
:include: code/nginx-vhost.txt
:end-before: # output
:linenos:
default.conf
============
The generated file.
|
.. code-block:: nginx
:include: code/nginx-vhost.txt
:start-after: # output
:linenos:
.. page:: titlePage
.. class:: centredtitle
Demo: "Workspacing" my site
.. page:: standardPage
2021-01-02 04:03:14 +00:00
Thanks!
=======
References:
* https://github.com/my127/workspace
2021-02-01 02:21:44 +00:00
* https://oliverdavies.link/workspace-demo
* https://oliverdavies.link/workspacing-site
2021-01-02 04:03:14 +00:00
|
Me:
* https://www.oliverdavies.uk