https://github.com/informaticsmatters/format-support-template
https://github.com/informaticsmatters/format-support-template
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/informaticsmatters/format-support-template
- Owner: InformaticsMatters
- License: mit
- Created: 2021-01-20T11:56:27.000Z (over 5 years ago)
- Default Branch: main
- Last Pushed: 2025-11-26T12:40:18.000Z (7 months ago)
- Last Synced: 2025-11-29T03:25:31.477Z (7 months ago)
- Language: Shell
- Size: 60.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# format-support-template
[](https://github.com/InformaticsMatters/format-support-template/actions/workflows/build.yaml)
[](https://github.com/InformaticsMatters/format-support-template/actions/workflows/publish-latest.yaml)
[](https://github.com/InformaticsMatters/format-support-template/actions/workflows/publish-tag.yaml)
[](https://github.com/InformaticsMatters/format-support-template/actions/workflows/publish-stable.yaml)

---
> Replace the following template text with your own documentation
A template repository for **Informatics Matters DataTier dataset
format-support container image implementations**.
Use this repository to start development of a container image that can be
used by the DataTier Manager to support the loading of a dataset _type_.
You are required to preserve and adhere to the design rules
that can be found in this repository's `RULES.md`.
Please take time to familiarise yourself with following sections before
discarding this text. Failing to comply with what's discussed here
may result in the image not passing any future automated acceptance testing
that may be deployed.
- Building
- Testing
- Required image tags
- Built-in GitHub Actions
- Updating the badge links
## Building
You should be able to build your format-support image using `docker`: -
$ docker build . -t ${PWD##*/}:latest
Or `docker-compose`: -
$ IMAGE_NAME=${PWD##*/} docker-compose build
> The expectation is that you're using a recent Docker engine
(like `20.10.2`) and docker-compose utility (like `1.27.4`).
## Testing
Familiarise yourself with `TESTING.md`, which describes
a strategy you can replicate while developing and testing your image.
## Required image tags
The DataTier Manager will only execute formatter images tagged `:stable`
so you **MUST** ultimately produce an image with this tag. You are also
encouraged to produce a `:latest` tag and any specific tags that satisfy your
own needs (with formats like `1.0.0-rc.1`, `1.0.0` and `2021.1`).
> This repository's built-in GitHub Actions (see the next section)
will do all this for you.
## Built-in GitHub Actions
The template contains a number of [GitHub Actions] that will automatically
build the container image and also publish `:latest` and any tags you make to
Docker Hub.
This relies on your docker registry mirroring your repository. If your docker
repository name does not mirror your GitHub repository name then you will need
to adjust these actions. For example, if you create a GitHub repository
from this one and call it 'XYZ/my-support-template' then you must be able to
push docker images to 'xyz/my-support-template:latest'. If not, you will need
to edit the workflow files to satisfy your needs.
> Your images must be published to Docker Hub.
The following built-in actions are: -
1. **For every commit to main** an Action builds the docker image and
pushes it using the image tag `:latest`.
This is accomplished by the `publish-latest.yaml` Action.
2. **For every repository tag** an Action builds the docker image and
pushes it with the image tag `:`
This is accomplished by the `publish-tag.yaml` Action.
- If the tag looks like a _formal_ release, i.e. is a 2 or 3-digit number
like `2021.1` or `1.0.0` an Action builds the docker image and
pushes it using the image tag `:` and the tag `:stable`
This is accomplished by the `publish-stable.yaml` Action.
3. **For every commit on a branch**, or a pull request to main, an Action
runs that just builds the docker image - but does not push it.
This is accomplished by the `build.yaml` Action.
In order for the above Actions to succeed you will need to define the following
GitHub Repository (or Organisation) **secrets**: -
- `DOCKERHUB_USERNAME` A Docker Hub user
- `DOCKERHUB_TOKEN` A Docker Hub user password or, ideally, access token
> Repositories created in the InformaticsMatters organisation
are already presented with these secrets as they are already
defined at the Organisation level.
## Updating the badge links
Don't forget to replace the `InformaticsMatters/format-support-template`
values in the above badge links with the name of your own repository, otherwise
your badges will reflect the template repository's state, not yours.
---
[github actions]: https://github.com/features/actions