Skip to content

Commit

Permalink
Mutagen v0.18.* check
Browse files Browse the repository at this point in the history
  • Loading branch information
alexanderM91 committed Nov 8, 2024
1 parent d6acb18 commit 3d5508f
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 1 deletion.
1 change: 1 addition & 0 deletions bin/command/install/bootstrap.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ require docker

import environment/docker.sh
import environment/docker-compose.sh
import environment/mutagen-version-check.sh

Registry::addCommand "boot" "Command::bootstrap"
Registry::addCommand "bootstrap" "Command::bootstrap"
Expand Down
20 changes: 20 additions & 0 deletions bin/environment/mutagen-version-check.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
#!/bin/bash

function Environment::checkMutagenVersion() {
local mutagenInstalledVersion="$(Mutagen::getInstalledVersion)"

if [[ "$mutagenInstalledVersion" == 0.18.* || "$mutagenInstalledVersion" > "0.18" ]]; then
Console::error "Error: Mutagen version 0.18.* is not supported yet. Please, run the command to install the latest supported version.
brew unlink mutagen && brew unlink mutagen-compose && brew install mutagen-io/mutagen/[email protected] mutagen-io/mutagen/[email protected]"
exit 1
fi
}

function Mutagen::getInstalledVersion() {
echo $(String::trimWhitespaces "$(
command -v mutagen >/dev/null 2>&1
test $? -eq 0 && mutagen version
)")
}

Registry::addChecker "Environment::checkMutagenVersion"
12 changes: 11 additions & 1 deletion docs/09-troubleshooting.md
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@ $config[SchedulerJenkinsConstants::JENKINS_CONFIGURATION] = [
```
**when**
Assets install error
Assets install error
```bash
line 1: run-s: not found
```
Expand All @@ -400,3 +400,13 @@ line 1: run-s: not found
1. ensure you are using latest docker-sdk and spryker/php image.
2. run `docker/sdk pull`
3. run `docker/sdk boot {{your deploy file}} && docker/sdk up --build`
**when**
Installation error with Mutagen v0.18.*
```bash
unable to bring up Mutagen Compose sidecar service: Error response from daemon: network is ambiguous (5 matches found based on ID prefix)
```
**then**
brew unlink mutagen && brew unlink mutagen-compose && brew install mutagen-io/mutagen/[email protected] mutagen-io/mutagen/[email protected]

0 comments on commit 3d5508f

Please sign in to comment.