Skip to content

Commit

Permalink
Use the new repo.yunohost.org/incus/ repository
Browse files Browse the repository at this point in the history
  • Loading branch information
Salamandar committed Oct 13, 2024
1 parent 0354ede commit 0d2c3ad
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -147,10 +147,10 @@ answering the default (just pressing enter) to all questions is fine.
incus admin init
```

Pre-built images are centralized on `devbaseimgs.yunohost.org` and we'll download them from there to speed things up:
Pre-built images are centralized on `repo.yunohost.org/incus` and we'll download them from there to speed things up:

```bash
incus remote add yunohost https://devbaseimgs.yunohost.org --public
incus remote add yunohost https://repo.yunohost.org/incus --protocol simplestream --public
```

On Archlinux-based distributions (Arch, Manjaro, ...) it was found that it's needed
Expand Down Expand Up @@ -186,7 +186,7 @@ cd ynh-dev # if not already done
./ynh-dev start
```

This should automatically download from `devbaseimgs.yunohost.org` a pre-build
This should automatically download from `repo.yunohost.org/incus` a pre-build
ynh-dev LXC image running Yunohost unstable, and create a fresh container from it.

After starting the LXC, your terminal will automatically be attached to it. If you
Expand Down
12 changes: 8 additions & 4 deletions ynh-dev
Original file line number Diff line number Diff line change
Expand Up @@ -200,9 +200,13 @@ function set_incus_remote()
critical "You need jq installed for ynh-dev"
fi

configured=$(incus remote list -f json | jq 'has("yunohost")')
if [[ "$configured" != "true" ]]; then
incus remote add yunohost https://devbaseimgs.yunohost.org --public
remote_url=$(incus remote list -f json | jq '.yunohost.Addr')
if [[ "${remote_url}" == *"devbaseimgs"* ]]; then
incus remote remove yunohost
fi
remote_url=$(incus remote list -f json | jq '.yunohost.Addr')
if [[ "$remote_url" == "null" ]]; then
incus remote add yunohost https://repo.yunohost.org/incus --protocol simplestream --public
fi
}

Expand All @@ -218,7 +222,7 @@ function start_ynhdev()
then
if ! incus image info "$BOX-base" &>/dev/null
then
LXC_BASE="ynh-dev-$DIST-amd64-$YNH_BRANCH-base"
LXC_BASE="yunohost/$DIST-$YNH_BRANCH/dev"
incus launch "yunohost:$LXC_BASE" "$BOX" -c security.nesting=true -c security.privileged=true \
|| critical "Failed to launch the container ?"
else
Expand Down

0 comments on commit 0d2c3ad

Please sign in to comment.