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 2020/08/14 18:41:18 UTC

[GitHub] [trafficcontrol] ocket8888 opened a new pull request #4959: Traffic Ops integration tests

ocket8888 opened a new pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959


   ## What does this PR (Pull Request) do?
   - [x] This PR is not related to any Issue
   
   This PR adds running the API tests to Pull Requests, any time a source file for Traffic Ops, one of its Go clients, or the Go client/API integration tests changes.
   
   ## Which Traffic Control components are affected by this PR?
   None.
   
   ## What is the best way to verify this PR?
   Observe the test output.
   
   ## The following criteria are ALL met by this PR
   - [x] This PR includes tests
   - [x] Documentation is unnecessary
   - [x] An update to CHANGELOG.md is not necessary
   - [x] This PR includes any and all required license headers
   - [x] This PR does not include a database migration
   - [x] This PR **DOES NOT FIX A SERIOUS SECURITY VULNERABILITY**


----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470841337



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
+CgKCAQEA1OsuQ71qaSZ4ivGnh4YryeQEHMn5wZLX7kWYB637ssyOJnkU1ZGs93JM
+XJADzsjmssP6icSDhV2JPgDDYzx1eBJt6y3vHI7L3AdGfQJj+4FFABKR8moqpc1J
+WIMGnPzO6DeEc8irf0qxSh+yvuFX0j6oS8oCqiRxz5+HL2wEGWmrgr37JY4/bs7o
+4CMY19Ru1dP2F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aM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}
+EOF
+
+cat <<-EOF >database.conf
+{
+	"description": "Local PostgreSQL database on port 5432",
+	"dbname": "traffic_ops",
+	"hostname": "postgres",
+	"user": "traffic_ops",
+	"password": "twelve",
+	"port": "5432",
+	"ssl": false,
+	"type": "Pg"
+}

Review comment:
       Either way. Although, `jq` as an added dependency is only 1072 kB on top of `golang:1.14.2-buster`.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470846403



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
+CgKCAQEA1OsuQ71qaSZ4ivGnh4YryeQEHMn5wZLX7kWYB637ssyOJnkU1ZGs93JM
+XJADzsjmssP6icSDhV2JPgDDYzx1eBJt6y3vHI7L3AdGfQJj+4FFABKR8moqpc1J
+WIMGnPzO6DeEc8irf0qxSh+yvuFX0j6oS8oCqiRxz5+HL2wEGWmrgr37JY4/bs7o
+4CMY19Ru1dP2Fr292HEIqCEnLTOuaHSWAEWx1Tm93kT9sXbw/SG2JTLQSX80biFL
+7foJeoGWLls2reTCYTprzWFaMu3x9I8HLtf4VIN44rtvo5N20KYgjGqvPjFGPljL
+yrgB8rXSCpH3M4AbazxD8fZKbdORawIDAQABo4GnMIGkMB0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bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}

Review comment:
       but my delicate sensibilities...




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r471869971



##########
File path: .github/actions/to-integration-tests/Dockerfile
##########
@@ -15,9 +15,11 @@
 # specific language governing permissions and limitations
 # under the License.
 
-FROM golang:1.14.2-alpine
+FROM golang:1.14.2-buster

Review comment:
       If we're pinning to under-patched go versions for stability, then I don't know if we should change how it's building.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470839388



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
+CgKCAQEA1OsuQ71qaSZ4ivGnh4YryeQEHMn5wZLX7kWYB637ssyOJnkU1ZGs93JM
+XJADzsjmssP6icSDhV2JPgDDYzx1eBJt6y3vHI7L3AdGfQJj+4FFABKR8moqpc1J
+WIMGnPzO6DeEc8irf0qxSh+yvuFX0j6oS8oCqiRxz5+HL2wEGWmrgr37JY4/bs7o
+4CMY19Ru1dP2Fr292HEIqCEnLTOuaHSWAEWx1Tm93kT9sXbw/SG2JTLQSX80biFL
+7foJeoGWLls2reTCYTprzWFaMu3x9I8HLtf4VIN44rtvo5N20KYgjGqvPjFGPljL
+yrgB8rXSCpH3M4AbazxD8fZKbdORawIDAQABo4GnMIGkMB0GA1UdDgQWBBT6zEpf
+DYbYCI3Bu82+Q5SmI+/7ojB1BgNVHSMEbjBsgBT6zEpfDYbYCI3Bu82+Q5SmI+/7
+oqFJpEcwRTELMAkGA1UEBhMCQVUxEzARBgNVBAgTClNvbWUtU3RhdGUxITAfBgNV
+BAoTGEludGVybmV0IFdpZGdpdHMgUHR5IEx0ZIIJAJgQuE9T48+gMAwGA1UdEwQF
+MAMBAf8wDQYJKoZIhvcNAQEFBQADggEBAGLs1NcYNtUgN6FuMb6/UskEWLTKwfno
+NBtNdIbcZP3HmJHwruLWCeqj6HIWJC87EqmPTIYPdem3SAN1L20fWpzm7AB7av+2
+wTCAPVP0punF/IouSb6fyo8fdG1a104Mge4iy/Sf2uf09NEv08sfVdB4P0tKRRlg
+5KChhmspdPP7fmPXyghm4IC0Seknmh6IlVOnALXLU5OoCLHTie5Hjv4Tm8Xu0oBA
+dIH/cPu2/w5SAIVq9CtcsdglS0ZsCAv4W2YieuSLPf5xuI0q/5lFZGNoDpIWJldx
+Y2IpnoNCrHEAxijP5ctPawsxkSt2PmQ5uNNL7TbMudc3hZzOpTPkGoo=
+-----END CERTIFICATE-----

