When building a new worker from our official template, a file structure gets created for you to ease the burden of setting up a Python package, a Docker build, with the best development practices:
- YAML configuration file that allows Arkindex to understand what it should do with this repository. To learn more about this file, see YAML configuration.
- YAML file that stores the options you defined when creating a new worker. This file can be reused to fetch template updates.
- Lists which files to exclude from the Docker build context. For more information, see the Docker documentation.
- Specifies configuration options for the Flake8 linter. For more information, see the Flake8 documentation.
- Lists which files to exclude from Git versioning. For more information, see the Git docs.
- Configures the GitLab CI jobs and pipelines. To learn more about the configuration we provide, see GitLab Continuous Integration for workers.
- Configures the automatic Python import sorting rules. For more information, see the isort docs.
- Configures the pre-commit hook.
- Specifies how the Docker image will be built. You can change the instructions in this file to update the image to the needs of your worker, for example to install system dependencies.
- Lists the Python dependencies your worker relies on. Those are automatically installed by the default Dockerfile.
- Configures the Python unit test runner. For more information, see the tox docs.
- Configures the worker’s Python package.
- Official version number of your worker. Defaults to
- Script that gets run by CI pipelines to build the Docker image.
- An example unit test file.
- Declares the folder as a Python package.
- The core part of the worker. This is where you can write code that processes Arkindex elements.