Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

prepare for public release, add licence #136

Merged
merged 7 commits into from
Jan 29, 2024
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
373 changes: 373 additions & 0 deletions LICENSE

Large diffs are not rendered by default.

12 changes: 11 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
#
# Copyright 2024 Oxide Computer Company
#

TOP = $(PWD)

Expand All @@ -23,6 +26,13 @@ gmakecheck:
exit 1; \
fi

.PHONY: cargocheck
cargocheck:
@if ! cargo --version >/dev/null 2>&1; then \
printf ' You must install Rust before continuing.\n' >&2; \
exit 1; \
fi

#
# Run a "quick" build of illumos for development:
#
Expand All @@ -47,7 +57,7 @@ setup: gmakecheck $(HELIOS_BUILD)
@printf '\n'

.PHONY: $(HELIOS_BUILD)
$(HELIOS_BUILD):
$(HELIOS_BUILD): cargocheck
@if [[ $$(/usr/bin/uname -o) != illumos ]]; then \
printf 'ERROR: must be built on illumos\n' >&2; \
exit 1; \
Expand Down
259 changes: 168 additions & 91 deletions README.md

Large diffs are not rendered by default.

54 changes: 37 additions & 17 deletions config/projects.toml
Original file line number Diff line number Diff line change
@@ -1,18 +1,24 @@
#
# Copyright 2024 Oxide Computer Company
#

[project.illumos]
github = "oxidecomputer/illumos-gate"
rev = "stlouis"
unless_env = "BUILD_OS"

[project.omnios-build]
github = "oxidecomputer/helios-omnios-build"
rev = "helios2"
unless_env = "BUILD_OS"
use_ssh = true
use_ssh = false
site_sh = true

[project.omnios-extra]
github = "oxidecomputer/helios-omnios-extra"
rev = "helios2"
unless_env = "BUILD_OS"
use_ssh = true
use_ssh = false
site_sh = true

[project.pinprick]
Expand All @@ -22,14 +28,38 @@ cargo_build = true

[project.phbl]
github = "oxidecomputer/phbl"
use_ssh = true
use_ssh = false

[project.image-builder]
github = "illumos/image-builder"
use_ssh = false
cargo_build = true
use_debug = true
auto_update = true

[project.bootserver]
github = "oxidecomputer/boot-image-tools"
use_ssh = false
cargo_build = true
auto_update = true

#
# -----------------------------------------------------------------------------
# NOTE: Repositories below this comment are all still private.
#
# If you do not have access to private repositories in the "oxidecomputer"
# GitHub organisation, set "OXIDE_STAFF=no" in your environment to skip
# cloning them.
# -----------------------------------------------------------------------------
#

[project.amd-host-image-builder]
github = "oxidecomputer/amd-host-image-builder"
use_ssh = true
cargo_build = true
use_debug = true
auto_update = true
unless_env = "OXIDE_STAFF"

[[project.amd-host-image-builder.fixup]]
#
Expand All @@ -43,28 +73,18 @@ to_branch = "main"
github = "oxidecomputer/amd-firmware"
use_ssh = true
auto_update = true

[project.bootserver]
github = "oxidecomputer/boot-image-tools"
use_ssh = true
cargo_build = true
auto_update = true

[project.image-builder]
github = "illumos/image-builder"
use_ssh = false
cargo_build = true
use_debug = true
auto_update = true
unless_env = "OXIDE_STAFF"

[project.chelsio-t6-roms]
github = "oxidecomputer/chelsio-t6-roms"
use_ssh = true
cargo_build = false
auto_update = true
unless_env = "OXIDE_STAFF"

[project.pilot]
github = "oxidecomputer/compliance-pilot"
github = "oxidecomputer/pilot"
use_ssh = true
cargo_build = true
auto_update = true
unless_env = "OXIDE_STAFF"
3 changes: 3 additions & 0 deletions image/mkcpio.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
#
# Copyright 2024 Oxide Computer Company
#

set -o errexit
set -o pipefail
Expand Down
3 changes: 3 additions & 0 deletions image/templates/files/bootparams.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
#
# Copyright 2024 Oxide Computer Company
#

prtconf -v /devices | awk -v want="$1" "
/name='/ && /type=string/ && /items=1/ {
Expand Down
3 changes: 3 additions & 0 deletions image/templates/files/compliance-beacon.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
#
# Copyright 2024 Oxide Computer Company
#

set -o errexit
set -o pipefail
Expand Down
83 changes: 43 additions & 40 deletions image/templates/files/compliance-beacon.xml
Original file line number Diff line number Diff line change
@@ -1,49 +1,52 @@
<?xml version="1.0"?>
<!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">
<!--
Copyright 2024 Oxide Computer Company
-->

<service_bundle type='manifest' name='site-compliance-beacon'>

<service name='site/compliance/beacon' type='service' version='1'>
<create_default_instance enabled='true' />

<!-- Wait for multi-user... -->
<dependency name='multi-user-server' grouping='require_all' restart_on='none'
type='service'>
<service_fmri value='svc:/milestone/multi-user-server' />
</dependency>

<!-- ... and make sure we run after the T6 has been configured. -->
<dependency name='t6init' grouping='require_all' restart_on='none'
type='service'>
<service_fmri value='svc:/system/t6init' />
</dependency>

<!-- ... and after our postboot script. -->
<dependency name='after-postboot' grouping='require_all' restart_on='none'
type='service'>
<service_fmri value='svc:/site/postboot' />
</dependency>