Review comment:
       Because that's another dependency, and also because I tried to do that a couple of times, didn't get it to work immediately, threw my hands up and used a static one I had lying around instead. It doesn't matter how invalid the cert/key pair is as long as it can be used to encode/decode HTTPS traffic, since everything's being run with InsecureSkipVerify anyway.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470848827



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdG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+MTnHaoCHbYBkrGTlGviu5Fl2V5EbrN7R7CdxJeem
+HOU4shTy1acMPgf8sT17ykkXhVeUhSK2Jg6fZn6HAoGAI4/51SeE4htuKwMyhTRN
+SOFcFBlBIE1ieRBr9lx4Ln7+xCMbEog/hM7z9z8gxd35Vv4YqoxQrZpWOHCw2NIf
+CqX3V5vubhe6WcY4bY5MttM/yLvwPKUZeng57PDqucV9zzkuoKfiCdXCcRpaGDEp
+okOooghj4ip204WDg6NTDZkCgYEAwZTfzsGLgmF1kRBIoZqmt1zeUcQxHfhKx32Y
+BaM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}

Review comment:
       Or `$PWD` could be set using `jq --arg`




----------------------------------------------------------------
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 pull request #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#issuecomment-674930570


   If they're separate steps, v2 and v3 tests won't run if the preceding step - v1 tests - fails. If they're separate jobs then we duplicate a lot of work, which can cause it to slow down because it's waiting for executors. I think a better solution would be to use the reporting API to provide detailed error descriptions.


----------------------------------------------------------------
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 pull request #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#issuecomment-674350947


   How hard would it be to get junit reports for v1, v2, and v3 as artifacts?


----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470839978



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE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GvRcSJNy4/kEEFECJXkeO
+mV/aklCi39cxAaIjVdTQ1XN67RMxgdekCI2Eg8h4RdvwgB/tAO+C3ExzMSOA1IcZ
+tWuwIA2YnaFF9Sla9iJqxgtoGlaqm4VTUM/IdZqlzsP08pfNq7bXPsr9AoGBANgk
+tkovf1Y0O4lBHX3eVLnHXForxEZh8bGHwuJJWWzb0ZFcXrrSd8FSycZrR28v4sdQ
+WSSVPz3Op95HoTVXVL9EJcZ+MTnHaoCHbYBkrGTlGviu5Fl2V5EbrN7R7CdxJeem
+HOU4shTy1acMPgf8sT17ykkXhVeUhSK2Jg6fZn6HAoGAI4/51SeE4htuKwMyhTRN
+SOFcFBlBIE1ieRBr9lx4Ln7+xCMbEog/hM7z9z8gxd35Vv4YqoxQrZpWOHCw2NIf
+CqX3V5vubhe6WcY4bY5MttM/yLvwPKUZeng57PDqucV9zzkuoKfiCdXCcRpaGDEp
+okOooghj4ip204WDg6NTDZkCgYEAwZTfzsGLgmF1kRBIoZqmt1zeUcQxHfhKx32Y
+BaM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}
+EOF
+
+cat <<-EOF >database.conf
+{
+	"description": "Local PostgreSQL database on port 5432",
+	"dbname": "traffic_ops",
+	"hostname": "postgres",
+	"user": "traffic_ops",
+	"password": "twelve",
+	"port": "5432",
+	"ssl": false,
+	"type": "Pg"
+}
+EOF
+
+./traffic_ops_golang --cfg ./cdn.conf --dbcfg ./database.conf >out.log 2>err.log &
+
+cd ../testing/api/v1
+
+makeCFG() {
+	cat <<-EOF >traffic-ops-test.conf
+	{
+		"default": {
+			"logLocations": {
+				"debug": "stderr",
+				"error": "stderr",
+				"event": "stderr",
+				"info": "stderr",
+				"warning": "stderr"
+			},
+			"session": {
+				"timeoutInSecs": 60
+			}
+		},
+		"trafficOps": {
+			"URL": "https://localhost:6443",
+			"password": "twelve",
+			"users": {
+				"disallowed": "disallowed",
+				"operations": "operations",
+				"admin": "admin",
+				"federation": "federation",
+				"portal": "portal",
+				"readOnly": "readOnly",
+				"extension": "extension"
+			}
+		},
+		"trafficOpsDB": {
+			"dbname": "traffic_ops",
+			"description": "Test database to_test",
+			"hostname": "postgres",
+			"password": "twelve",
+			"port": "5432",
+			"type": "Pg",
+			"user": "traffic_ops"
+		},
+		"noPerl": true,
+		"noISO": true
+	}
+	EOF
+}
+
+CODE="0"
+
+makeCFG
+/usr/local/go/bin/go test -v --cfg ./traffic-ops-test.conf
+if [ "$?" -gt "0" ]; then
+	CODE="1"
+fi
+rm traffic-ops-test.conf
+
+cd ../v2
+makeCFG
+ /usr/local/go/bin/go test -v --cfg ./traffic-ops-test.conf

Review comment:
       I don't know why, but I have had no end of trouble trying to pass anything outside of PWD as the configuration file to those tests. This is actually how I run it locally; I have a separate configuration for each test set, even though they're all the same.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470839813



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
+CgKCAQEA1OsuQ71qaSZ4ivGnh4YryeQEHMn5wZLX7kWYB637ssyOJnkU1ZGs93JM
+XJADzsjmssP6icSDhV2JPgDDYzx1eBJt6y3vHI7L3AdGfQJj+4FFABKR8moqpc1J
+WIMGnPzO6DeEc8irf0qxSh+yvuFX0j6oS8oCqiRxz5+HL2w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LgmF1kRBIoZqmt1zeUcQxHfhKx32Y
+BaM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}

Review comment:
       `envsubst` is pretty lightweight




