]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
no bug - circleci config tweaks
authorDylan William Hardison <dylan@hardison.net>
Wed, 4 Apr 2018 13:57:20 +0000 (09:57 -0400)
committerDylan William Hardison <dylan@hardison.net>
Wed, 4 Apr 2018 13:57:20 +0000 (09:57 -0400)
.circleci/config.yml
conf/log4perl-test.conf

index f5c761af461cd43a84d992d7c772c80a40dccb73..1283d573b35e83be98cb934846d417d48cce44c0 100644 (file)
@@ -5,13 +5,6 @@
 
 version: 2
 
-main_filters: &main_filters
-  branches:
-    ignore:
-      - /^(?:release|test)-20\d\d\d\d\d\d\.\d+/
-      - /\//
-      - production
-
 defaults:
   bmo_slim_image: &bmo_slim_image
     image: mozillabteam/bmo-slim:20180330.1
@@ -20,6 +13,18 @@ defaults:
   mysql_image: &mysql_image
     image: mozillabteam/bmo-mysql:5.6
 
+  store_log: &store_log
+    store_artifacts:
+      path: /app/bugzilla.log
+      destination: bugzilla.log
+
+  main_filters: &main_filters
+    branches:
+      ignore:
+        - /^(?:release|test)-20\d\d\d\d\d\d\.\d+/
+        - /\//
+        - production
+
   bmo_env: &bmo_env
     PORT: 8000
     LOGGING_PORT: 5880
@@ -81,6 +86,8 @@ jobs:
           name: build push data
           command: |
             mv /opt/bmo/local /app/local
+            perl Makefile.PL
+            perl -I/app -I/app/local/lib/perl5 -MBugzilla -e 1
             perl checksetup.pl --no-database --no-templates --no-permissions
             perl scripts/build-bmo-push-data.pl
       - run:
@@ -115,6 +122,7 @@ jobs:
           paths: ["*.txt"]
       - store_artifacts:
           path: /app/build_info
+      - *store_log
 
   build:
     working_directory: /app
@@ -138,6 +146,7 @@ jobs:
       - run: "docker cp bmo:/app/version.json build_info/version.json"
       - store_artifacts:
           path: /app/build_info
+      - *store_log
       - deploy:
           command: |
             TAG="$(cat /app/build_info/tag.txt)"
@@ -158,7 +167,7 @@ jobs:
             docker push "$DOCKERHUB_REPO:latest"
 
   test_sanity:
-    parallelism: 2
+    parallelism: 1
     working_directory: /app
     docker:
       - <<: *bmo_slim_image
@@ -181,6 +190,7 @@ jobs:
             /app/scripts/entrypoint.pl prove -qf $(circleci tests glob 't/*.t' | circleci tests split) | tee artifacts/$CIRCLE_JOB.txt
       - store_artifacts:
           path: /app/artifacts
+      - *store_log
 
   test_webservices:
     parallelism: 1
@@ -199,6 +209,7 @@ jobs:
           /app/scripts/entrypoint.pl test_webservices | tee artifacts/$CIRCLE_JOB.txt
       - store_artifacts:
           path: /app/artifacts
+      - *store_log
 
   test_selenium:
     parallelism: 1
@@ -217,6 +228,7 @@ jobs:
           /app/scripts/entrypoint.pl test_selenium | tee artifacts/$CIRCLE_JOB.txt
       - store_artifacts:
           path: /app/artifacts
+      - *store_log
 
   test_bmo:
     parallelism: 1
@@ -246,6 +258,7 @@ jobs:
       - run: |
           [[ -f build_info/only_version_changed.txt ]] && exit 0
           /app/scripts/entrypoint.pl test_bmo -q -f t/bmo/*.t
+      - *store_log
 
 workflows:
   version: 2
index eda81d31b9eabe7fb1b988666538b69fbd158c2b..65558ba4fc7706d391ed04db38247106a27730b4 100644 (file)
@@ -1,4 +1,4 @@
-log4perl.rootLogger = DEBUG, Cereal, Screen
+log4perl.rootLogger = DEBUG, Cereal, Screen, File
 log4perl.appender.Cereal = Log::Log4perl::Appender::Socket
 log4perl.appender.Cereal.PeerAddr=127.0.0.1
 log4perl.appender.Cereal.PeerPort=5880
@@ -10,4 +10,9 @@ log4perl.filter.IS_INTERACTIVE = sub { Bugzilla::Logging::is_interactive() }
 log4perl.appender.Screen = Log::Log4perl::Appender::Screen
 log4perl.appender.Screen.Filter = IS_INTERACTIVE
 log4perl.appender.Screen.layout = Log::Log4perl::Layout::PatternLayout
-log4perl.appender.Screen.layout.ConversionPattern = %-5.5p [%d] [%c] %m{chomp} at %F line %L (%M)%n
\ No newline at end of file
+log4perl.appender.Screen.layout.ConversionPattern = %-5.5p [%d] [%c] %m{chomp} at %F line %L (%M)%n
+
+log4perl.appender.File = Log::Log4perl::Appender::File
+log4perl.appender.File.layout = Log::Log4perl::Layout::Mozilla
+log4perl.appender.File.filename = /app/bugzilla.log
+log4perl.appender.File.mode = append