<exec_method type='method' name='start'
exec='/usr/lib/compliance-beacon' timeout_seconds='30' />

<exec_method type='method' name='stop' exec=':kill' timeout_seconds='30' />

<property_group name='startd' type='framework'>
<propval name='duration' type='astring' value='child' />
</property_group>

<stability value='Unstable' />

<template>
<common_name>
<loctext xml:lang='C'>compliance multicast beacon</loctext>
</common_name>
<description>
<loctext xml:lang='C'>sends multicast discovery announcements</loctext>
</description>
</template>
<create_default_instance enabled='true' />

<!-- Wait for multi-user... -->
<dependency name='multi-user-server' grouping='require_all'
restart_on='none' type='service'>
<service_fmri value='svc:/milestone/multi-user-server' />
</dependency>

<!-- ... and make sure we run after the T6 has been configured. -->
<dependency name='t6init' grouping='require_all' restart_on='none'
type='service'>
<service_fmri value='svc:/system/t6init' />
</dependency>

<!-- ... and after our postboot script. -->
<dependency name='after-postboot' grouping='require_all' restart_on='none'
type='service'>
<service_fmri value='svc:/site/postboot' />
</dependency>

<exec_method type='method' name='start'
exec='/usr/lib/compliance-beacon' timeout_seconds='30' />

<exec_method type='method' name='stop' exec=':kill' timeout_seconds='30' />

<property_group name='startd' type='framework'>
<propval name='duration' type='astring' value='child' />
</property_group>

<stability value='Unstable' />

<template>
<common_name>
<loctext xml:lang='C'>compliance multicast beacon</loctext>
</common_name>
<description>
<loctext xml:lang='C'>sends multicast discovery announcements
</loctext>
</description>
</template>
</service>

</service_bundle>
<!-- vim: set ts=2 sts=2 sw=2 et: -->
70 changes: 36 additions & 34 deletions image/templates/files/compliance-dump.xml
Original file line number Diff line number Diff line change
@@ -1,43 +1,45 @@
<?xml version="1.0"?>
<!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">
<!--
Copyright 2024 Oxide Computer Company
-->

<service_bundle type='manifest' name='site-compliance-dump'>

<service name='site/compliance/dump' type='service' version='1'>
<create_default_instance enabled='false' />

<!-- Wait for local file systems, like dumpadm does: -->
<dependency name='local-filesystems' grouping='require_all' restart_on='none'
type='service'>
<service_fmri value='svc:/system/filesystem/local'/>
</dependency>

<!-- Hold dumpadm back until we've had a chance to look around: -->
<dependent name='compliance-dump-dumpadm' restart_on='none'
grouping='optional_all'>
<service_fmri value='svc:/system/dumpadm'/>
</dependent>

<exec_method type='method' name='start'
exec='/usr/bin/pilot gimlet dump setup' timeout_seconds='600' />

<exec_method type='method' name='stop' exec=':kill' timeout_seconds='30' />

<property_group name='startd' type='framework'>
<propval name='duration' type='astring' value='transient' />
</property_group>

<stability value='Unstable' />

<template>
<common_name>
<loctext xml:lang='C'>compliance ad hoc dump setup</loctext>
</common_name>
<description>
<loctext xml:lang='C'>sets up a ZFS pool and dump device</loctext>
</description>
</template>
<create_default_instance enabled='false' />

<!-- Wait for local file systems, like dumpadm does: -->
<dependency name='local-filesystems' grouping='require_all'
restart_on='none' type='service'>
<service_fmri value='svc:/system/filesystem/local'/>
</dependency>

<!-- Hold dumpadm back until we've had a chance to look around: -->
<dependent name='compliance-dump-dumpadm' restart_on='none'
grouping='optional_all'>
<service_fmri value='svc:/system/dumpadm'/>
</dependent>

<exec_method type='method' name='start'
exec='/usr/bin/pilot gimlet dump setup' timeout_seconds='600' />

<exec_method type='method' name='stop' exec=':kill' timeout_seconds='30' />

<property_group name='startd' type='framework'>
<propval name='duration' type='astring' value='transient' />
</property_group>

<stability value='Unstable' />

<template>
<common_name>
<loctext xml:lang='C'>compliance ad hoc dump setup</loctext>
</common_name>
<description>
<loctext xml:lang='C'>sets up a ZFS pool and dump device</loctext>
</description>
</template>
</service>

</service_bundle>
<!-- vim: set ts=2 sts=2 sw=2 et: -->
3 changes: 3 additions & 0 deletions image/templates/files/compliance-hostname.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
#
# Copyright 2024 Oxide Computer Company
#

set -o errexit
set -o pipefail
Expand Down
4 changes: 3 additions & 1 deletion image/templates/files/compliance-hostname.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
<?xml version="1.0"?>
<!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">
<!--
Copyright 2024 Oxide Computer Company
-->

<service_bundle type='manifest' name='site-compliance-hostname'>

Expand Down Expand Up @@ -45,4 +48,3 @@
</service>

</service_bundle>
<!-- vim: set ts=2 sts=2 sw=2 et: -->
3 changes: 3 additions & 0 deletions image/templates/files/compliance-postboot.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
#!/bin/bash
#
# Copyright 2024 Oxide Computer Company
#

set -o errexit
set -o pipefail
Expand Down
Loading