----------------------------------------------------------------
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 pull request #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#issuecomment-674933086


   > If they're separate steps, v2 and v3 tests won't run if the preceding step - v1 tests - fails.
   
   By default, sure, but [`if: ${{ always() }}`](https://docs.github.com/en/actions/reference/context-and-expression-syntax-for-github-actions#always) covers that case, right?


----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470847884



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml

Review comment:
       Yep, as long as inline YAML isn't tucked away inside a bash script




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r471877140



##########
File path: .github/actions/to-integration-tests/Dockerfile
##########
@@ -15,9 +15,11 @@
 # specific language governing permissions and limitations
 # under the License.
 
-FROM golang:1.14.2-alpine
+FROM golang:1.14.2-buster

Review comment:
       This too builds on Alpine if the `musl-dev` package is installed. FWIW, all of the Go ATC components have been built with the [`osusergo`](https://golang.org/doc/go1.11#os/user) and [`netgo`](https://golang.org/doc/go1.5#net) tags ([example](https://github.com/apache/trafficcontrol/pull/4758/files#diff-d57f2a7a8ff4abbc35eef295ce11d1d9R60)) for static linking since #4758, which effectively disables cgo.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r471870056



##########
File path: .github/workflows/traffic ops.yml
##########
@@ -51,18 +51,19 @@ jobs:
     - name: Checkout
       uses: actions/checkout@master
     - name: Initialize Traffic Ops Database
+      id: todb
       uses: ./.github/actions/todb-init
     - name: Run API v1 tests
       uses: ./.github/actions/to-integration-tests
       with:
         version: 1
     - name: Run API v2 tests
-      if: ${{ always() }}
+      if: ${{ steps.todb.outcome == 'success' }}
       uses: ./.github/actions/to-integration-tests
       with:
         version: 2
     - name: Run API v3 tests
-      if: ${{ always() }}
+      if: ${{ steps.todb.outcome == 'success' }}

Review comment:
       that's super weird, but I'll do 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] ocket8888 commented on pull request #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#issuecomment-674462162


   Probably not too hard. But I don't know how yet.


----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r471883672



##########
File path: .github/actions/to-integration-tests/Dockerfile
##########
@@ -15,9 +15,11 @@
 # specific language governing permissions and limitations
 # under the License.
 
-FROM golang:1.14.2-alpine
+FROM golang:1.14.2-buster

Review comment:
       oh really? I didn't realize, I thought all Go components were built with CGo. I'll definitely look into that, then. I just sort of panicked when I saw "There's no such thing as stdio.h" because generally that means something is very, very wrong. But in the context of Alpine or it actually makes sense to not include the std lib even though you have a compiler. The whole point is to be extremely specific about what winds up in the resulting system.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470846655



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml

Review comment:
       couldn't this just be a file like the JSON files?




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470840227



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEh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FICATE-----

Review comment:
       Ok, that can be improved later.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470842082



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+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zEl7Dj3Vi7WXr
+jsRZC4dxAoGBAPwuPdtc9gSNKjn8RnqfEJjdSo1qdLbGvRcSJNy4/kEEFECJXkeO
+mV/aklCi39cxAaIjVdTQ1XN67RMxgdekCI2Eg8h4RdvwgB/tAO+C3ExzMSOA1IcZ
+tWuwIA2YnaFF9Sla9iJqxgtoGlaqm4VTUM/IdZqlzsP08pfNq7bXPsr9AoGBANgk
+tkovf1Y0O4lBHX3eVLnHXForxEZh8bGHwuJJWWzb0ZFcXrrSd8FSycZrR28v4sdQ
+WSSVPz3Op95HoTVXVL9EJcZ+MTnHaoCHbYBkrGTlGviu5Fl2V5EbrN7R7CdxJeem
+HOU4shTy1acMPgf8sT17ykkXhVeUhSK2Jg6fZn6HAoGAI4/51SeE4htuKwMyhTRN
+SOFcFBlBIE1ieRBr9lx4Ln7+xCMbEog/hM7z9z8gxd35Vv4YqoxQrZpWOHCw2NIf
+CqX3V5vubhe6WcY4bY5MttM/yLvwPKUZeng57PDqucV9zzkuoKfiCdXCcRpaGDEp
+okOooghj4ip204WDg6NTDZkCgYEAwZTfzsGLgmF1kRBIoZqmt1zeUcQxHfhKx32Y
+BaM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}
+EOF
+
+cat <<-EOF >database.conf
+{
+	"description": "Local PostgreSQL database on port 5432",
+	"dbname": "traffic_ops",
+	"hostname": "postgres",
+	"user": "traffic_ops",
+	"password": "twelve",
+	"port": "5432",
+	"ssl": false,
+	"type": "Pg"
+}
+EOF
+
+./traffic_ops_golang --cfg ./cdn.conf --dbcfg ./database.conf >out.log 2>err.log &
+
+cd ../testing/api/v1
+
+makeCFG() {
+	cat <<-EOF >traffic-ops-test.conf
+	{
+		"default": {
+			"logLocations": {
+				"debug": "stderr",
+				"error": "stderr",
+				"event": "stderr",
+				"info": "stderr",
+				"warning": "stderr"
+			},
+			"session": {
+				"timeoutInSecs": 60
+			}
+		},
+		"trafficOps": {
+			"URL": "https://localhost:6443",
+			"password": "twelve",
+			"users": {
+				"disallowed": "disallowed",
+				"operations": "operations",
+				"admin": "admin",
+				"federation": "federation",
+				"portal": "portal",
+				"readOnly": "readOnly",
+				"extension": "extension"
+			}
+		},
+		"trafficOpsDB": {
+			"dbname": "traffic_ops",
+			"description": "Test database to_test",
+			"hostname": "postgres",
+			"password": "twelve",
+			"port": "5432",
+			"type": "Pg",
+			"user": "traffic_ops"
+		},
+		"noPerl": true,
+		"noISO": true
+	}
+	EOF
+}
+
+CODE="0"
+
+makeCFG
+/usr/local/go/bin/go test -v --cfg ./traffic-ops-test.conf
+if [ "$?" -gt "0" ]; then
+	CODE="1"
+fi
+rm traffic-ops-test.conf
+
+cd ../v2
+makeCFG
+ /usr/local/go/bin/go test -v --cfg ./traffic-ops-test.conf

