Skip to content
Open
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
11 changes: 8 additions & 3 deletions package-manifest.toml
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ source.type = "local"
source.rust.binary_names = ["nexus", "schema-updater"]
source.rust.release = true
source.paths = [
{ from = "/opt/ooce/pgsql-13/lib/amd64", to = "/opt/ooce/pgsql-13/lib/amd64" },
{ from = "/opt/ooce/pgsql-18/lib/amd64", to = "/opt/ooce/pgsql-18/lib/amd64" },
{ from = "smf/nexus/manifest.xml", to = "/var/svc/manifest/site/nexus/manifest.xml" },
{ from = "smf/nexus/{{rack-topology}}", to = "/var/svc/manifest/site/nexus" },
{ from = "out/console-assets", to = "/var/nexus/static" },
Expand All @@ -132,7 +132,8 @@ source.paths = [
output.type = "zone"
setup_hint = """
- Run `cargo xtask download console` to download the web console assets
- Run `pkg install library/postgresql-13` to download Postgres libraries
- Run `pkg install library/postgresql-18` to download Postgres libraries
- Run `pkg set-mediator -V 18 postgresql` to select the library version
"""
output.intermediate_only = true

Expand Down Expand Up @@ -528,10 +529,14 @@ source.type = "local"
source.paths = [
{ from = "smf/switch_zone_setup/manifest.xml", to = "/var/svc/manifest/site/switch_zone_setup/manifest.xml" },
{ from = "smf/switch_zone_setup/support_authorized_keys", to = "/opt/oxide/support/authorized_keys" },
{ from = "/opt/ooce/pgsql-13/lib/amd64", to = "/opt/ooce/pgsql-13/lib/amd64" },
{ from = "/opt/ooce/pgsql-18/lib/amd64", to = "/opt/ooce/pgsql-18/lib/amd64" },
]
output.type = "zone"
output.intermediate_only = true
setup_hint = """
- Run `pkg install library/postgresql-18` to download Postgres libraries
- Run `pkg set-mediator -V 18 postgresql` to select the library version
"""

[package.sp-sim]
service_name = "sp-sim"
Expand Down
27 changes: 17 additions & 10 deletions tools/install_builder_prerequisites.sh
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ HOST_OS=$(uname -s)
function install_packages {
if [[ "${HOST_OS}" == "Linux" ]]; then
# If Nix is in use, we don't need to install any packagess here,
# as they're provided by the Nix flake.
# as they're provided by the Nix flake.
if [[ "${OMICRON_USE_FLAKE-}" = 1 ]] && nix flake show &> /dev/null; then
echo "OMICRON_USE_FLAKE=1 in environment and nix detected in PATH, skipping package installation"
return
Expand Down Expand Up @@ -145,7 +145,7 @@ function install_packages {
fi
elif [[ "${HOST_OS}" == "SunOS" ]]; then
CLANGVER=15
PGVER=13
PGVER=18
packages=(
"pkg:/package/pkg"
"build-essential"
Expand Down Expand Up @@ -174,7 +174,8 @@ function install_packages {
# Explicitly manage the return code using "rc" to observe the result of this
# command without exiting the script entirely (due to bash's "errexit").
rc=0
confirm "Install (or update) [${packages[*]}]?" && { pfexec pkg install -v "${packages[@]}" || rc=$?; }
confirm "Install (or update) [${packages[*]}]?" &&
{ pfexec pkg install -v "${packages[@]}" || rc=$?; }
# Return codes:
# 0: Normal Success
# 4: Failure because we're already up-to-date. Also acceptable.
Expand All @@ -191,13 +192,19 @@ function install_packages {
pkg publisher
pkg list -afv "${packages[@]}"
elif [[ "${HOST_OS}" == "Darwin" ]]; then
PGVER=18
packages=(
'coreutils'
'postgresql@14'
'pkg-config'
'libxmlsec1'
"coreutils"
"postgresql@$PGVER"
"pkg-config"
"libxmlsec1"
)
confirm "Install (or update) [${packages[*]}]?" && brew install "${packages[@]}"
confirm "Install (or update) [${packages[*]}]?" &&
brew install "${packages[@]}"
confirm "Set symlinks?" && {
brew unlink postgresql
brew link --force --overwrite postgresql@$PGVER
}
else
echo "Skipping builder prereqs for unsupported OS: ${HOST_OS}"
exit 1
Expand Down Expand Up @@ -239,12 +246,12 @@ function show_hint
case "$1" in
"pg_config")
if [[ "${HOST_OS}" == "SunOS" ]]; then
echo "On illumos, $1 is typically found in '/opt/ooce/bin'"
echo "On helios, $1 is typically found in '/opt/ooce/bin'"
fi
;;
"pkg-config")
if [[ "${HOST_OS}" == "SunOS" ]]; then
echo "On illumos, $1 is typically found in '/usr/bin'"
echo "On helios, $1 is typically found in '/usr/bin'"
fi
;;
"cockroach")
Expand Down
2 changes: 1 addition & 1 deletion tools/install_runner_prerequisites.sh
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ function install_packages {
if [[ "${HOST_OS}" == "SunOS" ]]; then
packages=(
'pkg:/package/pkg'
'library/postgresql-13'
'library/postgresql-18'
'pkg-config'
'brand/omicron1/tools'
'library/libxmlsec1'
Expand Down
Loading