Skip to content

Commit

Permalink
Merge pull request #196 from hpidcock/noble
Browse files Browse the repository at this point in the history
chore: move to noble
  • Loading branch information
hpidcock authored Jul 7, 2024
2 parents 5ee7f5b + a2c0bb5 commit 66ff959
Show file tree
Hide file tree
Showing 96 changed files with 1,055 additions and 1,531 deletions.
19 changes: 9 additions & 10 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,18 +1,17 @@
STATIC_ANALYSIS_JOB ?=
IGNORE_STATIC_ANALYSIS ?=
PUSH_JOB ?=
PUSH_TARGET ?= "jobs/ci-run"
JJB_CONF_PATH ?= jenkins-jjb
JUJU_REPO_PATH ?= "${GOPATH}/src/github.com/juju/juju"
STATIC_ANALYSIS_JOB ?=
IGNORE_STATIC_ANALYSIS ?=
PUSH_JOB ?=
PUSH_TARGET ?= "jobs/ci-run"
JJB_CONF_PATH ?= jenkins-jjb
JUJU_REPO_PATH ?= "${GOPATH}/src/github.com/juju/juju"

cwd = $(shell pwd)
virtualenv_dir = $(cwd)/venv
cwd = $(shell pwd)
virtualenv_dir = $(cwd)/venv
python_base_path = $(shell which python3)

.PHONY: ensure-venv
ensure-venv:
pip3 show virtualenv > /dev/null || pip3 install virtualenv
test -d venv || virtualenv -p $(python_base_path) $(virtualenv_dir)
$(python_base_path) -m venv $(virtualenv_dir)

.PHONY: install-deps
install-deps: ensure-venv
Expand Down
27 changes: 27 additions & 0 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

42 changes: 42 additions & 0 deletions flake.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
description = "juju qa jenkins job builder shell";
inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.05";
};

outputs = { self, nixpkgs, ... } @ inputs:
let
forAllSystems = inputs.nixpkgs.lib.genAttrs [
"aarch64-linux"
"x86_64-linux"
"aarch64-darwin"
];
in
{
devShells = forAllSystems (system: {
default =
let
pkgs = nixpkgs.legacyPackages.${system};
in
pkgs.mkShell {
name = "juju-qa-jenkins";
# Enable experimental features without having to specify the argument
NIX_CONFIG = "experimental-features = nix-command flakes";
nativeBuildInputs = with pkgs; [
coreutils
findutils
gnumake
gnused
gnugrep
zsh
go
python3
shellcheck
];
shellHook = ''
exec zsh
'';
};
});
};
}
11 changes: 11 additions & 0 deletions jenkins-jjb-localhost
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[job_builder]
ignore_cache=True
keep_descriptions=False
include_path=.:scripts:~/git/
recursive=False
exclude=.*:manual:./development
allow_duplicates=False

[jenkins]
url=http://localhost:8080
query_plugins_info=True
30 changes: 15 additions & 15 deletions jobs/ci-run/build/builddqlite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
- validating-string:
description: The git short hash for the commit you wish to build
name: SHORT_GIT_COMMIT
regex: ^\S{7}$
regex: ^\S{{7}}$
msg: Enter a valid 7 char git sha
builders:
- multijob:
Expand All @@ -24,23 +24,23 @@
- name: build-dqlite-amd64
current-parameters: true
predefined-parameters: |-
GIT_COMMIT=${SHORT_GIT_COMMIT}
GIT_COMMIT=${{SHORT_GIT_COMMIT}}
- name: build-dqlite-arm64
current-parameters: true
predefined-parameters: |-
GIT_COMMIT=${SHORT_GIT_COMMIT}
GIT_COMMIT=${{SHORT_GIT_COMMIT}}
- name: build-dqlite-ppc64el
current-parameters: true
predefined-parameters: |-
GIT_COMMIT=${SHORT_GIT_COMMIT}
GIT_COMMIT=${{SHORT_GIT_COMMIT}}
- name: build-dqlite-s390x
current-parameters: true
predefined-parameters: |-
GIT_COMMIT=${SHORT_GIT_COMMIT}
GIT_COMMIT=${{SHORT_GIT_COMMIT}}
- job:
name: build-dqlite-amd64
node: ephemeral-focal-8c-32g-amd64
node: ephemeral-noble-8c-32g-amd64
concurrent: true
description: |-
Build dqlite libraries for specified platform
Expand All @@ -53,7 +53,7 @@
- validating-string:
description: The git short hash for the commit you wish to build
name: SHORT_GIT_COMMIT
regex: ^\S{7}$
regex: ^\S{{7}}$
msg: Enter a valid 7 char git sha
builders:
- wait-for-cloud-init
Expand All @@ -68,7 +68,7 @@

- job:
name: build-dqlite-arm64
node: ephemeral-focal-8c-32g-arm64
node: ephemeral-noble-8c-32g-arm64
concurrent: true
description: |-
Build dqlite libraries for specified platform
Expand All @@ -81,7 +81,7 @@
- validating-string:
description: The git short hash for the commit you wish to build
name: SHORT_GIT_COMMIT
regex: ^\S{7}$
regex: ^\S{{7}}$
msg: Enter a valid 7 char git sha
builders:
- wait-for-cloud-init
Expand All @@ -98,11 +98,11 @@
name: "make-dqlite"
builders:
- host-src-command:
src_command: !include-raw: ../scripts/snippet_make-dqlite-build.sh
src_command: !include-raw-verbatim: ../scripts/snippet_make-dqlite-build.sh