Review comment:
       It works as-is, so maybe that optimization can come later.




----------------------------------------------------------------
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 pull request #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#issuecomment-675099524


   We're about to find out


----------------------------------------------------------------
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 pull request #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#issuecomment-674925238


   Running v1, v2, and v3 in separate steps would be nice so we can tell at a glance which API version had failing 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] zrhoffman commented on a change in pull request #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470846080



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T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AaIjVdTQ1XN67RMxgdekCI2Eg8h4RdvwgB/tAO+C3ExzMSOA1IcZ
+tWuwIA2YnaFF9Sla9iJqxgtoGlaqm4VTUM/IdZqlzsP08pfNq7bXPsr9AoGBANgk
+tkovf1Y0O4lBHX3eVLnHXForxEZh8bGHwuJJWWzb0ZFcXrrSd8FSycZrR28v4sdQ
+WSSVPz3Op95HoTVXVL9EJcZ+MTnHaoCHbYBkrGTlGviu5Fl2V5EbrN7R7CdxJeem
+HOU4shTy1acMPgf8sT17ykkXhVeUhSK2Jg6fZn6HAoGAI4/51SeE4htuKwMyhTRN
+SOFcFBlBIE1ieRBr9lx4Ln7+xCMbEog/hM7z9z8gxd35Vv4YqoxQrZpWOHCw2NIf
+CqX3V5vubhe6WcY4bY5MttM/yLvwPKUZeng57PDqucV9zzkuoKfiCdXCcRpaGDEp
+okOooghj4ip204WDg6NTDZkCgYEAwZTfzsGLgmF1kRBIoZqmt1zeUcQxHfhKx32Y
+BaM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}
+EOF
+
+cat <<-EOF >database.conf
+{
+	"description": "Local PostgreSQL database on port 5432",
+	"dbname": "traffic_ops",
+	"hostname": "postgres",
+	"user": "traffic_ops",
+	"password": "twelve",
+	"port": "5432",
+	"ssl": false,
+	"type": "Pg"
+}
+EOF
+
+./traffic_ops_golang --cfg ./cdn.conf --dbcfg ./database.conf >out.log 2>err.log &
+
+cd ../testing/api/v1
+
+makeCFG() {
+	cat <<-EOF >traffic-ops-test.conf
+	{
+		"default": {
+			"logLocations": {
+				"debug": "stderr",
+				"error": "stderr",
+				"event": "stderr",
+				"info": "stderr",
+				"warning": "stderr"
+			},
+			"session": {
+				"timeoutInSecs": 60
+			}
+		},
+		"trafficOps": {
+			"URL": "https://localhost:6443",
+			"password": "twelve",
+			"users": {
+				"disallowed": "disallowed",
+				"operations": "operations",
+				"admin": "admin",
+				"federation": "federation",
+				"portal": "portal",
+				"readOnly": "readOnly",
+				"extension": "extension"
+			}
+		},
+		"trafficOpsDB": {
+			"dbname": "traffic_ops",
+			"description": "Test database to_test",
+			"hostname": "postgres",
+			"password": "twelve",
+			"port": "5432",
+			"type": "Pg",
+			"user": "traffic_ops"
+		},
+		"noPerl": true,
+		"noISO": true
+	}
+	EOF
+}
+
+CODE="0"
+
+makeCFG
+/usr/local/go/bin/go test -v --cfg ./traffic-ops-test.conf
+if [ "$?" -gt "0" ]; then
+	CODE="1"
+fi
+rm traffic-ops-test.conf
+
+cd ../v2
+makeCFG
+ /usr/local/go/bin/go test -v --cfg ./traffic-ops-test.conf

Review comment:
       ```
   go test ./v3 -test.v -cfg=../conf/traffic-ops-test.conf -fixtures=tc-fixtures.json
   ```
   
   run from the `api` directory is what I use




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470844261



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
+CgKCAQEA1OsuQ71qaSZ4ivGnh4YryeQEHMn5wZLX7kWYB637ssyOJnkU1ZGs93JM
+XJADzsjmssP6icSDhV2JPgDDYzx1eBJt6y3vHI7L3AdGfQJj+4FFABKR8moqpc1J
+WIMGnPzO6DeEc8irf0qxSh+yvuFX0j6oS8oCqiRxz5+HL2wEGWmrgr37JY4/bs7o
+4CMY19Ru1dP2Fr292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7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}
+EOF
+
+cat <<-EOF >database.conf
+{
+	"description": "Local PostgreSQL database on port 5432",
+	"dbname": "traffic_ops",
+	"hostname": "postgres",
+	"user": "traffic_ops",
+	"password": "twelve",
+	"port": "5432",
+	"ssl": false,
+	"type": "Pg"
+}
+EOF
+
+./traffic_ops_golang --cfg ./cdn.conf --dbcfg ./database.conf >out.log 2>err.log &
+
+cd ../testing/api/v1
+
+makeCFG() {
+	cat <<-EOF >traffic-ops-test.conf
+	{
+		"default": {
+			"logLocations": {
+				"debug": "stderr",
+				"error": "stderr",
+				"event": "stderr",
+				"info": "stderr",
+				"warning": "stderr"
+			},
+			"session": {
+				"timeoutInSecs": 60
+			}
+		},
+		"trafficOps": {
+			"URL": "https://localhost:6443",
+			"password": "twelve",
+			"users": {
+				"disallowed": "disallowed",
+				"operations": "operations",
+				"admin": "admin",
+				"federation": "federation",
+				"portal": "portal",
+				"readOnly": "readOnly",
+				"extension": "extension"
+			}
+		},
+		"trafficOpsDB": {
+			"dbname": "traffic_ops",
+			"description": "Test database to_test",
+			"hostname": "postgres",
+			"password": "twelve",
+			"port": "5432",
+			"type": "Pg",
+			"user": "traffic_ops"
+		},
+		"noPerl": true,
+		"noISO": true
+	}
+	EOF
+}
+
+CODE="0"
+
+makeCFG
+/usr/local/go/bin/go test -v --cfg ./traffic-ops-test.conf
+if [ "$?" -gt "0" ]; then
+	CODE="1"
+fi
+rm traffic-ops-test.conf
+
+cd ../v2
+makeCFG
+ /usr/local/go/bin/go test -v --cfg ./traffic-ops-test.conf

