Skip to content

Commit

Permalink
ci: Enable multi arch containers (#9)
Browse files Browse the repository at this point in the history
* Testing

* Test

* Downgrade npm

* --ignore-scripts

* Remove wasm

* Downgrade rollup

* Move files
  • Loading branch information
carlosthe19916 authored Mar 17, 2024
1 parent ba6c722 commit 801cfce
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 25 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/image-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,10 @@ jobs:
registry: "ghcr.io"
image_name: "${{ github.repository_owner }}/trustify-ui"
containerfile: "./Containerfile"
architectures: '[ "amd64" ]'
architectures: '[ "amd64", "arm64", "ppc64le", "s390x" ]'
extra-args: "--ulimit nofile=4096:4096"
pre_build_cmd: |
sed -i '/RUN npm clean-install/i RUN npm install -g npm@9' Containerfile
secrets:
registry_username: ${{ github.actor }}
registry_password: ${{ secrets.GITHUB_TOKEN }}
2 changes: 1 addition & 1 deletion Containerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM registry.access.redhat.com/ubi9/nodejs-20:latest as builder

USER 1001
COPY --chown=1001 . .
RUN npm clean-install && npm run build && npm run dist
RUN npm clean-install --ignore-scripts && npm run build && npm run dist

# Runner image
FROM registry.access.redhat.com/ubi9/nodejs-20-minimal:latest
Expand Down
53 changes: 32 additions & 21 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
],
"engines": {
"node": "^20",
"npm": ">=10.2.0"
"npm": ">=9.5.0"
},
"devDependencies": {
"@rollup/plugin-commonjs": "^25.0.7",
Expand All @@ -40,7 +40,6 @@
"@rollup/plugin-run": "^3.0.2",
"@rollup/plugin-typescript": "^11.1.6",
"@rollup/plugin-virtual": "^3.0.2",
"@rollup/wasm-node": "^4.12.0",
"@tanstack/eslint-plugin-query": "^4.34.1",
"@types/jest": "^29.5.4",
"@types/node": "^20.11.25",
Expand All @@ -61,6 +60,7 @@
"lint-staged": "^14.0.1",
"prettier": "^3.0.2",
"rimraf": "^4.4.1",
"rollup": "^3.29.4",
"rollup-plugin-copy": "^3.5.0",
"ts-jest": "^29.1.1",
"ts-node": "^10.9.1",
Expand Down

0 comments on commit 801cfce

Please sign in to comment.