A cookiecutter template for integration services syncpacks
$ pip install cookiecutter
$ cookiecutter https://github.com/ScienceLogic/is_syncpack_cookiecutter.git
You will be asked about basic information:
Prompt | Description |
---|---|
author | Creator of the SyncPack |
url_project | Link to the SyncPack Source Code |
syncpack_name | Name of the SyncPack Module |
syncpack_friendly_name | Display Name of the SyncPack |
syncpack_description | What does this SyncPack do? |
version | Initial SyncPack Version |
requires_minimum_pf_version | Which version(s) of PowerFlow will this SyncPack support? |
dev_container_source | Use SL External if you are not a ScienceLogic employee |
The generated package includes VSCode configuration settings to improve the SyncPack development process.
The generated package will contain a Visual Studio Code DevContainer
When you open the generated folder with VSCode you will get a prompt to open the workspace within the container.
This Container contains a functional environment for developing and testing your SyncPack steps without the need of a full PowerFlow system.
Usage
- After completing the cookie cutter run, open the generated folder in Visual Studio Code
- The .devcontainer folder should be detected and you should be prompted to re-open the workspace in the container. Click Yes.
If you are not prompted or you miss it, Open the command pallet (ctrl+shift+P) and run Remote-Containers: Reopen in Container
Your environemt should now be ready.
If you need any additional syncpacks or packages to be available, simply pip install
them into your container. Remember to add them to your dependancies!
The generated workspace contains a number of tasks to assist with development.
Usage:
- Open the Command Pallet
- Run
Tasks: Run Task
- Choose
PF: Build and Upload SyncPack
- Input your PF Hostname or IP
- Input your PF Username (default: isadmin)
- Input your PF Password (default: isadmin)
SyncPack should now be available to install on your PowerFlow system.
Initializes the pre-commit workflow. Run this after you have added a git repository to your workspace.
Usage:
- Open the Command Pallet
- Run
Tasks: Run Task
- Choose
Pre-Commit: Initialize
Pre-Commit should now be ready to use.
Manually run all Pre-Commit checks.
Usage:
- Open the Command Pallet
- Run
Tasks: Run Task
- Choose
Pre-Commit: Run All Files
Check pre-commit tasts for workflow updates and update them if needed.
Usage:
- Open the Command Pallet
- Run
Tasks: Run Task
- Choose
Pre-Commit: auto-update
The generated package will contain a settings.json
to enable pytest
and configure test discovery.