Configuration

Aperçu

Cette section explique comment configurer complètement un conteneur de mise à jour WorkflowGen. Certaines options sont configurées en tant que variables d'environnement et d'autres sont transmises directement au script du point d'entrée. Il est disponible sous forme d'images Linux et Windows.

Cette image n'est pas conçue pour être prise comme image de base.

Variables d'environnement

Dans le cas de l'image de mise à niveau, les variables d'environnement sont des arguments que vous ne devriez pas avoir à changer souvent lors de la mise à jour de WorkflowGen. De cette façon, vous pouvez facilement passer un fichier qui définit ces variables et le réutiliser entre les exécutions. Voici la liste des variables d'environnement disponibles avec leurs descriptions :

Paramètres de script

Les paramètres de script définissent des options à transmettre en tant qu'arguments directement au conteneur de mise à jour. Ces arguments sont plus susceptibles d'être définis chaque fois que vous exécutez le conteneur, c'est pourquoi ils ne sont pas dans des variables d'environnement. Voici le fichier d'aide du script de point d'entrée. Il décrit tous les paramètres et leurs regroupements et fournit quelques exemples :

NAME
    /usr/local/bin/docker-entrypoint.ps1
    
SYNOPSIS
    Entrypoint script for the upgrade container.
    
    
SYNTAX
    /usr/local/bin/docker-entrypoint.ps1 -FromVersion <String> -ToVersion <String> [-RemainingArgs <Object>] [-Offline] [<CommonParameters>]
    
    /usr/local/bin/docker-entrypoint.ps1 -Command -RemainingArgs <Object> [<CommonParameters>]
    
    /usr/local/bin/docker-entrypoint.ps1 -Help [<CommonParameters>]
    
    
DESCRIPTION
    This script will merge files for the App_Data and wfapps directory between
    the upgrade package of the destination version and the current installation
    ones (passed as volumes).
    
    It will also launch the required SQL migration scripts in order from lowest
    to highest version. Make sure to use a SQL account that has the proper 
    rights to modify the database tables.
    
    The "Files", "LogFiles" and "Ws" subfolders in App_Data are always ignored.
    You don't have to specify them in the exclusion environment variables.
    

PARAMETERS
    -FromVersion <String>
        The current version of WorkflowGen. The starting version of the 
        migration.
        
        Required?                    true
        Position?                    named
        Default value                
        Accept pipeline input?       false
        Accept wildcard characters?  false
        
    -ToVersion <String>
        The version to which you want to migrate the current one.
        
        Required?                    true
        Position?                    named
        Default value                
        Accept pipeline input?       false
        Accept wildcard characters?  false
        
    -Command [<SwitchParameter>]
        Indicates to execute a command inside the container. This is used in 
        conjunction with RemainingArgs
        
        Required?                    true
        Position?                    named
        Default value                False
        Accept pipeline input?       false
        Accept wildcard characters?  false
        
    -RemainingArgs <Object>
        Commands to execute inside the container. If versions are not passed, it is
        executed at the beginning and then it exits after the execution. If 
        versions are passed, it is executed at the end of the script.
        
        Required?                    false
        Position?                    named
        Default value                
        Accept pipeline input?       false
        Accept wildcard characters?  false
        
    -Help [<SwitchParameter>]
        Get full help for this script.
        
        Required?                    true
        Position?                    named
        Default value                False
        Accept pipeline input?       false
        Accept wildcard characters?  false
        
    -Offline [<SwitchParameter>]
        If provided, the script will not try to download the update package. 
        This means that you have to provide the update package from a volume.
        
        Required?                    false
        Position?                    named
        Default value                False
        Accept pipeline input?       false
        Accept wildcard characters?  false
        
    <CommonParameters>
        This cmdlet supports the common parameters: Verbose, Debug,
        ErrorAction, ErrorVariable, WarningAction, WarningVariable,
        OutBuffer, PipelineVariable, and OutVariable. 
        For more information, see about_CommonParameters (https://go.microsoft.com/fwlink/?LinkID=113216). 
    
NOTES
    
    
    File name: docker-entrypoint.ps1
        
    requires -Version 7.0
    
    -------------------------- EXAMPLE 1 --------------------------
    
    PS > docker container run -i "..." advantys/workflowgen-upgrade:latest-ubuntu-18.04 -Help
    
    Displays the full help for the container.
    
    
    
    
    -------------------------- EXAMPLE 2 --------------------------
    
    PS > docker container run -i "..." advantys/workflowgen-upgrade:latest-ubuntu-18.04 -Command dir /mnt/appdata
    
    This executes an arbitrary command inside the container. It can be useful 
    for debugging network issues or other problems prior to the migration.
    
    
    
    
    -------------------------- EXAMPLE 3 --------------------------
    
    PS > docker container run -i "..." advantys/workflowgen-upgrade:latest-ubuntu-18.04 -FromVersion 7.14.10 -ToVersion 7.18.2
    
    This will launch the migration process to upgrade WorkflowGen from version 
    7.14.10 to the 7.18.2 version.
    
    
    
    
    -------------------------- EXAMPLE 4 --------------------------
    
    PS > docker container run -i "..." advantys/workflowgen-upgrade:latest-ubuntu-18.04 -FromVersion 7.14.10 -ToVersion 7.18.2 dir /mnt/appdata
    
    This will launch the migration process to upgrade WorkflowGen from version 
    7.14.10 to the 7.18.2 version. In addition, it will execute an arbitrary command 
    at the end of the migration process.

Utilisation d'un gestionnaire de configuration externe

Certains gestionnaires de configuration populaires supportent les conteneurs Docker prêts à l'emploi. Vous utiliseriez un gestionnaire de configuration externe uniquement pour la définition des variables d'environnement. Voici quelques liens vers leur documentation spécifique pour vous aider à démarrer :

Chef

Ansible

Puppet

Dernière mise à jour