Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,12 @@ On a native Linux host, skip steps 1 and 2 and go straight to [Setup Packages](h
> Security is relaxed by default: the MariaDB root password is stored in plaintext in `config.yml`, and phpMyAdmin allows root login.
> Never expose it to a network.

## Updating

Already have an installation?
Run `git pull` in your clone and add any new aliases to `~/.bash_profile`.
See [Updating](https://docs.dotkernel.org/development/v2/updating/) for the steps and a list of changes.

## Virtualhosts

List the domains you want under the `virtualhosts` key in `wsl/config.yml`, then run:
Expand Down
2 changes: 2 additions & 0 deletions docs/book/v2/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,8 @@ The aliases are the following:
* `node20`: switch to Node.js 20
* `node18`: switch to Node.js 18

> If an alias is missing from an existing installation, see [Updating an existing installation](updating.md).

After switching to a different Node.js version, test with the following command:

```shell
Expand Down
81 changes: 81 additions & 0 deletions docs/book/v2/updating.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# Updating an existing installation

## Summary

Pull the latest changes of the `development` repository and apply any new shell aliases to your `~/.bash_profile`.
Aliases such as `node24` are written to `~/.bash_profile` only when the environment is first provisioned, so an existing installation does not receive them automatically.

## General procedure

Follow these steps whenever a new release of this repository introduces changes that affect an installation you have already provisioned.

Connect to your **AlmaLinux 10** distro, then go to the directory where you cloned the repository (by default `~/development`) and pull the latest changes:

```shell
cd ~/development
git pull
```

Open the template that defines the shell aliases and compare it with your own `~/.bash_profile`:

```shell
cat wsl/roles/system/templates/bash_profile.j2
```

Open `~/.bash_profile` in an editor and add any alias that is missing from it:

```shell
nano ~/.bash_profile
```

Save the file, then log out and log back in (or run `source ~/.bash_profile`) so that the new aliases are loaded.

> Only add what is new.
> Do not replace the whole file, as it may contain your own customizations.

## Changes

### Node.js 24 by default

Node.js 24 is now the default version, and the `node24` alias is available.
To upgrade an existing installation:

1. Go to your clone of the repository and pull the latest changes:

```shell
cd ~/development
git pull
```

2. Open `~/.bash_profile`:

```shell
nano ~/.bash_profile
```

3. Add the following line:

```shell
alias node24="sudo dnf remove nodejs -y && curl -fsSL https://rpm.nodesource.com/setup_24.x | sudo bash - && sudo dnf install nodejs -y"
```

4. Save the file, then log out and log back in.
5. Run the alias to switch to Node.js 24:

```shell
node24
```

6. Check the installed version:

```shell
node -v
```

The output should look similar to the below:

```terminaloutput
v24.13.0
```

For more on switching between Node.js versions, see the [FAQ](faq.md#how-do-i-switch-to-a-different-version-of-nodejs).
1 change: 1 addition & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ nav:
- Installation: v2/setup/installation.md
- Setup Packages: v2/setup/setup-packages.md
- Running on WSL 2: v2/running.md
- Updating: v2/updating.md
- Virtualhosts:
- Overview: v2/virtualhosts/overview.md
- Create virtualhost: v2/virtualhosts/create-virtualhost.md
Expand Down
Loading