Review comment:
       I hope someone can figure out why I couldn't get that to work. It was *very* confusing.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r472375429



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,111 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
+CgKCAQEA1OsuQ71qaSZ4ivGn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ieRBr9lx4Ln7+xCMbEog/hM7z9z8gxd35Vv4YqoxQrZpWOHCw2NIf
+CqX3V5vubhe6WcY4bY5MttM/yLvwPKUZeng57PDqucV9zzkuoKfiCdXCcRpaGDEp
+okOooghj4ip204WDg6NTDZkCgYEAwZTfzsGLgmF1kRBIoZqmt1zeUcQxHfhKx32Y
+BaM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+envsubst </cdn.json >cdn.conf
+mv /database.json ./database.conf
+
+./traffic_ops_golang --cfg ./cdn.conf --dbcfg ./database.conf >out.log 2>err.log &

Review comment:
       Should stdout and stderr go to the same file so we have context for errors and warnings? Errors will still be pretty easy to find by searching for `ERROR:`.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r472520126



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,111 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
+CgKCAQEA1OsuQ71qaSZ4ivGnh4YryeQEHMn5wZLX7kWYB637ssyOJnkU1ZGs93JM
+XJADzsjmssP6icSDhV2JPgDDYzx1eBJt6y3vHI7L3AdGfQJj+4FFABKR8moqpc1J
+WIMGnPzO6DeEc8irf0qxSh+yvuFX0j6oS8oCqiRxz5+HL2wEGWmrgr37JY4/bs7o
+4CMY19Ru1dP2Fr292HEIqCEnLTOuaHSWAEWx1Tm93kT9sXbw/SG2JTLQSX80biFL
+7foJeoGWLls2reTCYTprzWFaMu3x9I8HLtf4VIN44rtvo5N20KYgjGqvPjFGPljL
+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CFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+envsubst </cdn.json >cdn.conf
+mv /database.json ./database.conf
+
+./traffic_ops_golang --cfg ./cdn.conf --dbcfg ./database.conf >out.log 2>err.log &

Review comment:
       stdout won't contain anything too helpful, I pretty much just do that to avoid writing to closed file descriptors, just in case. info, event, and debug logging is piped to `/dev/null` by the logging configuration. I tried including those in stderr as well, but the resulting logs after the tests finished were so large my browser refused to load the checks page that printed them. One day, we can put the entire log in a build artifact, so at that point we don't need to worry about what the GH UI can handle and can include everything in one stream.




----------------------------------------------------------------
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] jhg03a merged pull request #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
jhg03a merged pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959


   


