Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
41 commits
Select commit Hold shift + click to select a range
c2aff06
Merge pull request #2241 from opengovsg/release-1.76.1
halfwhole Jul 13, 2023
90479be
Experiment go <> sgid integration (#2247)
PikkaPikkachu Aug 3, 2023
6b3e5df
1.77.0
PikkaPikkachu Aug 3, 2023
f53142d
Merge pull request #2250 from opengovsg/release-1.77
PikkaPikkachu Aug 4, 2023
801c4ae
fix: stored xss via file upload (#2258)
thamsimun Aug 22, 2023
feab32c
1.77.1
thamsimun Sep 7, 2023
931d9e3
Merge pull request #2267 from opengovsg/release-1.77.1
thamsimun Sep 7, 2023
c6321f2
build(deps): bump import-in-the-middle from 1.4.1 to 1.4.2 (#2259)
halfwhole Sep 21, 2023
ae740a3
[Snyk] Security upgrade sharp from 0.30.7 to 0.32.6 (#2277)
gweiying Oct 2, 2023
b3a5bee
1.77.2
PikkaPikkachu Oct 2, 2023
c1acc3c
Merge pull request #2279 from opengovsg/release-1.77.2
PikkaPikkachu Oct 2, 2023
a8ae407
feat: remove verify message button linking to checkwho (#2284)
halfwhole Oct 17, 2023
a8ff80c
1.78.0
thamsimun Dec 13, 2023
7247e31
Merge pull request #2287 from opengovsg/release-1.78
halfwhole Dec 29, 2023
3ef2dd0
build(deps): bump node from 16 to 18 (#2285)
halfwhole Feb 5, 2024
54cac98
chore: fix serverless plugin include dependencies to v5 (#2290)
halfwhole Feb 19, 2024
a71d1a9
build(deps): bump webpack-dev-server from 3 to 4 (#2291)
halfwhole Feb 19, 2024
33cceca
1.78.1
halfwhole Feb 19, 2024
c2fdac2
Merge pull request #2298 from opengovsg/release-1.78.1
gweiying Mar 18, 2024
f71e34b
Chore/fix user query (#2299)
gweiying Mar 18, 2024
efd86f6
1.78.2
gweiying Mar 18, 2024
822d2db
Merge pull request #2301 from opengovsg/release-1.78.2
gweiying Mar 20, 2024
7c8cea6
Chore/disable link stats (#2304)
gweiying Mar 21, 2024
1e1f53b
chore: replace safe browsing with web risk (#2305)
gweiying Mar 21, 2024
2ab4e4d
1.79.0
gweiying Mar 21, 2024
e0a8a5f
Merge pull request #2307 from opengovsg/release-1.79
gweiying Apr 1, 2024
02c9d3f
build: fix link to ibm plex sans font (#2341)
halfwhole Sep 5, 2024
01ce46b
chore: pipe test results to datadog (#2342)
halfwhole Oct 4, 2024
adc81ea
build(deps-dev): bump @babel/traverse from 7.14.8 to 7.24.7 (#2330)
dependabot[bot] Dec 23, 2024
d4bd2fc
fix: remove statistics repo (#2381)
seaerchin Jun 17, 2025
515f9f4
1.79.1
halfwhole Jun 17, 2025
166e32f
Merge pull request #2383 from opengovsg/release-1.79.1
halfwhole Jun 17, 2025
67fe64e
chore: fix formatting (#2384)
seaerchin Jun 26, 2025
37bd712
chore: fix codeql (#2385)
seaerchin Jun 27, 2025
4cf3e55
chore: correct capitalization of GoGovSG in README.md
adriangohjw Jul 9, 2025
b094514
Merge pull request #2390 from opengovsg/fix-product-naming-inconsiste…
adriangohjw Jul 9, 2025
705f15a
1.79.2
adriangohjw Jul 9, 2025
dda9fa6
Merge pull request #2392 from opengovsg/release-1.79.2
adriangohjw Jul 9, 2025
80942e7
chore: fix compoute issue from tags (#2396)
seaerchin Jul 15, 2025
40d6de2
chore: escape raw html (#2395)
seaerchin Jul 15, 2025
04305b7
1.80.0
dcshzj Jul 15, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 41 additions & 0 deletions .ebextensions/25-load-sgid-env.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# loads SGID environment variables to a .env file from SSM

commands:
01-create-env:
command: "/tmp/create-env.sh"

files:
"/tmp/create-env.sh":
mode: "000755"
content : |
#!/bin/bash
ENV_NAME=$(/opt/elasticbeanstalk/bin/get-config environment -k SSM_PREFIX)

ENV_VARS=("SGID_CLIENT_ID" "SGID_CLIENT_SECRET" "SGID_PRIVATE_KEY")

echo "Set AWS region"
aws configure set default.region ap-southeast-1

TARGET_DIR=/etc/gogovsg

echo "Checking if ${TARGET_DIR} exists..."
if [ ! -d ${TARGET_DIR} ]; then
echo "Creating directory ${TARGET_DIR} ..."
mkdir -p ${TARGET_DIR}
if [ $? -ne 0 ]; then
echo 'ERROR: Directory creation failed!'
exit 1
fi
else
echo "Directory ${TARGET_DIR} already exists!"
fi

echo "Creating config for ${ENV_NAME} in ${AWS_REGION}"

for ENV_VAR in "${ENV_VARS[@]}"; do
echo "Running for this ${ENV_NAME}"
echo "Fetching ${ENV_VAR} from SSM"
VALUE=$(aws ssm get-parameter --name "${ENV_NAME}_${ENV_VAR}" --with-decryption --query "Parameter.Value" --output text)
echo "${ENV_VAR}=${VALUE}" >> $TARGET_DIR/.env
echo "Saved ${ENV_VAR}"
done
69 changes: 46 additions & 23 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ jobs:
- name: Use Node.js
uses: actions/setup-node@v1
with:
node-version: '16.x'
node-version: '18.x'
- name: Cache Node.js modules
uses: actions/cache@v2
uses: actions/cache@v4
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
Expand All @@ -55,9 +55,9 @@ jobs:
- name: Use Node.js
uses: actions/setup-node@v1
with:
node-version: '16.x'
node-version: '18.x'
- name: Cache Node.js modules
uses: actions/cache@v2
uses: actions/cache@v4
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
Expand All @@ -66,11 +66,15 @@ jobs:
${{ runner.OS }}-node-
${{ runner.OS }}-
- run: npm ci --legacy-peer-deps
- run: npm run test
- name: Coveralls
uses: coverallsapp/github-action@master
- name: Configure Datadog Test Visibility
uses: datadog/test-visibility-github-action@v2
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
languages: js
service: gogovsg
api_key: ${{ secrets.DD_API_KEY }}
- run: npm run test
env:
NODE_OPTIONS: -r ${{ env.DD_TRACE_PACKAGE }}
testcafe:
name: End To End Tests
runs-on: ubuntu-22.04
Expand All @@ -79,9 +83,9 @@ jobs:
- name: Use Node.js
uses: actions/setup-node@v1
with:
node-version: '16.x'
node-version: '18.x'
- name: Cache Node.js modules
uses: actions/cache@v2
uses: actions/cache@v4
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
Expand All @@ -91,7 +95,15 @@ jobs:
${{ runner.OS }}-
- run: npm ci --legacy-peer-deps
- run: echo CLOUDMERSIVE_KEY=${{secrets.CLOUDMERSIVE_KEY}} >> .env
- name: Configure Datadog Test Visibility
uses: datadog/test-visibility-github-action@v2
with:
languages: js
service: gogovsg
api_key: ${{ secrets.DD_API_KEY }}
- run: npm run test:e2e-headless
env:
NODE_OPTIONS: -r ${{ env.DD_TRACE_PACKAGE }}
integration:
name: Integration Tests
runs-on: ubuntu-22.04
Expand All @@ -100,9 +112,9 @@ jobs:
- name: Use Node.js
uses: actions/setup-node@v1
with:
node-version: '16.x'
node-version: '18.x'
- name: Cache Node.js modules
uses: actions/cache@v2
uses: actions/cache@v4
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
Expand All @@ -113,7 +125,15 @@ jobs:
- run: npm ci --legacy-peer-deps
- run: npm run dev &
- run: sleep 270
- name: Configure Datadog Test Visibility
uses: datadog/test-visibility-github-action@v2
with:
languages: js
service: gogovsg
api_key: ${{ secrets.DD_API_KEY }}
- run: npm run test:integration
env:
NODE_OPTIONS: -r ${{ env.DD_TRACE_PACKAGE }}
gatekeep:
name: Determine if Build & Deploy is needed
outputs:
Expand Down Expand Up @@ -142,9 +162,9 @@ jobs:
- name: Use Node.js
uses: actions/setup-node@v1
with:
node-version: '16.x'
node-version: '18.x'
- name: Cache Node.js modules
uses: actions/cache@v2
uses: actions/cache@v4
with:
# npm cache files are stored in `~/.npm` on Linux/macOS
path: ~/.npm
Expand Down Expand Up @@ -229,10 +249,10 @@ jobs:
if: needs.gatekeep.outputs.proceed == 'true'
steps:
- uses: actions/checkout@v2
- name: Use Node.js 16.x
- name: Use Node.js
uses: actions/setup-node@v1
with:
node-version: '16.x'
node-version: '18.x'
- run: |
echo SERVERLESS_SERVICE=gogovsg >> $GITHUB_ENV;
if [[ $GITHUB_REF == $STAGING_BRANCH ]]; then
Expand Down Expand Up @@ -296,7 +316,8 @@ jobs:
- name: serverless deploy
uses: opengovsg/[email protected]
with:
args: -c "serverless plugin install --name serverless-plugin-include-dependencies && serverless deploy --stage=$BRANCH_ENV --conceal --verbose"
# serverless-plugin-include-dependencies v6 onwards requires node 18
args: -c "serverless plugin install --name [email protected] && serverless deploy --stage=$BRANCH_ENV --conceal --verbose"
entrypoint: /bin/bash
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
Expand Down Expand Up @@ -353,10 +374,10 @@ jobs:
if: needs.gatekeep.outputs.proceed == 'true'
steps:
- uses: actions/checkout@v2
- name: Use Node.js 16.x
- name: Use Node.js
uses: actions/setup-node@v1
with:
node-version: '16.x'
node-version: '18.x'
- run: |
echo SERVERLESS_SERVICE=edu >> $GITHUB_ENV;
if [[ $GITHUB_REF == $STAGING_BRANCH ]]; then
Expand Down Expand Up @@ -422,7 +443,8 @@ jobs:
- name: serverless deploy
uses: opengovsg/[email protected]
with:
args: -c "serverless plugin install --name serverless-plugin-include-dependencies && serverless deploy --stage=$BRANCH_ENV --conceal --verbose"
# serverless-plugin-include-dependencies v6 onwards requires node 18
args: -c "serverless plugin install --name [email protected] && serverless deploy --stage=$BRANCH_ENV --conceal --verbose"
entrypoint: /bin/bash
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
Expand Down Expand Up @@ -479,10 +501,10 @@ jobs:
if: needs.gatekeep.outputs.proceed == 'true'
steps:
- uses: actions/checkout@v2
- name: Use Node.js 16.x
- name: Use Node.js
uses: actions/setup-node@v1
with:
node-version: '16.x'
node-version: '18.x'
- run: |
echo SERVERLESS_SERVICE=health >> $GITHUB_ENV;
if [[ $GITHUB_REF == $STAGING_BRANCH ]]; then
Expand Down Expand Up @@ -548,7 +570,8 @@ jobs:
- name: serverless deploy
uses: opengovsg/[email protected]
with:
args: -c "serverless plugin install --name serverless-plugin-include-dependencies && serverless deploy --stage=$BRANCH_ENV --conceal --verbose"
# serverless-plugin-include-dependencies v6 onwards requires node 18
args: -c "serverless plugin install --name [email protected] && serverless deploy --stage=$BRANCH_ENV --conceal --verbose"
entrypoint: /bin/bash
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
Expand Down
85 changes: 35 additions & 50 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
name: "CodeQL"
name: 'CodeQL'

on:
push:
Expand All @@ -12,60 +12,45 @@ on:
# The branches below must be a subset of the branches above
branches: [develop]
schedule:
- cron: '0 21 * * 3'
- cron: '0 10 * * *'

jobs:
analyze:
name: Analyze
runs-on: ubuntu-22.04
name: Analyze (${{matrix.language}})
runs-on: ${{(matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest'}}
timeout-minutes: ${{(matrix.language == 'swift' && 120) || 360}}
permissions:
# Required for all workflows
security-events: write

# Required to fetch internal or private CodeQL packs
packages: read

# Only required for workflows in private repositories
actions: read
contents: read

strategy:
fail-fast: false
matrix:
# Override automatic language detection by changing the below list
# Supported options are ['csharp', 'cpp', 'go', 'java', 'javascript', 'python']
language: ['javascript']
# Learn more...
# https://docs.github.com/en/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#overriding-automatic-language-detection

include:
- language: javascript-typescript
build-mode: none
steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
# We must fetch at least the immediate parents so that if this is
# a pull request then we can checkout the head.
fetch-depth: 2

# If this run was triggered by a pull request event, then checkout
# the head of the pull request instead of the merge commit.
- run: git checkout HEAD^2
if: ${{ github.event_name == 'pull_request' }}

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
- name: Checkout repository
uses: actions/checkout@v4

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{matrix.language}}
build-mode: ${{matrix.build-mode}}

# Pull config from https://github.com/opengovsg/codeql-config/blob/prod/codeql-config.yml
config-file: opengovsg/codeql-config/codeql-config.yml@prod

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: '/language:${{matrix.language}}'
4 changes: 2 additions & 2 deletions .gitpod.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ RUN sudo apt-get update \
RUN sudo mkdir -p /docker-entrypoint-initaws.d
RUN sudo chown gitpod /docker-entrypoint-initaws.d

# Installs IBMPlexSans-Regular.ttf for QRCodeService.
RUN sudo wget https://github.com/IBM/plex/blob/master/IBM-Plex-Sans/fonts/complete/ttf/IBMPlexSans-Regular.ttf?raw=true -O /usr/share/fonts/truetype/IBMPlexSans-Regular.ttf
# Installs IBMPlexSans-Regular.otf for QRCodeService.
RUN sudo wget https://github.com/IBM/plex/blob/master/packages/plex-sans/fonts/complete/otf/IBMPlexSans-Regular.otf?raw=true -O /usr/share/fonts/truetype/IBMPlexSans-Regular.otf
RUN sudo fc-cache -f

USER gitpod
Expand Down
Loading
Loading