Builds and publishes a Docker image to opengovsg/formsg-intl
This repository consists of the following meaningful parts:
A minimal set of source files used to replace parts of the FormSG codebase, hiding or removing features specific to Singapore
A variation of the original Dockerfile
in the FormSG codebase used
to build production images. This variation deliberately installs
MockPass to add placeholder
certificates. These certificates are usually used by FormSG to interact
with Singpass and Corppass, and are hence required at runtime.
A GitHub Actions workflow to:
- copy the original FormSG codebase
- replace some of the source code using the files in
replacements/
- build a Docker image using
Dockerfile
, pushing the result to Docker Hub
- Fork the original codebase at opengovsg/FormSG
- Clone the resulting repository onto your local machine
- While in the directory containing your repository, clone the formsg-intl repository
into a subdirectory called
formsg-intl
git clone --depth 1 [email protected]:opengovsg/formsg-intl
- Replace
Dockerfile
, and remove Singapore-specific features by replacing corresponding files with equivalents using the following command:
cp -rf formsg-intl/replacements/* .
cp -f formsg-intl/Dockerfile .
- Once replacements are complete, remove the
formsg-intl/
directory with the command:
rm -rf formsg-intl
You now have a codebase of FormSG that has most of the Singapore-specific features hidden. note that the code implementing these features may still be present, so you are free to remove them, or study them to understand how you might build equivalent features in your local context.