Compare commits
37 Commits
b2b359b63b
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
fa9bec5af4
|
|||
|
4521bed92d
|
|||
|
9118543a9c
|
|||
|
68f89a42a8
|
|||
|
8443f3a779
|
|||
|
c21a9a84d9
|
|||
|
77f01ae00f
|
|||
|
272046fb56
|
|||
|
587c95e246
|
|||
|
6d84a83350
|
|||
|
46bb646903
|
|||
|
86135fbcba
|
|||
|
8e900dc8c8
|
|||
|
ed50b3d219
|
|||
|
bc79a96076
|
|||
|
8c7b00f746
|
|||
|
bd7ebc9c1b
|
|||
|
120738412f
|
|||
|
a231ada791
|
|||
|
97bc55e0af
|
|||
|
e55dce9e43
|
|||
|
4232e490b7
|
|||
|
|
1aa40a6d75 | ||
|
939c70e7df
|
|||
|
d4656630db
|
|||
|
|
c58626d017 | ||
|
|
a3144ab5b7 | ||
|
|
dbcd25c55e | ||
|
|
31484e82ab | ||
|
|
8e29d340c7 | ||
|
|
10986cac4b | ||
|
|
6008b44edb | ||
|
|
e93c62f308 | ||
|
|
8518e07b8f | ||
|
|
ab5c008846 | ||
|
|
4de38b0b08 | ||
|
453e318817
|
6
.github/workflows/codacy.yml
vendored
6
.github/workflows/codacy.yml
vendored
@@ -35,11 +35,11 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
# Checkout the repository to the GitHub Actions runner
|
# Checkout the repository to the GitHub Actions runner
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
# Execute Codacy Analysis CLI and generate a SARIF output with the security issues identified during the analysis
|
# Execute Codacy Analysis CLI and generate a SARIF output with the security issues identified during the analysis
|
||||||
- name: Run Codacy Analysis CLI
|
- name: Run Codacy Analysis CLI
|
||||||
uses: codacy/codacy-analysis-cli-action@d840f886c4bd4edc059706d09c6a1586111c540b
|
uses: codacy/codacy-analysis-cli-action@db33ad5cfab49143adf0db6e890cf4bb9fb37b1c
|
||||||
with:
|
with:
|
||||||
# Check https://github.com/codacy/codacy-analysis-cli#project-token to get your project token from your Codacy repository
|
# Check https://github.com/codacy/codacy-analysis-cli#project-token to get your project token from your Codacy repository
|
||||||
# You can also omit the token and run the tools that support default configurations
|
# You can also omit the token and run the tools that support default configurations
|
||||||
@@ -55,6 +55,6 @@ jobs:
|
|||||||
|
|
||||||
# Upload the SARIF file generated in the previous step
|
# Upload the SARIF file generated in the previous step
|
||||||
- name: Upload SARIF results file
|
- name: Upload SARIF results file
|
||||||
uses: github/codeql-action/upload-sarif@v1
|
uses: github/codeql-action/upload-sarif@v2
|
||||||
with:
|
with:
|
||||||
sarif_file: results.sarif
|
sarif_file: results.sarif
|
||||||
|
|||||||
6
.github/workflows/snyk-container.yml
vendored
6
.github/workflows/snyk-container.yml
vendored
@@ -26,14 +26,14 @@ jobs:
|
|||||||
snyk:
|
snyk:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v3
|
||||||
- name: Build a Docker image
|
- name: Build a Docker image
|
||||||
run: docker build -t your/image-to-test .
|
run: docker build -t your/image-to-test .
|
||||||
- name: Run Snyk to check Docker image for vulnerabilities
|
- name: Run Snyk to check Docker image for vulnerabilities
|
||||||
# Snyk can be used to break the build when it detects vulnerabilities.
|
# Snyk can be used to break the build when it detects vulnerabilities.
|
||||||
# In this case we want to upload the issues to GitHub Code Scanning
|
# In this case we want to upload the issues to GitHub Code Scanning
|
||||||
continue-on-error: true
|
continue-on-error: true
|
||||||
uses: snyk/actions/docker@14818c4695ecc4045f33c9cee9e795a788711ca4
|
uses: snyk/actions/docker@806182742461562b67788a64410098c9d9b96adb
|
||||||
env:
|
env:
|
||||||
# In order to use the Snyk Action you will need to have a Snyk API token.
|
# In order to use the Snyk Action you will need to have a Snyk API token.
|
||||||
# More details in https://github.com/snyk/actions#getting-your-snyk-token
|
# More details in https://github.com/snyk/actions#getting-your-snyk-token
|
||||||
@@ -43,6 +43,6 @@ jobs:
|
|||||||
image: your/image-to-test
|
image: your/image-to-test
|
||||||
args: --file=Dockerfile
|
args: --file=Dockerfile
|
||||||
- name: Upload result to GitHub Code Scanning
|
- name: Upload result to GitHub Code Scanning
|
||||||
uses: github/codeql-action/upload-sarif@v1
|
uses: github/codeql-action/upload-sarif@v2
|
||||||
with:
|
with:
|
||||||
sarif_file: snyk.sarif
|
sarif_file: snyk.sarif
|
||||||
|
|||||||
11
Dockerfile
11
Dockerfile
@@ -2,20 +2,13 @@ FROM cubetiq/calpine-node:slim
|
|||||||
LABEL maintainer="sombochea@cubetiqs.com"
|
LABEL maintainer="sombochea@cubetiqs.com"
|
||||||
|
|
||||||
# Install PNPM
|
# Install PNPM
|
||||||
ARG PNPM_VERSION=7.28.0
|
RUN npm install -g pnpm@latest
|
||||||
ENV PNPM_HOME=/root/.local/share/pnpm
|
|
||||||
ENV PATH=$PATH:$PNPM_HOME
|
|
||||||
|
|
||||||
RUN echo "Installing PNPM version: $PNPM_VERSION" && \
|
|
||||||
apk add --no-cache curl && \
|
|
||||||
curl -fsSL "https://github.com/pnpm/pnpm/releases/download/v${PNPM_VERSION}/pnpm-linuxstatic-x64" -o /bin/pnpm && chmod +x /bin/pnpm && \
|
|
||||||
apk del curl
|
|
||||||
|
|
||||||
# Update NPM package
|
# Update NPM package
|
||||||
RUN npm install -g npm@latest
|
RUN npm install -g npm@latest
|
||||||
|
|
||||||
# Install yarn from npm package
|
# Install yarn from npm package
|
||||||
RUN npm -g i yarn@latest
|
RUN npm install -g yarn@latest --force
|
||||||
|
|
||||||
# Checking packages version
|
# Checking packages version
|
||||||
RUN echo "NODE: $(node --version)" \
|
RUN echo "NODE: $(node --version)" \
|
||||||
|
|||||||
@@ -1,82 +1,6 @@
|
|||||||
FROM cubetiq/calpine-os-linux:latest
|
FROM node:18-alpine
|
||||||
LABEL maintainer="sombochea@cubetiqs.com"
|
LABEL maintainer="sombochea@cubetiqs.com"
|
||||||
|
|
||||||
# Build with root access
|
|
||||||
USER root
|
|
||||||
|
|
||||||
ENV NODE_VERSION 16.19.0
|
|
||||||
ENV NODE_SHA256 f5817883eb3009972a031d635ea71ed8377808a6e831ae1c72e063e888cdd318
|
|
||||||
ENV USER_UID 1001
|
|
||||||
|
|
||||||
RUN addgroup -g ${USER_UID} node \
|
|
||||||
&& adduser -u ${USER_UID} -G node -s /bin/sh -D node \
|
|
||||||
&& apk add --no-cache \
|
|
||||||
libstdc++ \
|
|
||||||
&& apk add --no-cache --virtual .build-deps \
|
|
||||||
curl \
|
|
||||||
&& ARCH= && alpineArch="$(apk --print-arch)" \
|
|
||||||
&& case "${alpineArch##*-}" in \
|
|
||||||
x86_64) \
|
|
||||||
ARCH='x64' \
|
|
||||||
CHECKSUM=$NODE_SHA256 \
|
|
||||||
;; \
|
|
||||||
*) ;; \
|
|
||||||
esac \
|
|
||||||
&& if [ -n "${CHECKSUM}" ]; then \
|
|
||||||
set -eu; \
|
|
||||||
DL_ROOT="https://unofficial-builds.nodejs.org/download/release/v$NODE_VERSION/node-v$NODE_VERSION-linux-$ARCH-musl.tar.xz"; \
|
|
||||||
echo "Downloading Node.js from ${DL_ROOT}"; \
|
|
||||||
curl -fsSLO --compressed $DL_ROOT; \
|
|
||||||
echo "$CHECKSUM node-v$NODE_VERSION-linux-$ARCH-musl.tar.xz" | sha256sum -c - \
|
|
||||||
&& tar -xJf "node-v$NODE_VERSION-linux-$ARCH-musl.tar.xz" -C /usr/local --strip-components=1 --no-same-owner \
|
|
||||||
&& ln -s /usr/local/bin/node /usr/local/bin/nodejs; \
|
|
||||||
else \
|
|
||||||
echo "Building from source" \
|
|
||||||
# backup build
|
|
||||||
&& apk add --no-cache --virtual .build-deps-full \
|
|
||||||
binutils-gold \
|
|
||||||
g++ \
|
|
||||||
gcc \
|
|
||||||
gnupg \
|
|
||||||
libgcc \
|
|
||||||
linux-headers \
|
|
||||||
make \
|
|
||||||
python3 \
|
|
||||||
# gpg keys listed at https://github.com/nodejs/node#release-keys
|
|
||||||
&& for key in \
|
|
||||||
4ED778F539E3634C779C87C6D7062848A1AB005C \
|
|
||||||
94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \
|
|
||||||
74F12602B6F1C4E913FAA37AD3A89613643B6201 \
|
|
||||||
71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \
|
|
||||||
8FCCA13FEF1D0C2E91008E09770F7A9A5AE15600 \
|
|
||||||
C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \
|
|
||||||
C82FA3AE1CBEDC6BE46B9360C43CEC45C17AB93C \
|
|
||||||
DD8F2338BAE7501E3DD5AC78C273792F7D83545D \
|
|
||||||
A48C2BEE680E841632CD4E44F07496B3EB3C1762 \
|
|
||||||
108F52B48DB57BB0CC439B2997B01419BD92F80A \
|
|
||||||
B9E2F5981AA6E0CD28160D9FF13993A75599653C \
|
|
||||||
; do \
|
|
||||||
gpg --batch --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys "$key" || \
|
|
||||||
gpg --batch --keyserver hkp://ipv4.pool.sks-keyservers.net --recv-keys "$key" || \
|
|
||||||
gpg --batch --keyserver hkp://pgp.mit.edu:80 --recv-keys "$key" ; \
|
|
||||||
done \
|
|
||||||
&& curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION.tar.xz" \
|
|
||||||
&& curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \
|
|
||||||
&& gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \
|
|
||||||
&& grep " node-v$NODE_VERSION.tar.xz\$" SHASUMS256.txt | sha256sum -c - \
|
|
||||||
&& tar -xf "node-v$NODE_VERSION.tar.xz" \
|
|
||||||
&& cd "node-v$NODE_VERSION" \
|
|
||||||
&& ./configure \
|
|
||||||
&& make -j$(getconf _NPROCESSORS_ONLN) V= \
|
|
||||||
&& make install \
|
|
||||||
&& apk del .build-deps-full \
|
|
||||||
&& cd .. \
|
|
||||||
&& rm -Rf "node-v$NODE_VERSION" \
|
|
||||||
&& rm "node-v$NODE_VERSION.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt; \
|
|
||||||
fi \
|
|
||||||
&& rm -f "node-v$NODE_VERSION-linux-$ARCH-musl.tar.xz" \
|
|
||||||
&& apk del .build-deps
|
|
||||||
|
|
||||||
# Update NPM package
|
# Update NPM package
|
||||||
RUN npm install -g npm@latest
|
RUN npm install -g npm@latest
|
||||||
|
|
||||||
|
|||||||
2
Makefile
2
Makefile
@@ -1,6 +1,6 @@
|
|||||||
DOCKER_IMAGE=cubetiq/calpine-node
|
DOCKER_IMAGE=cubetiq/calpine-node
|
||||||
DOCKER_IMAGE_GIT=cubetiq/calpine-node-git
|
DOCKER_IMAGE_GIT=cubetiq/calpine-node-git
|
||||||
DOCKER_IMAGE_NAME=${DOCKER_IMAGE}:16
|
DOCKER_IMAGE_NAME=${DOCKER_IMAGE}:18
|
||||||
|
|
||||||
build:
|
build:
|
||||||
@echo 'Starting docker build with slim'
|
@echo 'Starting docker build with slim'
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
# CUBETIQ Alpine OS Linux with Nodejs 16
|
# CUBETIQ Alpine OS Linux with Nodejs 18
|
||||||
|
|
||||||

|

|
||||||

|

|
||||||
|
|
||||||
- CUBETIQ Alpine OS Linux (Latest)
|
- CUBETIQ Alpine OS Linux (Latest)
|
||||||
- Nodejs 16 (16.19.0)
|
- Nodejs 18
|
||||||
- PNPM 7 (7.28.0)
|
- PNPM 8 (8.7.5)
|
||||||
|
|
||||||
# [Docker Hub](https://hub.docker.com/r/cubetiq/calpine-node)
|
# [Docker Hub](https://hub.docker.com/r/cubetiq/calpine-node)
|
||||||
|
|
||||||
|
|||||||
6
renovate.json
Normal file
6
renovate.json
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
{
|
||||||
|
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
|
||||||
|
"extends": [
|
||||||
|
"config:base"
|
||||||
|
]
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user