canonical-ubuntu-qa team mailing list archive
-
canonical-ubuntu-qa team
-
Mailing list archive
-
Message #06419
[Merge] autopkgtest-cloud:only-charmcraft-yaml into autopkgtest-cloud:master
Tim Andersson has proposed merging autopkgtest-cloud:only-charmcraft-yaml into autopkgtest-cloud:master.
Requested reviews:
Canonical's Ubuntu QA (canonical-ubuntu-qa)
For more details, see:
https://code.launchpad.net/~ubuntu-release/autopkgtest-cloud/+git/autopkgtest-cloud/+merge/483128
Transition to use less yaml files to define our charms
--
Your team Canonical's Ubuntu QA is requested to review the proposed merge of autopkgtest-cloud:only-charmcraft-yaml into autopkgtest-cloud:master.
diff --git a/charms/focal/autopkgtest-cloud-worker/actions.yaml b/charms/focal/autopkgtest-cloud-worker/actions.yaml
deleted file mode 100644
index 989187b..0000000
--- a/charms/focal/autopkgtest-cloud-worker/actions.yaml
+++ /dev/null
@@ -1,7 +0,0 @@
-reload-units:
- description: Reload all systemd units.
- Use this after you upgrade the charm to
- change the worker code, for example.
-
-update-sources:
- description: Update (git pull) autopkgtest/autodep8
diff --git a/charms/focal/autopkgtest-cloud-worker/charmcraft.yaml b/charms/focal/autopkgtest-cloud-worker/charmcraft.yaml
index 3522b7a..4dc7d44 100644
--- a/charms/focal/autopkgtest-cloud-worker/charmcraft.yaml
+++ b/charms/focal/autopkgtest-cloud-worker/charmcraft.yaml
@@ -17,3 +17,178 @@ bases:
channel: "20.04"
architectures:
- amd64
+
+# metadata.yaml
+name: autopkgtest-cloud-worker
+summary: autopkgtest cloud worker
+description: |
+ An autopkgtest worker receives test requests from AMQP, runs autopkgtest with
+ the ssh/nova or lxd runner, and puts the test results into Swift.
+requires:
+ amqp:
+ interface: rabbitmq
+ haproxy-lxd-armhf:
+ interface: juju-info
+subordinate: false
+storage:
+ tmp:
+ type: filesystem
+ description: working files for running tests
+ shared: false
+ read-only: false
+ minimum-size: 200G
+ location: /tmp
+
+# actions.yaml done?
+actions:
+ reload-units:
+ description: Reload all systemd units.
+ Use this after you upgrade the charm to
+ change the worker code, for example.
+ update-sources:
+ description: Update (git pull) autopkgtest/autodep8
+
+# config.yaml
+config:
+ options:
+ package_status:
+ type: string
+ description: "APT layer package_status"
+ default: install
+ nova-rcs:
+ type: string
+ description: "base64 encoded tarball of nova OpenStack credential .rc files"
+ default: ~
+ n-workers:
+ type: string
+ description: "yaml dict region -> arch -> n_workers corresponding \
+ to the number of worker instances to run"
+ default: ~
+ lxd-remotes:
+ type: string
+ description: "yaml dict arch -> ip -> n_workers corresponding to the \
+ number of LXD workers to run"
+ default: ~
+ mail-notify:
+ type: string
+ description: "email addresses (space separated) to notify on worker failure"
+ default: ~
+ ssh-config:
+ type: string
+ description: "~/.ssh/config, in case some special tweaks are needed"
+ default: ~
+ swift-auth-url:
+ type: string
+ description: "swift auth URL"
+ default: ~
+ swift-username:
+ type: string
+ description: "username for swift"
+ default: ~
+ swift-password:
+ type: string
+ description: "password for swift"
+ default: ~
+ swift-region:
+ type: string
+ description: "the swift region to use"
+ default: ~
+ swift-project-domain-name:
+ type: string
+ description: "the swift project domain (v3 only)"
+ default: ~
+ swift-project-name:
+ type: string
+ description: "the swift project name (v3 only)"
+ default: ~
+ swift-user-domain-name:
+ type: string
+ description: "the swift user domain name (v3 only)"
+ default: ~
+ swift-auth-version:
+ type: int
+ description: "the keystone API version to use for swift (2 or 3)"
+ default: 2
+ swift-tenant:
+ type: string
+ description: "the swift tenant name (v2 only)"
+ default: ~
+ releases:
+ type: string
+ description: "the releases to test for"
+ default: ~
+ mirror:
+ type: string
+ description: "the archive mirror to use for tests"
+ default: "http://archive.ubuntu.com/ubuntu/"
+ worker-net-names:
+ type: string
+ description: "Network names for datacentre/arch combinations with a \
+ default (must have port 22 inbound open)"
+ worker-setup-command:
+ type: string
+ description: "autopkgtest's --setup-command argument"
+ default: ~
+ worker-setup-command2:
+ type: string
+ description: "second autopkgtest --setup-command argument"
+ default: ~
+ worker-flavor-config:
+ type: string
+ description: "yaml dict mapping region->arch->size to a flavor name"
+ default: |-
+ default: m1.small
+ big: m1.large
+ worker-args:
+ type: string
+ description: "autopkgtest virt args"
+ default: "null"
+ influxdb-hostname:
+ default: ~
+ description: The hostname of the remote influxdb to submit metrics to
+ type: string
+ influxdb-port:
+ default: 8086
+ description: The port of the remote influxdb to submit metrics to
+ type: int
+ influxdb-username:
+ default: ~
+ description: The influxdb username
+ type: string
+ influxdb-password:
+ default: ~
+ description: The influxdb password
+ type: string
+ influxdb-database:
+ default: ~
+ description: The influxdb database to use
+ type: string
+ influxdb-context:
+ default: "production"
+ description: Submit all metrics with this as the "context" tag,
+ to differentiate staging vs. production submissions
+ type: string
+ worker-tmp-cleanup-config:
+ default: ""
+ description: config for periodic cleanup of /tmp directory
+ type: string
+ worker-upstream-percentage:
+ default: 33
+ description: Percentage of workers that'll accept upstream tests.
+ This is useful to prioritise certain tests.
+ type: int
+ stable-release-percentage:
+ default: 100
+ description: Percentage of workers that'll accept test requests for
+ stable releases. This is useful to prioritise tests
+ for the development release.
+ type: int
+
+# layer.yaml
+# I don't know how to handle this.
+# The layer functionality is obsoleted, and is a remnant of reactive charming. I don't believe
+# there exists an alternative way of including this in the charmcraft.yaml.
+# I think this functionality is incompatible with a purely modern charmcraft.yaml.
+# The concept of a layer is something only included in reactive charming.
+# Moving past this involves at least partially rewriting the charm.
+
diff --git a/charms/focal/autopkgtest-cloud-worker/config.yaml b/charms/focal/autopkgtest-cloud-worker/config.yaml
deleted file mode 100644
index 01e3dc9..0000000
--- a/charms/focal/autopkgtest-cloud-worker/config.yaml
+++ /dev/null
@@ -1,133 +0,0 @@
-options:
- package_status:
- type: string
- description: "APT layer package_status"
- default: install
- nova-rcs:
- type: string
- description: "base64 encoded tarball of nova OpenStack credential .rc files"
- default: ~
- n-workers:
- type: string
- description: "yaml dict region -> arch -> n_workers corresponding \
- to the number of worker instances to run"
- default: ~
- lxd-remotes:
- type: string
- description: "yaml dict arch -> ip -> n_workers corresponding to the \
- number of LXD workers to run"
- default: ~
- mail-notify:
- type: string
- description: "email addresses (space separated) to notify on worker failure"
- default: ~
- ssh-config:
- type: string
- description: "~/.ssh/config, in case some special tweaks are needed"
- default: ~
- swift-auth-url:
- type: string
- description: "swift auth URL"
- default: ~
- swift-username:
- type: string
- description: "username for swift"
- default: ~
- swift-password:
- type: string
- description: "password for swift"
- default: ~
- swift-region:
- type: string
- description: "the swift region to use"
- default: ~
- swift-project-domain-name:
- type: string
- description: "the swift project domain (v3 only)"
- default: ~
- swift-project-name:
- type: string
- description: "the swift project name (v3 only)"
- default: ~
- swift-user-domain-name:
- type: string
- description: "the swift user domain name (v3 only)"
- default: ~
- swift-auth-version:
- type: int
- description: "the keystone API version to use for swift (2 or 3)"
- default: 2
- swift-tenant:
- type: string
- description: "the swift tenant name (v2 only)"
- default: ~
- releases:
- type: string
- description: "the releases to test for"
- default: ~
- mirror:
- type: string
- description: "the archive mirror to use for tests"
- default: "http://archive.ubuntu.com/ubuntu/"
- worker-net-names:
- type: string
- description: "Network names for datacentre/arch combinations with a \
- default (must have port 22 inbound open)"
- worker-setup-command:
- type: string
- description: "autopkgtest's --setup-command argument"
- default: ~
- worker-setup-command2:
- type: string
- description: "second autopkgtest --setup-command argument"
- default: ~
- worker-flavor-config:
- type: string
- description: "yaml dict mapping region->arch->size to a flavor name"
- default: |-
- default: m1.small
- big: m1.large
- worker-args:
- type: string
- description: "autopkgtest virt args"
- default: "null"
- influxdb-hostname:
- default: ~
- description: The hostname of the remote influxdb to submit metrics to
- type: string
- influxdb-port:
- default: 8086
- description: The port of the remote influxdb to submit metrics to
- type: int
- influxdb-username:
- default: ~
- description: The influxdb username
- type: string
- influxdb-password:
- default: ~
- description: The influxdb password
- type: string
- influxdb-database:
- default: ~
- description: The influxdb database to use
- type: string
- influxdb-context:
- default: "production"
- description: Submit all metrics with this as the "context" tag,
- to differentiate staging vs. production submissions
- type: string
- worker-tmp-cleanup-config:
- default: ""
- description: config for periodic cleanup of /tmp directory
- type: string
- worker-upstream-percentage:
- default: 33
- description: Percentage of workers that'll accept upstream tests.
- This is useful to prioritise certain tests.
- type: int
- stable-release-percentage:
- default: 100
- description: Percentage of workers that'll accept test requests for
- stable releases. This is useful to prioritise tests
- for the development release.
- type: int
diff --git a/charms/focal/autopkgtest-cloud-worker/metadata.yaml b/charms/focal/autopkgtest-cloud-worker/metadata.yaml
deleted file mode 100644
index 40d92ef..0000000
--- a/charms/focal/autopkgtest-cloud-worker/metadata.yaml
+++ /dev/null
@@ -1,24 +0,0 @@
-name: autopkgtest-cloud-worker
-summary: autopkgtest cloud worker
-maintainer: Brian Murray <brian.murray@xxxxxxxxxxxxx>
-series:
- - focal
-description: |
- An autopkgtest worker receives test requests from AMQP, runs autopkgtest with
- the ssh/nova or lxd runner, and puts the test results into Swift.
-tags:
- - ops
-requires:
- amqp:
- interface: rabbitmq
- haproxy-lxd-armhf:
- interface: juju-info
-subordinate: false
-storage:
- tmp:
- type: filesystem
- description: working files for running tests
- shared: false
- read-only: false
- minimum-size: 200G
- location: /tmp
diff --git a/charms/focal/autopkgtest-web/actions.yaml b/charms/focal/autopkgtest-web/actions.yaml
deleted file mode 100644
index efe984d..0000000
--- a/charms/focal/autopkgtest-web/actions.yaml
+++ /dev/null
@@ -1,2 +0,0 @@
-update-sources:
- description: Update (git pull) cloned repositories
diff --git a/charms/focal/autopkgtest-web/charmcraft.yaml b/charms/focal/autopkgtest-web/charmcraft.yaml
index 546437f..59c121c 100644
--- a/charms/focal/autopkgtest-web/charmcraft.yaml
+++ b/charms/focal/autopkgtest-web/charmcraft.yaml
@@ -19,3 +19,107 @@ bases:
channel: "20.04"
architectures:
- amd64
+
+# metadata.yaml
+name: autopkgtest-web
+summary: autopkgtest web frontend with results from Swift
+description: |
+ This regularly downloads new autopkgtest results from Swift and makes them
+ browsable through a web server.
+subordinate: true
+requires:
+ amqp:
+ interface: rabbitmq
+ website:
+ interface: apache-website
+ scope: container
+
+# actions.yaml
+actions:
+ update-sources:
+ description: Update (git pull) cloned repositories
+
+# config.yaml
+config:
+ options:
+ package_status:
+ type: string
+ description: "APT layer package_status"
+ default: install
+ storage-url-internal:
+ type: string
+ default:
+ description: "Cloud internal swift storage URL (from swift stat -v)"
+ storage-url-external:
+ type: string
+ default:
+ description: "Public external swift storage URL"
+ hostname:
+ type: string
+ default: autopkgtest.local
+ description: "Public host name of this web server"
+ archive-url:
+ type: string
+ default:
+ description: "URL of the Ubuntu archive, in case you want to use a mirror"
+ github-secrets:
+ type: string
+ default:
+ description: "projectname → shared secret \
+ JSON mapping for github test requests"
+ external-web-requests-api-keys:
+ type: string
+ default:
+ description: "user/project → api key \
+ JSON mapping for non-github automated test requests"
+ github-status-credentials:
+ type: string
+ default:
+ description: "project:user:token github credentials \
+ for POSTing to statuses_url"
+ https-proxy:
+ type: string
+ default:
+ description: "$https_proxy environment variable (for accessing github)"
+ no-proxy:
+ type: string
+ default:
+ description: "$no_proxy environment variable (for accessing sites \
+ other than github, like login.ubuntu.com and launchpad.net)"
+ indexed-packages-fp:
+ type: string
+ default:
+ description: "Filepath for json file with index of packages from database"
+ public-swift-creds:
+ type: string
+ default:
+ description: "creds for openstack swift storage for updating github jobs"
+ allowed-requestor-teams:
+ type: string
+ default: ~
+ description: "List of teams that are allowed to request autopkgtest tests."
+ influxdb-hostname:
+ default: ~
+ description: The hostname of the remote influxdb to submit metrics to
+ type: string
+ influxdb-port:
+ default: 8086
+ description: The port of the remote influxdb to submit metrics to
+ type: int
+ influxdb-username:
+ default: ~
+ description: The influxdb username
+ type: string
+ influxdb-password:
+ default: ~
+ description: The influxdb password
+ type: string
+ influxdb-database:
+ default: ~
+ description: The influxdb database to use
+ type: string
+ influxdb-context:
+ default: "production"
+ description: Submit all metrics with this as the "context" tag,
+ to differentiate staging vs. production submissions
+ type: string
diff --git a/charms/focal/autopkgtest-web/config.yaml b/charms/focal/autopkgtest-web/config.yaml
deleted file mode 100644
index 0d1d94f..0000000
--- a/charms/focal/autopkgtest-web/config.yaml
+++ /dev/null
@@ -1,82 +0,0 @@
-options:
- package_status:
- type: string
- description: "APT layer package_status"
- default: install
- storage-url-internal:
- type: string
- default:
- description: "Cloud internal swift storage URL (from swift stat -v)"
- storage-url-external:
- type: string
- default:
- description: "Public external swift storage URL"
- hostname:
- type: string
- default: autopkgtest.local
- description: "Public host name of this web server"
- archive-url:
- type: string
- default:
- description: "URL of the Ubuntu archive, in case you want to use a mirror"
- github-secrets:
- type: string
- default:
- description: "projectname → shared secret \
- JSON mapping for github test requests"
- external-web-requests-api-keys:
- type: string
- default:
- description: "user/project → api key \
- JSON mapping for non-github automated test requests"
- github-status-credentials:
- type: string
- default:
- description: "project:user:token github credentials \
- for POSTing to statuses_url"
- https-proxy:
- type: string
- default:
- description: "$https_proxy environment variable (for accessing github)"
- no-proxy:
- type: string
- default:
- description: "$no_proxy environment variable (for accessing sites \
- other than github, like login.ubuntu.com and launchpad.net)"
- indexed-packages-fp:
- type: string
- default:
- description: "Filepath for json file with index of packages from database"
- public-swift-creds:
- type: string
- default:
- description: "creds for openstack swift storage for updating github jobs"
- allowed-requestor-teams:
- type: string
- default: ~
- description: "List of teams that are allowed to request autopkgtest tests."
- influxdb-hostname:
- default: ~
- description: The hostname of the remote influxdb to submit metrics to
- type: string
- influxdb-port:
- default: 8086
- description: The port of the remote influxdb to submit metrics to
- type: int
- influxdb-username:
- default: ~
- description: The influxdb username
- type: string
- influxdb-password:
- default: ~
- description: The influxdb password
- type: string
- influxdb-database:
- default: ~
- description: The influxdb database to use
- type: string
- influxdb-context:
- default: "production"
- description: Submit all metrics with this as the "context" tag,
- to differentiate staging vs. production submissions
- type: string
diff --git a/charms/focal/autopkgtest-web/metadata.yaml b/charms/focal/autopkgtest-web/metadata.yaml
deleted file mode 100644
index 7c18e8b..0000000
--- a/charms/focal/autopkgtest-web/metadata.yaml
+++ /dev/null
@@ -1,18 +0,0 @@
-name: autopkgtest-web
-summary: autopkgtest web frontend with results from Swift
-series:
- - focal
-maintainer: Brian Murray <brian.murray@xxxxxxxxxxxxx>
-description: |
- This regularly downloads new autopkgtest results from Swift and makes them
- browsable through a web server.
-tags:
- - web_server
- - monitoring
-subordinate: true
-requires:
- amqp:
- interface: rabbitmq
- website:
- interface: apache-website
- scope: container
References