----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470809079



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ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oGAI4/51SeE4htuKwMyhTRN
+SOFcFBlBIE1ieRBr9lx4Ln7+xCMbEog/hM7z9z8gxd35Vv4YqoxQrZpWOHCw2NIf
+CqX3V5vubhe6WcY4bY5MttM/yLvwPKUZeng57PDqucV9zzkuoKfiCdXCcRpaGDEp
+okOooghj4ip204WDg6NTDZkCgYEAwZTfzsGLgmF1kRBIoZqmt1zeUcQxHfhKx32Y
+BaM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}
+EOF
+
+cat <<-EOF >database.conf
+{
+	"description": "Local PostgreSQL database on port 5432",
+	"dbname": "traffic_ops",
+	"hostname": "postgres",
+	"user": "traffic_ops",
+	"password": "twelve",
+	"port": "5432",
+	"ssl": false,
+	"type": "Pg"
+}
+EOF
+
+./traffic_ops_golang --cfg ./cdn.conf --dbcfg ./database.conf >out.log 2>err.log &
+
+cd ../testing/api/v1
+
+makeCFG() {
+	cat <<-EOF >traffic-ops-test.conf
+	{
+		"default": {
+			"logLocations": {
+				"debug": "stderr",
+				"error": "stderr",
+				"event": "stderr",
+				"info": "stderr",
+				"warning": "stderr"
+			},
+			"session": {
+				"timeoutInSecs": 60
+			}
+		},
+		"trafficOps": {
+			"URL": "https://localhost:6443",
+			"password": "twelve",
+			"users": {
+				"disallowed": "disallowed",
+				"operations": "operations",
+				"admin": "admin",
+				"federation": "federation",
+				"portal": "portal",
+				"readOnly": "readOnly",
+				"extension": "extension"
+			}
+		},
+		"trafficOpsDB": {
+			"dbname": "traffic_ops",
+			"description": "Test database to_test",
+			"hostname": "postgres",
+			"password": "twelve",
+			"port": "5432",
+			"type": "Pg",
+			"user": "traffic_ops"
+		},
+		"noPerl": true,
+		"noISO": true
+	}
+	EOF

Review comment:
       This JSON should be a file.

##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1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hZzOpTPkGoo=
+-----END CERTIFICATE-----

Review comment:
       This cert
   * Expired in May 2018
   * Has a weird subject (`C = AU, ST = Some-State, O = Internet Widgits Pty Ltd`) with no CN
   
   Since we never have to visit Traffic Ops in a browser for this GHA (and don't have to accept a cert), any reason not to generate the cert and key with `openssl req` each time?

##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml

Review comment:
       This YAML should be a file or be generated (with something like `yq`)

##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
+CgKCAQEA1OsuQ71qaSZ4ivGnh4YryeQEHMn5wZLX7kWYB637ssyOJnkU1ZGs93JM
+XJADzsjmssP6icSDhV2JPgDDYzx1eBJt6y3vHI7L3AdGfQJ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UZeng57PDqucV9zzkuoKfiCdXCcRpaGDEp
+okOooghj4ip204WDg6NTDZkCgYEAwZTfzsGLgmF1kRBIoZqmt1zeUcQxHfhKx32Y
+BaM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}

Review comment:
       This JSON should be a file.

##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
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7Dj3Vi7WXr
+jsRZC4dxAoGBAPwuPdtc9gSNKjn8RnqfEJjdSo1qdLbGvRcSJNy4/kEEFECJXkeO
+mV/aklCi39cxAaIjVdTQ1XN67RMxgdekCI2Eg8h4RdvwgB/tAO+C3ExzMSOA1IcZ
+tWuwIA2YnaFF9Sla9iJqxgtoGlaqm4VTUM/IdZqlzsP08pfNq7bXPsr9AoGBANgk
+tkovf1Y0O4lBHX3eVLnHXForxEZh8bGHwuJJWWzb0ZFcXrrSd8FSycZrR28v4sdQ
+WSSVPz3Op95HoTVXVL9EJcZ+MTnHaoCHbYBkrGTlGviu5Fl2V5EbrN7R7CdxJeem
+HOU4shTy1acMPgf8sT17ykkXhVeUhSK2Jg6fZn6HAoGAI4/51SeE4htuKwMyhTRN
+SOFcFBlBIE1ieRBr9lx4Ln7+xCMbEog/hM7z9z8gxd35Vv4YqoxQrZpWOHCw2NIf
+CqX3V5vubhe6WcY4bY5MttM/yLvwPKUZeng57PDqucV9zzkuoKfiCdXCcRpaGDEp
+okOooghj4ip204WDg6NTDZkCgYEAwZTfzsGLgmF1kRBIoZqmt1zeUcQxHfhKx32Y
+BaM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}
+EOF
+
+cat <<-EOF >database.conf
+{
+	"description": "Local PostgreSQL database on port 5432",
+	"dbname": "traffic_ops",
+	"hostname": "postgres",
+	"user": "traffic_ops",
+	"password": "twelve",
+	"port": "5432",
+	"ssl": false,
+	"type": "Pg"
+}
+EOF
+
+./traffic_ops_golang --cfg ./cdn.conf --dbcfg ./database.conf >out.log 2>err.log &
+
+cd ../testing/api/v1
+
+makeCFG() {
+	cat <<-EOF >traffic-ops-test.conf
+	{
+		"default": {
+			"logLocations": {
+				"debug": "stderr",
+				"error": "stderr",
+				"event": "stderr",
+				"info": "stderr",
+				"warning": "stderr"
+			},
+			"session": {
+				"timeoutInSecs": 60
+			}
+		},
+		"trafficOps": {
+			"URL": "https://localhost:6443",
+			"password": "twelve",
+			"users": {
+				"disallowed": "disallowed",
+				"operations": "operations",
+				"admin": "admin",
+				"federation": "federation",
+				"portal": "portal",
+				"readOnly": "readOnly",
+				"extension": "extension"
+			}
+		},
+		"trafficOpsDB": {
+			"dbname": "traffic_ops",
+			"description": "Test database to_test",
+			"hostname": "postgres",
+			"password": "twelve",
+			"port": "5432",
+			"type": "Pg",
+			"user": "traffic_ops"
+		},
+		"noPerl": true,
+		"noISO": true
+	}
+	EOF
+}
+
+CODE="0"
+
+makeCFG
+/usr/local/go/bin/go test -v --cfg ./traffic-ops-test.conf
+if [ "$?" -gt "0" ]; then
+	CODE="1"
+fi
+rm traffic-ops-test.conf
+
+cd ../v2
+makeCFG
+ /usr/local/go/bin/go test -v --cfg ./traffic-ops-test.conf

Review comment:
       Since `makeCFG` gives you the same file each time, is `makeCFG` doing anything the 2nd or 3rd time it is being called?
   
   `makeCFG` outputs a file in the directory it is created in, so maybe instead of `go test`, this could be `go test ./v2` with `../traffic-ops-test.conf` so the conf can be in the same place for all 3 tests.

##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
+CgKCAQEA1OsuQ71qaSZ4ivGnh4YryeQEHMn5wZLX7kWYB637ssyOJnkU1ZGs93JM
+XJADzsjmssP6icSDhV2JPgDDYzx1eBJt6y3vHI7L3AdGfQJj+4FFABKR8moqpc1J
+WIMGnPzO6DeEc8irf0qxSh+yvuFX0j6oS8oCqiRxz5+HL2wEGWmrgr37JY4/bs7o
+4CMY19Ru1dP2Fr292HEIqCEnLTOuaHSWAEWx1Tm93kT9sXbw/SG2JTLQSX80biFL
+7foJeoGWLls2reTCYTprzW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QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}
+EOF
+
+cat <<-EOF >database.conf
+{
+	"description": "Local PostgreSQL database on port 5432",
+	"dbname": "traffic_ops",
+	"hostname": "postgres",
+	"user": "traffic_ops",
+	"password": "twelve",
+	"port": "5432",
+	"ssl": false,
+	"type": "Pg"
+}

