You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficcontrol.apache.org by GitBox <gi...@apache.org> on 2021/04/01 22:35:55 UTC
[GitHub] [trafficcontrol] jrushford opened a new pull request #5706: Add an ORT integration tests GHA workflow
jrushford opened a new pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706
## What does this PR (Pull Request) do?
Adds a Github Actions workflow to automatically run the ORT Integration
tests when a change is pushed or a PR is created for code used by ORT.
- [x] This PR fixes #5555 Should have a GitHub Action to run the ORT integration test
## Which Traffic Control components are affected by this PR?
- Traffic Ops ORT
## What is the best way to verify this PR?
You can manually trigger the workflow to run the integration tests by going [HERE](https://github.com/jrushford/trafficcontrol/actions/workflows/traffic-ops-ort-tests.yml) and selecting the most recent
workflow. Then hit the button to Re-run jobs and monitor the four job logs, traffic_ops, traffic_ops_ort, trafficserver, and
finally ORT_tests.
You may clone the branch, push it to your GitHub and submit changes to trigger the workflow as well.
## If this is a bug fix, what versions of Traffic Control are affected?
This PR is not a bug fix.
## The following criteria are ALL met by this PR
- [X] This PR includes tests OR I have explained why tests are unnecessary
- [X] This PR includes documentation OR I have explained why documentation is unnecessary
- [ ] This PR includes an update to CHANGELOG.md OR such an update is not necessary
- [X] This PR includes any and all required license headers
- [X] This PR **DOES NOT FIX A SERIOUS SECURITY VULNERABILITY** (see [the Apache Software Foundation's security guidelines](https://www.apache.org/security/) for details)
## Additional Information
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610052569
##########
File path: .github/actions/to-ort-integration-tests/main.js
##########
@@ -0,0 +1,35 @@
+/*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+"use strict";
+const child_process = require("child_process");
+const spawnOptions = {
+ stdio: "inherit",
+ stderr: "inherit",
+};
+
+const dockerCompose = ["docker-compose", "-f", `${process.env.GITHUB_WORKSPACE}/traffic_ops_ort/testing/docker/docker-compose.yml`];
+
+function runProcess(...commandArguments) {
+ console.info(...commandArguments);
+ const status = child_process.spawnSync(commandArguments[0], commandArguments.slice(1), spawnOptions).status;
+ if (status === 0) {
+ return;
+ }
+ console.error("Child process \"", ...commandArguments, "\" exited with status code", status, "!");
+ process.exit(status ? status : 1);
+}
+
+runProcess(...dockerCompose, "build");
Review comment:
@zrhoffman good idea, I've made the change.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r609949112
##########
File path: .github/actions/to-ort-integration-tests/main.js
##########
@@ -0,0 +1,35 @@
+/*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+"use strict";
+const child_process = require("child_process");
+const spawnOptions = {
+ stdio: "inherit",
+ stderr: "inherit",
+};
+
+const dockerCompose = ["docker-compose", "-f", `${process.env.GITHUB_WORKSPACE}/traffic_ops_ort/testing/docker/docker-compose.yml`];
+
+function runProcess(...commandArguments) {
+ console.info(...commandArguments);
+ const status = child_process.spawnSync(commandArguments[0], commandArguments.slice(1), spawnOptions).status;
+ if (status === 0) {
+ return;
+ }
+ console.error("Child process \"", ...commandArguments, "\" exited with status code", status, "!");
+ process.exit(status ? status : 1);
+}
+
+runProcess(...dockerCompose, "build");
Review comment:
If this is changed from `docker-compose build` to `docker-compose build --parallel`, the images will build way faster.
##########
File path: .github/actions/to-ort-integration-tests/main.js
##########
@@ -0,0 +1,35 @@
+/*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+"use strict";
+const child_process = require("child_process");
+const spawnOptions = {
+ stdio: "inherit",
+ stderr: "inherit",
+};
+
+const dockerCompose = ["docker-compose", "-f", `${process.env.GITHUB_WORKSPACE}/traffic_ops_ort/testing/docker/docker-compose.yml`];
+
+function runProcess(...commandArguments) {
+ console.info(...commandArguments);
+ const status = child_process.spawnSync(commandArguments[0], commandArguments.slice(1), spawnOptions).status;
+ if (status === 0) {
+ return;
+ }
+ console.error("Child process \"", ...commandArguments, "\" exited with status code", status, "!");
+ process.exit(status ? status : 1);
+}
+
+runProcess(...dockerCompose, "build");
Review comment:
If the Docker images build in a step separate from the step that runs the ORT integration tests, it would be much easier to see the output for the tests themselves.
The build step could be pretty small, just
```yaml
- run: docker-compose -f traffic_ops_ort/testing/docker/docker-compose.yml build
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610060381
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,153 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
Review comment:
Good catch @zrhoffman , I forgot about those. Changes made.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r607902166
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
@zrhoffman ok, will update it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r607598107
##########
File path: traffic_ops_ort/testing/docker/trafficserver/run.sh
##########
@@ -0,0 +1,78 @@
+#!/bin/bash
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+function initBuildArea() {
+ cd /root
+
+ # prep build environment
+ [ -e rpmbuild ] && rm -rf rpmbuild
+ [ ! -e rpmbuild ] || { echo "Failed to clean up rpm build directory 'rpmbuild': $?" >&2; exit 1; }
+ mkdir -p rpmbuild/{BUILD,BUILDROOT,RPMS,SPECS,SOURCES,SRPMS} || { echo "Failed to create build directory '$RPMBUILD': $?" >&2;
+ exit 1; }
+}
+
+case ${ATS_VERSION:0:1} in
+ 8) cp /trafficserver-8.spec /trafficserver.spec
+ ;;
+ 9) cp /trafficserver-9.spec /trafficserver.spec
+ ;;
+ *) echo "Unknown trafficserver version was specified"
+ exit 1
+ ;;
+esac
+
+echo "Building a RPM for ATS version: $ATS_VERSION"
+
+# add the 'ats' user
+id ats &>/dev/null || /usr/sbin/useradd -u 176 -r ats -s /sbin/nologin -d /
+
+# setup the environment to use the devtoolset-9 tools.
+source scl_source enable devtoolset-9
+
+initBuildArea
+
+cd /root/rpmbuild/SOURCES
+# clone the trafficserver repo
+git clone https://github.com/apache/trafficserver.git
+
+# build trafficserver version 9
+rm -f /root/rpmbuild/RPMS/x86_64/trafficserver-*.rpm
+cd trafficserver
+git fetch --all
+git checkout $ATS_VERSION
+rpmbuild -bb /trafficserver.spec
+
+echo "Build completed"
+
+if [[ ! -d /trafficcontrol/dist ]]; then
+ mkdir /trafficcontrol/dist
+fi
+
+case ${ATS_VERSION:0:1} in
+ 8) cp /root/rpmbuild/RPMS/x86_64/trafficserver-8*.rpm /trafficcontrol/dist
+ ;;
+ 9) cp /root/rpmbuild/RPMS/x86_64/trafficserver-8*.rpm /trafficcontrol/dist
Review comment:
> `trafficserver-8*.rpm`
Should this be `trafficserver-9`?
##########
File path: traffic_ops_ort/testing/docker/trafficserver/trafficserver-8.spec
##########
@@ -0,0 +1,145 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+# SPDX-License-Identifier: Apache-2.0
+#
+%global src %{_topdir}/SOURCES/trafficserver
+%global git_args --git-dir="%{src}/.git" --work-tree="%{src}"
+%global git_tag %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\1/' | sed 's/-/_/')
+%global distance %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\2/')
+%global commit %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\3/')
Review comment:
These regexes are a little hard to read with all of the backslashes. If these lines used `sed -E` instead of `sed`, most of the backslashes could be removed.
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
The `traffic-ops-ort-tests.yml` workflow should also be triggered when files in the `to-ort-integration-tests` action are modified.
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
Path should be `.github/workflows/traffic-ops-ort-tests.yml`
##########
File path: traffic_ops_ort/testing/docker/trafficserver/trafficserver-9.spec
##########
@@ -0,0 +1,147 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+# SPDX-License-Identifier: Apache-2.0
+
+%global src %{_topdir}/SOURCES/trafficserver
+%global git_args --git-dir="%{src}/.git" --work-tree="%{src}"
+%global git_tag %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\1/' | sed 's/-/_/')
+%global distance %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\2/')
+%global commit %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\3/')
Review comment:
Same as above, consider using `sed -E` to reduce backslashes and increase readability.
##########
File path: .github/actions/build-ats-test-rpm/action.yaml
##########
@@ -0,0 +1,22 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: 'build-ats-test-rpm'
+description: 'Builds an ATS RPM used for ORT Integration tests.'
+runs:
+ using: 'node12'
+ main: 'main.js'
Review comment:
In addition to Docker actions and JavaScript actions, GHA now supports [composite run steps](https://docs.github.com/en/actions/creating-actions/creating-a-composite-run-steps-action#creating-an-action-metadata-file) actions (which were [not around](https://github.blog/changelog/2020-08-07-github-actions-composite-run-steps/) when we started migrating to GitHub Actions). So the JavaScript action that you have already is fine as far as I'm concerned, but if you want to do a composite run steps action, that option is out there, too.
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ types: [opened, reopened, ready_for_review, synchronize]
+
+jobs:
+
+ traffic_ops:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build RPM
+ uses: ./.github/actions/build-rpms
+ env:
+ ATC_COMPONENT: ${{ github.job }}
+ - name: Upload RPM
+ uses: actions/upload-artifact@v2
+ with:
+ name: ${{ github.job }}
+ path: ${{ github.workspace }}/dist/${{ github.job }}-*.x86_64.rpm
+
+ traffic_ops_ort:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build RPM
+ uses: ./.github/actions/build-rpms
+ env:
+ ATC_COMPONENT: ${{ github.job }}
+ - name: Upload RPM
+ uses: actions/upload-artifact@v2
+ with:
+ name: ${{ github.job }}
+ path: ${{ github.workspace }}/dist/${{ github.job }}-*.x86_64.rpm
+
+ trafficserver:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build ATS RPM
+ uses: ./.github/actions/build-ats-test-rpm
+ env:
+ ATC_COMPONENT: ${{ github.job }}
Review comment:
The `trafficserver` RPM takes 11m20s to build, about 10 minutes longer than the `traffic_ops` or `traffic_ops_ort` RPMs do. Can we cache the `trafficserver` RPM and only build on a cache miss?
The cache key should include the hash of the commit the RPM was built from. With some text manipulation, the latest 8.1.x or 9.1.x commit can be found from https://github.com/apache/trafficserver/info/refs?service=git-upload-pack.
A shell command can get that commit hash, then that step can make the result available [as an output](https://docs.github.com/en/actions/reference/workflow-commands-for-github-actions#using-workflow-commands-to-access-toolkit-functions) for use in a later step. Here is the `go.vet.yml` workflow setting and using an output:
https://github.com/apache/trafficcontrol/blob/b31db78965ee66dd5abea1508f732bdc42cafe0c/.github/workflows/go.vet.yml#L43-L47
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
The path should be `.github/workflows/traffic-ops-ort-tests.yml` here, too
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] ocket8888 merged pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
ocket8888 merged pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r608142272
##########
File path: traffic_ops_ort/testing/docker/trafficserver/trafficserver-8.spec
##########
@@ -0,0 +1,145 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+# SPDX-License-Identifier: Apache-2.0
+#
+%global src %{_topdir}/SOURCES/trafficserver
+%global git_args --git-dir="%{src}/.git" --work-tree="%{src}"
+%global git_tag %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\1/' | sed 's/-/_/')
+%global distance %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\2/')
+%global commit %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\3/')
Review comment:
Consistency makes sense, sounds fine to me.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610063771
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
yup, fixed this too @zrhoffman
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610178573
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,153 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
Review comment:
Sure the TO clients are used in ORT. I think @ocket8888 is talking specifically about
```yaml
- traffic_ops/testing/api/**.go
```
because no package within `github.com/apache/trafficcontrol/traffic_ops/testing/api` is used by ORT as far as I can tell.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610015422
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,153 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
Review comment:
The other actions should be added to the list of paths that trigger this workflow, as well:
```yaml
- .github/actions/build-ats-test-rpm
- .github/actions/fetch-github-branch-sha
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610015422
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,153 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
Review comment:
The other actions should be listed to the list of paths that trigger this workflow, as well:
```yaml
- .github/actions/build-ats-test-rpm
- .github/actions/fetch-github-branch-sha
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] ocket8888 commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r606355909
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
Review comment:
I don't think a change to only the API _tests_ would necessitate running this action, would it?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610183465
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,153 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
Review comment:
@zrhoffman my mistake. I was looking at the wrong path, it's been a long day :). I just pushed the change.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610142233
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
Paths are still missing `.github/actions/to-ort-integration-tests`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610063331
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
oops, I've made the change @zrhoffman
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610051757
##########
File path: .github/actions/to-ort-integration-tests/main.js
##########
@@ -0,0 +1,35 @@
+/*
+* Licensed under the Apache License, Version 2.0 (the "License");
+* you may not use this file except in compliance with the License.
+* You may obtain a copy of the License at
+*
+* http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+*/
+
+"use strict";
+const child_process = require("child_process");
+const spawnOptions = {
+ stdio: "inherit",
+ stderr: "inherit",
+};
+
+const dockerCompose = ["docker-compose", "-f", `${process.env.GITHUB_WORKSPACE}/traffic_ops_ort/testing/docker/docker-compose.yml`];
+
+function runProcess(...commandArguments) {
+ console.info(...commandArguments);
+ const status = child_process.spawnSync(commandArguments[0], commandArguments.slice(1), spawnOptions).status;
+ if (status === 0) {
+ return;
+ }
+ console.error("Child process \"", ...commandArguments, "\" exited with status code", status, "!");
+ process.exit(status ? status : 1);
+}
+
+runProcess(...dockerCompose, "build");
Review comment:
good suggestion @zrhoffman I've made the change.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r608155443
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
@zrhoffman I'll update that.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r608137367
##########
File path: traffic_ops_ort/testing/docker/trafficserver/trafficserver-9.spec
##########
@@ -0,0 +1,147 @@
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+# SPDX-License-Identifier: Apache-2.0
+
+%global src %{_topdir}/SOURCES/trafficserver
+%global git_args --git-dir="%{src}/.git" --work-tree="%{src}"
+%global git_tag %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\1/' | sed 's/-/_/')
+%global distance %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\2/')
+%global commit %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\3/')
Review comment:
@zrhoffman see comment above
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r609942190
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
This path should still be changed to `.github/workflows/traffic-ops-ort-tests.yml`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610011749
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,153 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
Review comment:
@ocket8888 that's intended, the client stuff is used in ORT.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] ocket8888 commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r609900502
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,153 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
Review comment:
this action will still run on changes to the Go client/TO API integration tests on PRs
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r609941118
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
The `.github/actions/to-ort-integration-tests` path should still be added.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r607901464
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
@zrhoffman I'll update that
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r608137234
##########
File path: traffic_ops_ort/testing/docker/trafficserver/trafficserver-8.spec
##########
@@ -0,0 +1,145 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+# SPDX-License-Identifier: Apache-2.0
+#
+%global src %{_topdir}/SOURCES/trafficserver
+%global git_args --git-dir="%{src}/.git" --work-tree="%{src}"
+%global git_tag %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\1/' | sed 's/-/_/')
+%global distance %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\2/')
+%global commit %(git %{git_args} describe --long | sed 's/^\\\(.*\\\)-\\\([0-9]\\\+\\\)-g\\\([0-9a-f]\\\+\\\)$/\\\3/')
Review comment:
@zrhoffman I'd prefer to keep the spec files as they are. These are basically copies of the ones we use to build the production RPM's today and we've been using them for years. if you look in the trafficcontrol code base these two have all the backslashes too, `./traffic_server/_tsb/trafficserver.spec ./traffic_server/spec/trafficserver.spec`. The point is that I'd like to I'd like to keep the SPEC files as nearly identical as the ones we use for production. Is this alright with you?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r609697489
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ types: [opened, reopened, ready_for_review, synchronize]
+
+jobs:
+
+ traffic_ops:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build RPM
+ uses: ./.github/actions/build-rpms
+ env:
+ ATC_COMPONENT: ${{ github.job }}
+ - name: Upload RPM
+ uses: actions/upload-artifact@v2
+ with:
+ name: ${{ github.job }}
+ path: ${{ github.workspace }}/dist/${{ github.job }}-*.x86_64.rpm
+
+ traffic_ops_ort:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build RPM
+ uses: ./.github/actions/build-rpms
+ env:
+ ATC_COMPONENT: ${{ github.job }}
+ - name: Upload RPM
+ uses: actions/upload-artifact@v2
+ with:
+ name: ${{ github.job }}
+ path: ${{ github.workspace }}/dist/${{ github.job }}-*.x86_64.rpm
+
+ trafficserver:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build ATS RPM
+ uses: ./.github/actions/build-ats-test-rpm
+ env:
+ ATC_COMPONENT: ${{ github.job }}
Review comment:
@zrhoffman good suggestion! I've implemented this, caching the trafficserver rpm build between runs using the apache trafficserver branch commit SHA as the cache key. This is working very well and shaves off about 10 minutes from the workflow. I added a new action, .github/actions/fetch-github-branch-sha. It uses the GitHub API to fetch the SHA.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r609697489
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ types: [opened, reopened, ready_for_review, synchronize]
+
+jobs:
+
+ traffic_ops:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build RPM
+ uses: ./.github/actions/build-rpms
+ env:
+ ATC_COMPONENT: ${{ github.job }}
+ - name: Upload RPM
+ uses: actions/upload-artifact@v2
+ with:
+ name: ${{ github.job }}
+ path: ${{ github.workspace }}/dist/${{ github.job }}-*.x86_64.rpm
+
+ traffic_ops_ort:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build RPM
+ uses: ./.github/actions/build-rpms
+ env:
+ ATC_COMPONENT: ${{ github.job }}
+ - name: Upload RPM
+ uses: actions/upload-artifact@v2
+ with:
+ name: ${{ github.job }}
+ path: ${{ github.workspace }}/dist/${{ github.job }}-*.x86_64.rpm
+
+ trafficserver:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build ATS RPM
+ uses: ./.github/actions/build-ats-test-rpm
+ env:
+ ATC_COMPONENT: ${{ github.job }}
Review comment:
@zrhoffman good suggestion! I've implemented this, caching the trafficserver rpm build between runs using the apache trafficserver branch commit SHA as the cache key. This is working very well and shaves off about 10 minutes from the workflow when there is a cache hit. I added a new action, .github/actions/fetch-github-branch-sha. It uses the GitHub API to fetch the SHA.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r610172695
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
@zrhoffman oops, thought I had that in there. I just fixed it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r609957677
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ create:
+ pull_request:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
+ - traffic_ops/traffic_ops_golang/**.go
+ - traffic_ops_ort/**.go
+ - vendor/**.go
+ - vendor/modules.txt
+ types: [opened, reopened, ready_for_review, synchronize]
+
+jobs:
+
+ traffic_ops:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build RPM
+ uses: ./.github/actions/build-rpms
+ env:
+ ATC_COMPONENT: ${{ github.job }}
+ - name: Upload RPM
+ uses: actions/upload-artifact@v2
+ with:
+ name: ${{ github.job }}
+ path: ${{ github.workspace }}/dist/${{ github.job }}-*.x86_64.rpm
+
+ traffic_ops_ort:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build RPM
+ uses: ./.github/actions/build-rpms
+ env:
+ ATC_COMPONENT: ${{ github.job }}
+ - name: Upload RPM
+ uses: actions/upload-artifact@v2
+ with:
+ name: ${{ github.job }}
+ path: ${{ github.workspace }}/dist/${{ github.job }}-*.x86_64.rpm
+
+ trafficserver:
+ if: github.event.pull_request.draft == false
+ runs-on: ubuntu-latest
+ steps:
+ - name: Checkout
+ uses: actions/checkout@v2
+ - name: Build ATS RPM
+ uses: ./.github/actions/build-ats-test-rpm
+ env:
+ ATC_COMPONENT: ${{ github.job }}
Review comment:
Awesome, that's a huge timesave.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r609941118
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
The `.github/actions/to-ort-integration-tests` should still be added.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r606372399
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
+ - go.mod
+ - go.sum
+ - GO_VERSION
+ - traffic_ops/*client/**.go
+ - traffic_ops/testing/api/**.go
Review comment:
You're right, I'll remove that.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r607900228
##########
File path: traffic_ops_ort/testing/docker/trafficserver/run.sh
##########
@@ -0,0 +1,78 @@
+#!/bin/bash
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+function initBuildArea() {
+ cd /root
+
+ # prep build environment
+ [ -e rpmbuild ] && rm -rf rpmbuild
+ [ ! -e rpmbuild ] || { echo "Failed to clean up rpm build directory 'rpmbuild': $?" >&2; exit 1; }
+ mkdir -p rpmbuild/{BUILD,BUILDROOT,RPMS,SPECS,SOURCES,SRPMS} || { echo "Failed to create build directory '$RPMBUILD': $?" >&2;
+ exit 1; }
+}
+
+case ${ATS_VERSION:0:1} in
+ 8) cp /trafficserver-8.spec /trafficserver.spec
+ ;;
+ 9) cp /trafficserver-9.spec /trafficserver.spec
+ ;;
+ *) echo "Unknown trafficserver version was specified"
+ exit 1
+ ;;
+esac
+
+echo "Building a RPM for ATS version: $ATS_VERSION"
+
+# add the 'ats' user
+id ats &>/dev/null || /usr/sbin/useradd -u 176 -r ats -s /sbin/nologin -d /
+
+# setup the environment to use the devtoolset-9 tools.
+source scl_source enable devtoolset-9
+
+initBuildArea
+
+cd /root/rpmbuild/SOURCES
+# clone the trafficserver repo
+git clone https://github.com/apache/trafficserver.git
+
+# build trafficserver version 9
+rm -f /root/rpmbuild/RPMS/x86_64/trafficserver-*.rpm
+cd trafficserver
+git fetch --all
+git checkout $ATS_VERSION
+rpmbuild -bb /trafficserver.spec
+
+echo "Build completed"
+
+if [[ ! -d /trafficcontrol/dist ]]; then
+ mkdir /trafficcontrol/dist
+fi
+
+case ${ATS_VERSION:0:1} in
+ 8) cp /root/rpmbuild/RPMS/x86_64/trafficserver-8*.rpm /trafficcontrol/dist
+ ;;
+ 9) cp /root/rpmbuild/RPMS/x86_64/trafficserver-8*.rpm /trafficcontrol/dist
Review comment:
No, production is all trafficserver-8 at them moment. Will switch to 9 when it's appropriate.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] jrushford commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
jrushford commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r607900228
##########
File path: traffic_ops_ort/testing/docker/trafficserver/run.sh
##########
@@ -0,0 +1,78 @@
+#!/bin/bash
+#
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+#
+
+function initBuildArea() {
+ cd /root
+
+ # prep build environment
+ [ -e rpmbuild ] && rm -rf rpmbuild
+ [ ! -e rpmbuild ] || { echo "Failed to clean up rpm build directory 'rpmbuild': $?" >&2; exit 1; }
+ mkdir -p rpmbuild/{BUILD,BUILDROOT,RPMS,SPECS,SOURCES,SRPMS} || { echo "Failed to create build directory '$RPMBUILD': $?" >&2;
+ exit 1; }
+}
+
+case ${ATS_VERSION:0:1} in
+ 8) cp /trafficserver-8.spec /trafficserver.spec
+ ;;
+ 9) cp /trafficserver-9.spec /trafficserver.spec
+ ;;
+ *) echo "Unknown trafficserver version was specified"
+ exit 1
+ ;;
+esac
+
+echo "Building a RPM for ATS version: $ATS_VERSION"
+
+# add the 'ats' user
+id ats &>/dev/null || /usr/sbin/useradd -u 176 -r ats -s /sbin/nologin -d /
+
+# setup the environment to use the devtoolset-9 tools.
+source scl_source enable devtoolset-9
+
+initBuildArea
+
+cd /root/rpmbuild/SOURCES
+# clone the trafficserver repo
+git clone https://github.com/apache/trafficserver.git
+
+# build trafficserver version 9
+rm -f /root/rpmbuild/RPMS/x86_64/trafficserver-*.rpm
+cd trafficserver
+git fetch --all
+git checkout $ATS_VERSION
+rpmbuild -bb /trafficserver.spec
+
+echo "Build completed"
+
+if [[ ! -d /trafficcontrol/dist ]]; then
+ mkdir /trafficcontrol/dist
+fi
+
+case ${ATS_VERSION:0:1} in
+ 8) cp /root/rpmbuild/RPMS/x86_64/trafficserver-8*.rpm /trafficcontrol/dist
+ ;;
+ 9) cp /root/rpmbuild/RPMS/x86_64/trafficserver-8*.rpm /trafficcontrol/dist
Review comment:
@zrhoffman No, production is all trafficserver-8 at them moment. Will switch to 9 when it's appropriate.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] zrhoffman commented on a change in pull request #5706: Add an ORT integration tests GHA workflow
Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #5706:
URL: https://github.com/apache/trafficcontrol/pull/5706#discussion_r609941501
##########
File path: .github/workflows/traffic-ops-ort-tests.yml
##########
@@ -0,0 +1,140 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Traffic Ops ORT integration tests
+
+on:
+ push:
+ workflow_dispatch:
+ paths:
+ - .github/actions/todb-init/**
+ - .github/workflows/traffic-ops-ort.yml
Review comment:
This path should still be `.github/workflows/traffic-ops-ort-tests.yml`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org