- job:
name: build-dqlite-ppc64el
node: ephemeral-focal-8c-32g-amd64
node: ephemeral-noble-8c-32g-amd64
concurrent: true
description: |-
Build dqlite libraries for specified platform
Expand All @@ -115,7 +115,7 @@
- validating-string:
description: The git short hash for the commit you wish to build
name: SHORT_GIT_COMMIT
regex: ^\S{7}$
regex: ^\S{{7}}$
msg: Enter a valid 7 char git sha
builders:
- wait-for-cloud-init
Expand All @@ -132,7 +132,7 @@

- job:
name: build-dqlite-s390x
node: ephemeral-focal-8c-32g-amd64
node: ephemeral-noble-8c-32g-amd64
concurrent: true
description: |-
Build dqlite libraries for specified platform
Expand All @@ -145,7 +145,7 @@
- validating-string:
description: The git short hash for the commit you wish to build
name: SHORT_GIT_COMMIT
regex: ^\S{7}$
regex: ^\S{{7}}$
msg: Enter a valid 7 char git sha
builders:
- wait-for-cloud-init
Expand All @@ -164,7 +164,7 @@
name: "make-cross-dqlite"
builders:
- host-src-command:
src_command: !include-raw: ../scripts/snippet_make-dqlite-cross-build.sh
src_command: !include-raw-verbatim: ../scripts/snippet_make-dqlite-cross-build.sh

- builder:
name: "upload-s3-dqlite"
Expand Down
40 changes: 20 additions & 20 deletions jobs/ci-run/build/buildjuju.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

- job:
name: build-juju
node: ephemeral-focal-16c-64g-amd64
node: ephemeral-noble-16c-64g-amd64
concurrent: true
description: |-
Build juju binaries for specified platform
Expand All @@ -11,7 +11,7 @@
- workspace-cleanup
- timestamps
- build-name:
name: build-juju-${BUILD_LABEL}
name: build-juju-${{BUILD_LABEL}}
properties:
- build-discarder:
days-to-keep: 30
Expand All @@ -22,7 +22,7 @@
- validating-string:
description: The git short hash for the commit you wish to build
name: SHORT_GIT_COMMIT
regex: ^\S{7}$
regex: ^\S{{7}}$
msg: Enter a valid 7 char git sha
- string:
default: ''
Expand Down Expand Up @@ -53,23 +53,23 @@
- setup-go-environment
- get-s3-source-payload
- set-build-description:
GOVERSION: "${GOVERSION}"
GOVERSION: "${{GOVERSION}}"
- make-juju:
platform: ${PLATFORM}
build_tags: ${BUILD_TAGS}
platform: ${{PLATFORM}}
build_tags: ${{BUILD_TAGS}}
- conditional-step:
condition-kind: regex-match
label: "$PLATFORM"
regex: "windows.*"
steps:
- make-windows-installer:
platform: ${PLATFORM}
platform: ${{PLATFORM}}
- create-build-payload-tarballs:
platform: ${PLATFORM}
label: ${LABEL:-}
platform: ${{PLATFORM}}
label: ${{LABEL:-}}
- upload-s3-binaries:
platform: ${PLATFORM}
label: ${LABEL:-}
platform: ${{PLATFORM}}
label: ${{LABEL:-}}
- conditional-step:
condition-kind: and
condition-operands:
Expand All @@ -81,7 +81,7 @@
condition-string2: ""
steps:
- upload-s3-agent-binaries:
platform: ${PLATFORM}
platform: ${{PLATFORM}}

- builder:
name: "make-windows-installer"
Expand Down Expand Up @@ -135,11 +135,11 @@
rm -rf make-juju.properties
- host-src-command:
src_command: !include-raw: ../scripts/snippet_make-release-build.sh
src_command: !include-raw-verbatim: ../scripts/snippet_make-release-build.sh

- job:
name: build-jujud-operator
node: ephemeral-jammy-8c-32g-amd64
node: ephemeral-noble-8c-32g-amd64
description: Build juju docker image for caas operator on all platforms.
wrappers:
- ansicolor
Expand All @@ -153,7 +153,7 @@
- validating-string:
description: The git short hash for the commit you wish to build
name: SHORT_GIT_COMMIT
regex: ^\S{7}$
regex: ^\S{{7}}$
msg: Enter a valid 7 char git sha
- string:
default: ""
Expand All @@ -170,13 +170,13 @@
- setup-go-environment
- get-s3-source-payload
- set-build-description:
GOVERSION: "${GOVERSION}"
GOVERSION: "${{GOVERSION}}"
- shell: |-
#!/bin/bash
set -eu
touch build.properties
echo "DOCKER_USERNAME=public.ecr.aws/jujuqabot/build-${SHORT_GIT_COMMIT}" >> build.properties
echo "DOCKER_USERNAME=public.ecr.aws/jujuqabot/build-${{SHORT_GIT_COMMIT}}" >> build.properties
cat build.properties
- inject:
Expand All @@ -186,11 +186,11 @@
- ensure-aws-credentials
- docker-ecr-login
- get-s3-build-payload-packaging:
platforms: "${BUILD_PLATFORMS}"
platforms: "${{BUILD_PLATFORMS}}"
- host-src-command:
src_command: !include-raw: ../scripts/snippet_setup_ecr_public.sh
src_command: !include-raw-verbatim: ../scripts/snippet_setup_ecr_public.sh
- host-src-command:
src_command: !include-raw: ../scripts/snippet_caas-jujud-operator.sh
src_command: !include-raw-verbatim: ../scripts/snippet_caas-jujud-operator.sh

- builder:
name: "create-build-payload-tarballs"
Expand Down
Loading

0 comments on commit 66ff959

Please sign in to comment.