Review comment:
       This JSON should be a file or be generated with `jq`.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r471877140



##########
File path: .github/actions/to-integration-tests/Dockerfile
##########
@@ -15,9 +15,11 @@
 # specific language governing permissions and limitations
 # under the License.
 
-FROM golang:1.14.2-alpine
+FROM golang:1.14.2-buster

Review comment:
       This too builds on Alpine if the `musl-dev` package is installed. FWIW, all of the Go ATC components have been built with the [`osusergo`](https://golang.org/doc/go1.11#os/user) and [`netgo`](https://golang.org/pkg/net/#hdr-Name_Resolution) tags ([example](https://github.com/apache/trafficcontrol/pull/4758/files#diff-d57f2a7a8ff4abbc35eef295ce11d1d9R60)) for static linking since #4758, which effectively disables cgo.




----------------------------------------------------------------
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 pull request #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#issuecomment-675122835


   I wound up separating out the database setup to alleviate what became a much longer runtime, so instead of `if: ${{ always() }}` it checks that that step, specifically, succeeded. But it's working as separate steps now.


----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470839537



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BE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EJjdSo1qdLbGvRcSJNy4/kEEFECJXkeO
+mV/aklCi39cxAaIjVdTQ1XN67RMxgdekCI2Eg8h4RdvwgB/tAO+C3ExzMSOA1IcZ
+tWuwIA2YnaFF9Sla9iJqxgtoGlaqm4VTUM/IdZqlzsP08pfNq7bXPsr9AoGBANgk
+tkovf1Y0O4lBHX3eVLnHXForxEZh8bGHwuJJWWzb0ZFcXrrSd8FSycZrR28v4sdQ
+WSSVPz3Op95HoTVXVL9EJcZ+MTnHaoCHbYBkrGTlGviu5Fl2V5EbrN7R7CdxJeem
+HOU4shTy1acMPgf8sT17ykkXhVeUhSK2Jg6fZn6HAoGAI4/51SeE4htuKwMyhTRN
+SOFcFBlBIE1ieRBr9lx4Ln7+xCMbEog/hM7z9z8gxd35Vv4YqoxQrZpWOHCw2NIf
+CqX3V5vubhe6WcY4bY5MttM/yLvwPKUZeng57PDqucV9zzkuoKfiCdXCcRpaGDEp
+okOooghj4ip204WDg6NTDZkCgYEAwZTfzsGLgmF1kRBIoZqmt1zeUcQxHfhKx32Y
+BaM7/EtD/rSEAz7NEtBa9uLOL77rlSdZL3KcGXck0efFckitFkCqtIQBAoaf1E12
+vS9tV0/6QBAjZByhgM0Qnt/Uad7k2/vilUmZ9TkoMVy9kdm3xCFCowP14OKb+uK4
+YxBQc7ECgYEAm7eVtNlPHYmC54FU2bLucryNMLmu9I8O6zvbK5sxiMdtlh7OjaUB
+RQS5iVc0iTacDZTGh7eqNzgGplj76pWGHeZUy0xIj/ZIRu2qOy0v+ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}
+EOF
+
+cat <<-EOF >database.conf
+{
+	"description": "Local PostgreSQL database on port 5432",
+	"dbname": "traffic_ops",
+	"hostname": "postgres",
+	"user": "traffic_ops",
+	"password": "twelve",
+	"port": "5432",
+	"ssl": false,
+	"type": "Pg"
+}

Review comment:
       A file would mean no extra dependency.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r471870162



##########
File path: .github/actions/todb-init/Dockerfile
##########
@@ -15,9 +15,11 @@
 # specific language governing permissions and limitations
 # under the License.
 
-FROM golang:1.14.2-alpine
+FROM golang:1.14.2-buster
 
-RUN apk add --no-cache git gcc gettext postgresql-client
+RUN apt-get update &&\
+	apt-get install -y --no-install-recommends git gcc gettext-base postgresql-client-11 &&\

Review comment:
       dang, that's huge. But probably substantially less than the difference between buster and alpine.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r470838563



