Skip to content

Commit

Permalink
Merge pull request #478 from kool-dev/updating-versions
Browse files Browse the repository at this point in the history
Updating Node and Redis latest versions
  • Loading branch information
fabriciojs authored Oct 25, 2023
2 parents 4cab40b + 45b6995 commit d165238
Show file tree
Hide file tree
Showing 37 changed files with 58 additions and 58 deletions.
4 changes: 2 additions & 2 deletions docs/1-Getting-Started/3-How-it-works.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,8 @@ scripts:
artisan: kool exec app php artisan
composer: kool exec app composer
mysql: kool exec -e MYSQL_PWD=$DB_PASSWORD database mysql -uroot
node: kool docker kooldev/node:16 node
npm: kool docker kooldev/node:16 npm # or yarn
node: kool docker kooldev/node:20 node
npm: kool docker kooldev/node:20 npm # or yarn
npx: kool exec app npx

setup:
Expand Down
4 changes: 2 additions & 2 deletions docs/1-Getting-Started/4-Starting-new-project.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,8 +157,8 @@ Here's a **kool.yml** example to show you the types of commands you can add and
```yaml
scripts:
composer: kool exec app composer2
node: kool docker kooldev/node:16 node
yarn: kool docker kooldev/node:16 yarn
node: kool docker kooldev/node:20 node
yarn: kool docker kooldev/node:20 yarn

setup:
- kool docker kooldev/bash -c "cp .env.example .env"
Expand Down
2 changes: 1 addition & 1 deletion docs/2-Presets/AdonisJs.md
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ scripts:
npx: kool exec app npx

setup:
- kool docker kooldev/node:16 npm install # or yarn install
- kool docker kooldev/node:20 npm install # or yarn install
- kool start
```
Expand Down
2 changes: 1 addition & 1 deletion docs/2-Presets/ExpressJS.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ scripts:
npx: kool exec app npx

setup:
- kool docker kooldev/node:16 npm install
- kool docker kooldev/node:20 npm install
- kool start
# - add more setup commands
```
Expand Down
4 changes: 2 additions & 2 deletions docs/2-Presets/Laravel.md
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,8 @@ scripts:
artisan: kool exec app php artisan
composer: kool exec app composer
mysql: kool exec -e MYSQL_PWD=$DB_PASSWORD database mysql -uroot
node: kool docker kooldev/node:16 node
npm: kool docker kooldev/node:16 npm # or yarn
node: kool docker kooldev/node:20 node
npm: kool docker kooldev/node:20 npm # or yarn
npx: kool exec app npx

setup:
Expand Down
2 changes: 1 addition & 1 deletion docs/2-Presets/NestJS.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ scripts:
# copy .env file
- cp .env.dist .env
# install backend deps
- kool docker kooldev/node:16 npm install
- kool docker kooldev/node:20 npm install

# helpers
npm: kool exec app npm
Expand Down
4 changes: 2 additions & 2 deletions docs/2-Presets/NextJS.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Use the [`kool create PRESET FOLDER` command](/docs/commands/kool-create) to cre
$ kool create nextjs my-project
```

Under the hood, this command will run `yarn create next-app my-project` to install Next.js using a customized **kool** Docker image: <a href="https://github.com/kool-dev/docker-node" target="_blank">kooldev/node:16</a>.
Under the hood, this command will run `yarn create next-app my-project` to install Next.js using a customized **kool** Docker image: <a href="https://github.com/kool-dev/docker-node" target="_blank">kooldev/node:20</a>.

After installing Next.js, `kool create` automatically runs the `kool preset nextjs` command, which helps you easily set up the initial tech stack for your project using an interactive wizard.

Expand Down Expand Up @@ -68,7 +68,7 @@ scripts:
npx: kool exec app npx

setup:
- kool docker kooldev/node:16 npm install # or yarn install
- kool docker kooldev/node:20 npm install # or yarn install
- kool start
```
Expand Down
4 changes: 2 additions & 2 deletions docs/2-Presets/NuxtJS.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Use the [`kool create PRESET FOLDER` command](/docs/commands/kool-create) to cre
$ kool create nuxtjs my-project
```

