Services Blog Français

clitoo: make your python callbacks work in CLI too !

| by jpic | python best-practices

Clitoo makes your python callbacks work on CLI too !

This CLI can execute python callbacks with parameters.

Clitoo recognizes 4 types of command line arguments:

  • lone arguments are passed as args
  • arguments with = are passed as kwargs
  • dashed arguments like -f arrive in context.args
  • dashed arguments like -foo=bar arrive in context.kwargs

It doesn’t matter how many dashes you put in the front, they are all removed.

To use the context in your callback just import the clitoo context::

Read More

DevOps since 2005: a  retrospective

| by jpic | python ansible best-practice

This article shares some history of DevOps testing in France during the last few years. How it looked like when I started in the industry in 2004 and almost 15 years later today.

Background

Just a 1337c0d3 that somehow made it so far with the help of a lot of shadow hacking, now somewhat known as “DevOps” in some places …

Pre-DevOps era: the obscurity

In 2004 i was hacking for Jouve which had high tech digital printers which meant that they could make small batches of books, at the time where the market was filled with offset printers that made the minimal batch have to be 1500 or something.

Read More

building-images-with-kaniko-and-gitlab-cicd

| by jpic | gitlab best-practice

https://docs.gitlab.com/ee/ci/docker/using_kaniko.html

kaniko is a tool to build container images from a Dockerfile, inside a container or Kubernetes cluster. kaniko solves two problems with using the docker-in-docker build method: Docker-in-docker requires privileged mode in order to function, which is a significant security concern. Docker-in-docker generally incurs a performance penalty and can be quite slow Read more at docs.gitlab.com

Getting started with Elm

| by jpic | elm

This article was created by Thomas Binetruy as he’s into R&D around Elm for YourLabs but maybe it will help you too !

Introduction

In this short tutorial, we create a basic counter application that changes the title color based on the counter value. We first define our state model, its transitions, and finally our view - function of our current application state.

Setup code

Here are the necessary imports:

elm import Browser import Html exposing (Html, button, div, text, h1) import Html.Events exposing (onClick) import Html.Attributes exposing (alt, class, classList, href, src, title, style)

Read More

clilabs 1.1.1 release

| by jpic | django python best-practice

Clilabs now benefit a new command that automates a series of 3 lines that’s I’ve been typing over and over again during 10 years of Django hacking.

$ clilabs help +django:settings Setting up django has failed ! DJANGO_SETTINGS_MODULE env var not set ! Show settings from django.

How many times have you done the following ?

python manage.py shell
from django.conf import settings
settings.DATABASES # or something

Well it’s over now ! Try this instead:

Read More
Previous Page 8 of 32 Next Page

They trust us

Contact

logo