bump node to v16

This commit is contained in:
Aarni Halinen
2021-12-10 01:23:08 +02:00
parent f9e855fd23
commit 0a3e006c0f
5 changed files with 13 additions and 13 deletions
+7 -7
View File
@@ -8,7 +8,7 @@ stages:
- deploy
install:
image: node:14
image: node:16
stage: setup
script:
- npm ci
@@ -21,34 +21,34 @@ install:
expire_in: 1 week
audit:
image: node:14
image: node:16
needs: ["install"]
stage: audit
script:
- npm audit --audit-level=critical
es:lint:
image: node:14
image: node:16
needs: ["install"]
stage: lint
script:
- npm run lint:es
css:lint:
image: node:14
image: node:16
needs: ["install"]
stage: lint
script:
- npm run lint:css
# test:unit:
# image: node:14
# image: node:16
# stage: test
# script:
# - npm run test:unit
build:
image: node:14
image: node:16
needs: ["install"]
stage: build
script:
@@ -66,7 +66,7 @@ build:
- .next/cache/
test:e2e:
image: circleci/node:14-browsers
image: circleci/node:16-browsers
needs: ["install", "build"]
stage: test
script:
+1 -1
View File
@@ -1 +1 @@
14
16
+3 -3
View File
@@ -1,5 +1,5 @@
# Install dependencies only when needed
FROM node:14-alpine AS deps
FROM node:16-alpine AS deps
# Check https://github.com/nodejs/docker-node/tree/b4117f9333da4138b03a546ec926ef50a31506c3#nodealpine to understand why libc6-compat might be needed.
RUN apk add --no-cache libc6-compat
WORKDIR /app
@@ -7,7 +7,7 @@ COPY package.json package-lock.json ./
RUN npm ci
# Rebuild the source code only when needed
FROM node:14-alpine AS builder
FROM node:16-alpine AS builder
WORKDIR /app
COPY . .
COPY --from=deps /app/node_modules ./node_modules
@@ -21,7 +21,7 @@ ARG SENTRY_AUTH_TOKEN
RUN npm run build
# Production image, copy all the files and run next
FROM node:14-alpine AS runner
FROM node:16-alpine AS runner
WORKDIR /app
ENV NODE_ENV production
+1 -1
View File
@@ -10,7 +10,7 @@ This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next
## Installation
1. Clone/download repo
2. Install node v14 ([`nvm`](https://github.com/nvm-sh/nvm))
2. Install node v16 ([`nvm`](https://github.com/nvm-sh/nvm))
3. `npm install`
## Getting Started
+1 -1
View File
@@ -12,7 +12,7 @@ export async function generateToken(username: string, password: string): Promise
return resp.data.token;
}
export function setTokenCookie(token: string) {
export function setTokenCookie(token: string): void {
Cookies.set("jwt", token);
Cookies.set("jwt", token, { domain: ".sahkoinsinoorikilta.fi" });
}