A collection of supporting Github Actions for eGeoffrey.
This workflow is triggered at every push and pull-request and automate the process of:
- Testing an eGeoffrey module code
- Packaging it in a Docker image
- Publishing it to Dockerhub for distribution
- Create a DockerHub account
- Create a DockerHub Access Token
- In the Github repository where your eGeoffrey package resides, go to "Settings", "Secrets" and create a secret called
DOCKERHUB_USERNAME
storing your DockerHub username andDOCKERHUB_TOKEN
storing your DockerHub access code - Commit your code as you would normally do with
egeoffrey-cli commit "new change"
. Theegeoffrey-cli
utility will automatically download and keep up to date the workflow file in your repository - As the new version is committed and pushed to your repository, the build workflow automatically triggers. You can see the result of the execution under "Actions". In case of failure, you will receive an email notification
- If everything goes well, the eGeoffrey package is automatically built and pushed to your DockerHub repository
Every time egeoffrey-cli commit
is run, it will download the latest version of this GitHub Action workflow and deploy it in your local repository, just before committing the changes and pushing them to GitHub. This makes the workflow trigerring as the new code is pushed to GitHub.
The worklof does the following:
- Starts up a virtual image
- Checkout the latest version of the code
- Login to DockerHub
- Setup Docker for cross-platform building
- Install eGeoffrey
- Build your eGeoffrey Package
- Install your package
- Wait a few seconds for collecting enough logs
- Check if there are no errors showing up in the logs
- Push the eGeoffrey Package to DockerHub
If any of the above steps fails, the entire workflows fails.