Under the hood, this command will run `yarn create nuxt-app my-project` to install NuxtJS using a customized **kool** Docker image: <a href="https://github.com/kool-dev/docker-node" target="_blank">kooldev/node:16</a>.
Under the hood, this command will run `yarn create nuxt-app my-project` to install NuxtJS using a customized **kool** Docker image: <a href="https://github.com/kool-dev/docker-node" target="_blank">kooldev/node:20</a>.

After installing NuxtJS, `kool create` automatically runs the `kool preset nuxtjs` command, which helps you easily set up the initial tech stack for your project using an interactive wizard.

Expand Down Expand Up @@ -87,7 +87,7 @@ scripts:
npx: kool exec app npx

setup:
- kool docker kooldev/node:16 npm install # or yarn install
- kool docker kooldev/node:20 npm install # or yarn install
- kool start
```
Expand Down
4 changes: 2 additions & 2 deletions docs/6-Troubleshooting/hmr-eer-empty-response.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ For the sake of clarity, let's elect port `8080` to publish.
In your `kool.yml`, apply the following changes:

```diff
-npm: kool docker kooldev/node:16 npm
+npm: kool docker -p 8080:8080 kooldev/node:16 npm
-npm: kool docker kooldev/node:20 npm
+npm: kool docker -p 8080:8080 kooldev/node:20 npm
```

- Alternatively, if you don't want to publish the port for your general `kool run npm` commands, you may add a new entry.
Expand Down
2 changes: 1 addition & 1 deletion presets/expressjs/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: "3.7"
services:
app:
image: kooldev/node:16
image: kooldev/node:20
command: ["node", "app.js"]
ports:
- "${KOOL_APP_PORT:-3000}:3000"
Expand Down
8 changes: 4 additions & 4 deletions presets/nest+next/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ create:
- name: Creating new NestJS Application
actions:
- scripts:
- docker pull -q kooldev/node:16
- docker pull -q kooldev/node:20
- mkdir $CREATE_DIRECTORY
- kool docker kooldev/node:16 npx -y @nestjs/cli new -l Typescript -p npm --skip-git $CREATE_DIRECTORY/backend
- kool docker kooldev/node:16 npx -y create-next-app@latest --ts --use-npm $CREATE_DIRECTORY/frontend
- kool docker kooldev/node:20 npx -y @nestjs/cli new -l Typescript -p npm --skip-git $CREATE_DIRECTORY/backend
- kool docker kooldev/node:20 npx -y create-next-app@latest --ts --use-npm $CREATE_DIRECTORY/frontend

preset:
- name: 'Copy basic config files'
Expand All @@ -28,4 +28,4 @@ preset:
- copy: gitignore
dst: .gitignore
- scripts:
- kool docker kooldev/node:16 sed -i 's/app.listen(3000)/app.listen(process.env.KOOL_BACKEND_PORT)/' backend/src/main.ts
- kool docker kooldev/node:20 sed -i 's/app.listen(3000)/app.listen(process.env.KOOL_BACKEND_PORT)/' backend/src/main.ts
4 changes: 2 additions & 2 deletions presets/nest+next/nest+next-docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
services:
frontend:
image: kooldev/node:16
image: kooldev/node:20
command: ["npm", "run", "dev", "--", "-p", "${KOOL_FRONTEND_PORT:-80}"]
ports:
- "${KOOL_FRONTEND_PORT:-80}:${KOOL_FRONTEND_PORT:-80}"
Expand All @@ -15,7 +15,7 @@ services:
- kool_local
- kool_global
backend:
image: kooldev/node:16
image: kooldev/node:20
command: ["npm", "run", "start:dev"]
ports:
- "${KOOL_BACKEND_PORT:-81}:${KOOL_BACKEND_PORT:-81}"
Expand Down
4 changes: 2 additions & 2 deletions presets/nest+next/nest+next-kool.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ scripts:
- cp .env.dist backend/.env
- ln -s backend/.env .env
# install backend deps
- kool docker kooldev/node:16 npm --prefix ./backend install
- kool docker kooldev/node:20 npm --prefix ./backend install
# install frontend deps
- kool docker kooldev/node:16 npm --prefix ./frontend install
- kool docker kooldev/node:20 npm --prefix ./frontend install

# backend helpers
backend:npm: kool exec backend npm
Expand Down
4 changes: 2 additions & 2 deletions presets/nestjs/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ create:
- name: Creating new NestJS Application
actions:
- scripts:
- docker pull -q kooldev/node:16
- kool docker kooldev/node:16 npx -y @nestjs/cli new -l Typescript -p npm $CREATE_DIRECTORY
- docker pull -q kooldev/node:20
- kool docker kooldev/node:20 npx -y @nestjs/cli new -l Typescript -p npm $CREATE_DIRECTORY

# Preset defines the workflow for installing this preset in the current working directory
preset:
Expand Down
2 changes: 1 addition & 1 deletion presets/nestjs/docker-compose.nestjs.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
services:
app:
image: kooldev/node:16
image: kooldev/node:20
command: ["npm", "run", "start:dev"]
ports:
- "${KOOL_APP_PORT:-3000}:${KOOL_APP_PORT:-3000}"
Expand Down
2 changes: 1 addition & 1 deletion presets/nestjs/kool.nestjs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ scripts:
# copy .env file
- cp .env.dist .env
# install backend deps
- kool docker kooldev/node:16 npm install
- kool docker kooldev/node:20 npm install

# helpers
npm: kool exec app npm
Expand Down
4 changes: 2 additions & 2 deletions presets/nextjs/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ create:
- name: Creating new NextJS Application
actions:
- scripts:
- docker pull -q kooldev/node:16
- kool docker kooldev/node:16 yarn create next-app $CREATE_DIRECTORY
- docker pull -q kooldev/node:20
- kool docker kooldev/node:20 yarn create next-app $CREATE_DIRECTORY

# Preset defines the workflow for installing this preset in the current working directory
preset:
Expand Down
2 changes: 1 addition & 1 deletion presets/nextjs/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: "3.7"
services:
app:
image: kooldev/node:16
image: kooldev/node:20
command: ["npm", "run", "dev"]
ports:
- "${KOOL_APP_PORT:-3000}:3000"
Expand Down
2 changes: 1 addition & 1 deletion presets/nodejs/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: "3.7"
services:
app:
image: kooldev/node:16
image: kooldev/node:20
command: ["node", "app.js"]
ports:
- "${KOOL_APP_PORT:-3000}:3000"
Expand Down
4 changes: 2 additions & 2 deletions presets/nuxtjs/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ create:
- name: Creating new Nuxt Application
actions:
- scripts:
- docker pull -q kooldev/node:16
- kool docker kooldev/node:16 yarn create nuxt-app $CREATE_DIRECTORY
- docker pull -q kooldev/node:20
- kool docker kooldev/node:20 yarn create nuxt-app $CREATE_DIRECTORY

# Preset defines the workflow for installing this preset in the current working directory
preset:
Expand Down
2 changes: 1 addition & 1 deletion presets/nuxtjs/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
version: "3.7"
services:
app:
image: kooldev/node:16
image: kooldev/node:20
command: ["npm", "run", "dev"]
ports:
- "${KOOL_APP_PORT:-3000}:3000"
Expand Down
6 changes: 3 additions & 3 deletions recipes/pick-cache.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ title: "Wizard: cache service"
actions:
# Defines which cache service to use (in-memory key/value storage)
- prompt: 'Which cache service do you want to use'
default: 'Redis 6.0'
default: 'Redis 7.0'
options:
- name: 'Redis 6.0'
- name: 'Redis 7.0'
actions:
- recipe: redis-6
- recipe: redis-7
- name: 'Memcached 1.6'
actions:
- recipe: memcached-1.6
Expand Down
5 changes: 0 additions & 5 deletions recipes/redis-6.yml

This file was deleted.

5 changes: 5 additions & 0 deletions recipes/redis-7.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
title: "Redis 7"

actions:
- merge: cache/redis7.yml
dst: docker-compose.yml
2 changes: 1 addition & 1 deletion templates/cache/redis6.yml → templates/cache/redis7.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
services:
cache:
image: redis:6-alpine
image: redis:7-alpine
volumes:
- cache:/data:delegated
networks:
Expand Down
2 changes: 1 addition & 1 deletion templates/misc/npm-vitejs.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
services:
node:
image: kooldev/node:16
image: kooldev/node:20
command: ["npm", "run", "dev"]
ports:
- "3001:3001"
Expand Down
2 changes: 1 addition & 1 deletion templates/misc/yarn-vitejs.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
services:
node:
image: kooldev/node:16
image: kooldev/node:20
command: ["yarn", "dev"]
ports:
- "3001:3001"
Expand Down
2 changes: 1 addition & 1 deletion templates/scripts/npm-expressjs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ scripts:
npx: kool exec app npx

setup:
- kool docker kooldev/node:16 npm install
- kool docker kooldev/node:20 npm install
- kool start
4 changes: 2 additions & 2 deletions templates/scripts/npm-laravel.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
scripts:
# npm - helpers for JS handling
npm: kool docker kooldev/node:16 npm
npx: kool docker kooldev/node:16 npx
npm: kool docker kooldev/node:20 npm
npx: kool docker kooldev/node:20 npx
before-start:
- kool run npm install
reset:
Expand Down
2 changes: 1 addition & 1 deletion templates/scripts/npm-nextjs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ scripts:
npx: kool exec app npx

setup:
- kool docker kooldev/node:16 npm install
- kool docker kooldev/node:20 npm install
- kool start
2 changes: 1 addition & 1 deletion templates/scripts/npm-nuxtjs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ scripts:
npx: kool exec app npx

setup:
- kool docker kooldev/node:16 npm install
- kool docker kooldev/node:20 npm install
- kool start
4 changes: 2 additions & 2 deletions templates/scripts/npm.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
scripts:
# npm - helpers for JS handling
npm: kool docker kooldev/node:16 npm
npx: kool docker kooldev/node:16 npx
npm: kool docker kooldev/node:20 npm
npx: kool docker kooldev/node:20 npx
setup:
- kool run npm install
reset:
Expand Down
2 changes: 1 addition & 1 deletion templates/scripts/yarn-expressjs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ scripts:
yarn: kool exec app yarn

setup:
- kool docker kooldev/node:16 yarn install
- kool docker kooldev/node:20 yarn install
- kool start
2 changes: 1 addition & 1 deletion templates/scripts/yarn-laravel.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
scripts:
# yarn - helpers for JS handling
yarn: kool docker kooldev/node:16 yarn
yarn: kool docker kooldev/node:20 yarn
before-start:
- kool run yarn install
reset:
Expand Down
2 changes: 1 addition & 1 deletion templates/scripts/yarn-nextjs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ scripts:
yarn: kool exec app yarn

setup:
- kool docker kooldev/node:16 yarn install
- kool docker kooldev/node:20 yarn install
- kool start
2 changes: 1 addition & 1 deletion templates/scripts/yarn-nuxtjs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ scripts:
yarn: kool exec app yarn

setup:
- kool docker kooldev/node:16 yarn install
- kool docker kooldev/node:20 yarn install
- kool start
2 changes: 1 addition & 1 deletion templates/scripts/yarn.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
scripts:
# yarn - helpers for JS handling
yarn: kool docker kooldev/node:16 yarn
yarn: kool docker kooldev/node:20 yarn
setup:
- kool run yarn install
reset:
Expand Down

0 comments on commit d165238

Please sign in to comment.