##########
File path: .github/actions/to-integration-tests/entrypoint.sh
##########
@@ -0,0 +1,242 @@
+#!/bin/sh -l
+# 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.
+
+GOPATH="$(mktemp -d)"
+SRCDIR="$GOPATH/src/github.com/apache"
+mkdir -p "$SRCDIR"
+ln -s "$PWD" "$SRCDIR/trafficcontrol"
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/app/db"
+
+echo 'version: "1.0"
+name: dbconf.yml
+
+test:
+  driver: postgres
+  open: host=postgres port=5432 user=traffic_ops password=twelve dbname=traffic_ops sslmode=disable
+
+' > dbconf.yml
+
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./create_tables.sql >/dev/null
+goose --env=test --path="$PWD" up
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./seeds.sql >/dev/null
+psql -d postgresql://traffic_ops:twelve@postgres:5432/traffic_ops < ./patches.sql >/dev/null
+
+cd "$SRCDIR/trafficcontrol/traffic_ops/traffic_ops_golang"
+
+
+/usr/local/go/bin/go get ./...
+/usr/local/go/bin/go build .
+
+echo "
+-----BEGIN CERTIFICATE-----
+MIIDtTCCAp2gAwIBAgIJAJgQuE9T48+gMA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNV
+BAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHwYDVQQKExhJbnRlcm5ldCBX
+aWRnaXRzIFB0eSBMdGQwHhcNMTcwNTA5MDIyNTI0WhcNMTgwNTA5MDIyNTI0WjBF
+MQswCQYDVQQGEwJBVTETMBEGA1UECBMKU29tZS1TdGF0ZTEhMB8GA1UEChMYSW50
+ZXJuZXQgV2lkZ2l0cyBQdHkgTHRkMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIB
+CgKCAQEA1OsuQ71qaSZ4ivGnh4YryeQEHMn5wZLX7kWYB637ssyOJnkU1ZGs93JM
+XJADzsjmssP6icSDhV2JPgDDYzx1eBJt6y3vHI7L3AdGfQJj+4FFABKR8moqpc1J
+WIMGnPzO6DeEc8irf0qxSh+yvuFX0j6oS8oCqiRxz5+HL2wEGWmrgr37JY4/bs7o
+4CMY19Ru1dP2Fr292HEIqCEnLTOuaHSWAEWx1Tm93kT9sXbw/SG2JTLQSX80biFL
+7foJeoGWLls2reTCYTprzWFaMu3x9I8HLtf4VIN44rtvo5N20KYgjGqvPjFGPljL
+yrgB8rXSCpH3M4AbazxD8fZKbdORawIDAQABo4GnMIGkMB0GA1UdDgQWBBT6zEpf
+DYbYCI3Bu82+Q5SmI+/7ojB1BgNVHSMEbjBsgBT6zEpfDYbYCI3Bu82+Q5SmI+/7
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ffqfX1wCz7p
+A22D22wvfs7CE3cUz/8UnvLM3kbTTu1WbbBbrHjAV47sAHjW/ckTqeo=
+-----END RSA PRIVATE KEY-----
+" > localhost.key
+
+cat <<-EOF >cdn.conf
+{
+	"hypnotoad" : {
+		"listen" : [
+			"https://not-a-real-host.test:1?cert=$PWD/localhost.crt&key=$PWD/localhost.key&verify=0x00&ciphers=AES128-GCM-SHA256:HIGH:!RC4:!MD5:!aNULL:!EDH:!ED"
+		],
+		"user" : "trafops",
+		"group" : "trafops",
+		"heartbeat_timeout" : 20,
+		"pid_file" : "/var/run/traffic_ops.pid",
+		"workers" : 12
+	},
+	"use_ims": true,
+	"traffic_ops_golang" : {
+		"insecure": true,
+		"port" : "6443",
+		"log_location_error": "stderr",
+		"log_location_warning": "stderr",
+		"log_location_info": null,
+		"log_location_debug": null,
+		"log_location_event": null,
+		"max_db_connections": 20,
+		"db_conn_max_lifetime_seconds": 60,
+		"db_query_timeout_seconds": 20,
+		"supported_ds_metrics": [ "kbps", "tps_total", "tps_2xx", "tps_3xx", "tps_4xx", "tps_5xx" ]
+	},
+	"cors" : {
+		"access_control_allow_origin" : "*"
+	},
+	"to" : {
+		"base_url" : "https://localhost",
+		"email_from" : "no-reply@traffic-ops.test",
+		"no_account_found_msg" : "A Traffic Ops user account is required for access. Please contact your Traffic Ops user administrator."
+	},
+	"portal" : {
+		"base_url" : "https://not-a-real-host.test/#!/",
+		"email_from" : "no-reply@traffic-portal.test",
+		"pass_reset_path" : "user",
+		"user_register_path" : "user"
+	},
+	"secrets" : [
+		"blahblah"
+	],
+	"geniso" : {
+		"iso_root_path" : "/opt/traffic_ops/app/public"
+	},
+	"inactivity_timeout" : 60,
+	"smtp" : {
+		"enabled" : false
+	},
+	"InfluxEnabled": false
+}

Review comment:
       This uses environment variables, so making it a file would force it to pull in some kind of dependency.




----------------------------------------------------------------
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 #4959: Traffic Ops integration tests

Posted by GitBox <gi...@apache.org>.
zrhoffman commented on a change in pull request #4959:
URL: https://github.com/apache/trafficcontrol/pull/4959#discussion_r471824488



##########
File path: .github/actions/to-integration-tests/Dockerfile
##########
@@ -15,9 +15,11 @@
 # specific language governing permissions and limitations
 # under the License.
 
-FROM golang:1.14.2-alpine
+FROM golang:1.14.2-buster

Review comment:
       No need for `stdio` here if cgo is disabled
   ```dockerfile
   ENV CGO_ENABLED=0
   ```

##########
File path: .github/workflows/traffic ops.yml
##########
@@ -51,18 +51,19 @@ jobs:
     - name: Checkout
       uses: actions/checkout@master
     - name: Initialize Traffic Ops Database
+      id: todb
       uses: ./.github/actions/todb-init
     - name: Run API v1 tests
       uses: ./.github/actions/to-integration-tests
       with:
         version: 1
     - name: Run API v2 tests
-      if: ${{ always() }}
+      if: ${{ steps.todb.outcome == 'success' }}
       uses: ./.github/actions/to-integration-tests
       with:
         version: 2
     - name: Run API v3 tests
-      if: ${{ always() }}
+      if: ${{ steps.todb.outcome == 'success' }}

Review comment:
       The v2 and v3 stages no longer run if a previous stage failed. Re-adding the `always()` check makes them run in that case:
   
   ```workflow
        if: ${{ steps.todb.outcome == 'success' && always() }}
   ```

##########
File path: .github/actions/todb-init/Dockerfile
##########
@@ -15,9 +15,11 @@
 # specific language governing permissions and limitations
 # under the License.
 
-FROM golang:1.14.2-alpine
+FROM golang:1.14.2-buster
 
-RUN apk add --no-cache git gcc gettext postgresql-client
+RUN apt-get update &&\
+	apt-get install -y --no-install-recommends git gcc gettext-base postgresql-client-11 &&\

Review comment:
       This builds for me on alpine if the `musl-dev` package is added (16MB).




----------------------------------------------------------------
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