Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
124 commits
Select commit Hold shift + click to select a range
d5f9e64
Tweak for proper branch
pingevt Aug 1, 2022
4547370
Test local Updates
pingevt Aug 1, 2022
25e31a2
Add debugger
pingevt Aug 16, 2022
42a6512
Change var to get full ref
pingevt Aug 16, 2022
2288508
Pantheon does notsupport “/“s
pingevt Aug 16, 2022
32ef30c
New variables
pingevt Aug 22, 2022
8cb857e
testing
pingevt Aug 25, 2022
397a8dc
Remove debug
pingevt Aug 25, 2022
1683724
try env script
pingevt Sep 15, 2022
8de6b06
More updates to vars
pingevt Sep 15, 2022
69ad92b
change location of bash file
pingevt Sep 15, 2022
5a79ce8
Try adding to github env
pingevt Sep 15, 2022
fe92509
Try test file
pingevt Sep 15, 2022
3642df2
Test file part 2
pingevt Sep 15, 2022
0f11e96
Try full file
pingevt Sep 15, 2022
975cc00
Set Terminus site
pingevt Sep 15, 2022
2ab9dd9
rearrange steps
pingevt Sep 15, 2022
b1cee3c
testing
pingevt Sep 16, 2022
f444381
more testing
pingevt Sep 16, 2022
9f21afb
More Testing
pingevt Sep 16, 2022
ea48b22
Lets see what happens
pingevt Sep 16, 2022
b0a5309
Remove extrs “’”s
pingevt Sep 16, 2022
67116b5
Testing IF
pingevt Sep 16, 2022
ec09e55
more testing
pingevt Sep 16, 2022
cc84b2e
if syntax
pingevt Sep 16, 2022
327319f
maybe its a string
pingevt Sep 16, 2022
5e028ba
Add in IFs
pingevt Sep 16, 2022
6767e47
Take out some debugging
pingevt Sep 16, 2022
db4e18b
Trigger
pingevt Sep 16, 2022
b26f298
Test PR number
pingevt Sep 16, 2022
60097eb
YAML…
pingevt Sep 16, 2022
d349c7e
eh
pingevt Sep 16, 2022
0cc33e5
Update for PR#
pingevt Sep 16, 2022
f691972
uh…
pingevt Sep 16, 2022
36236cf
oh…
pingevt Sep 16, 2022
353ac82
Revert "Take out some debugging"
pingevt Sep 16, 2022
b1a8340
uh….
pingevt Sep 16, 2022
41e8fc7
This should fail
pingevt Sep 16, 2022
748defa
pantheon cleanup
pingevt Sep 16, 2022
562491e
Re-order jobs so we vcan use terminus
pingevt Sep 16, 2022
0781a8c
And add in IF
pingevt Sep 16, 2022
883748c
temp dir testing
pingevt Sep 16, 2022
488587e
tmp dir testing 2
pingevt Sep 16, 2022
1e3139a
debugging temp dir
pingevt Sep 16, 2022
e185fcb
oops…
pingevt Sep 16, 2022
41869c5
more debugging
pingevt Sep 16, 2022
b3644c6
debugging API
pingevt Sep 16, 2022
4f10ac1
Move temp dir to top level
pingevt Sep 16, 2022
d78d1a7
A little clean up
pingevt Sep 16, 2022
b84baca
Add backups workflow
pingevt Sep 16, 2022
477c66f
Add in basic scaffold for vis reg testing
pingevt Sep 16, 2022
d5c5ef9
working…
pingevt Sep 16, 2022
f3d6d5e
install backstopjs
pingevt Sep 16, 2022
ba0ff77
initial backstop scripts, see what breaks
pingevt Sep 16, 2022
d9ebc21
quick tweaks
pingevt Sep 16, 2022
7a00863
TRIGGER
pingevt Sep 16, 2022
336e10f
Change to PR number
pingevt Sep 16, 2022
90ec637
Rework artifacts dir and add Puppeteer
pingevt Sep 16, 2022
f88ea1c
Add in config gen file
pingevt Sep 16, 2022
524d236
remove some of the “reporting” for now
pingevt Sep 16, 2022
d9420fa
Lets try local for now
pingevt Sep 17, 2022
35d65aa
add in `build-test-config-files.js`
pingevt Sep 17, 2022
3188f4b
fix artifacts dir location
pingevt Sep 17, 2022
b1fce77
fix up some variables
pingevt Sep 17, 2022
836e139
oops…
pingevt Sep 17, 2022
9896bf7
backstop needs to be global
pingevt Sep 17, 2022
463c757
add minimist
pingevt Sep 17, 2022
e187d08
add in env shebang
pingevt Sep 17, 2022
e24dfdb
Debug
pingevt Sep 17, 2022
3e0cd9d
more debugging
pingevt Sep 17, 2022
8f94e9f
take out global again
pingevt Sep 17, 2022
7cd6704
Add in full path
pingevt Sep 17, 2022
216a057
periods…
pingevt Sep 17, 2022
e40579d
Save the artifacts
pingevt Sep 17, 2022
6b6d687
Full path
pingevt Sep 17, 2022
cedb148
get config itnot assets
pingevt Sep 19, 2022
de886cb
testing…
pingevt Sep 19, 2022
4bebcda
Post to pantheon
pingevt Sep 19, 2022
ffccddc
update permissions
pingevt Sep 19, 2022
47a9289
changing timestamp
pingevt Sep 19, 2022
a059179
oh variables
pingevt Sep 19, 2022
9108025
more variables
pingevt Sep 19, 2022
00ac7b5
rsync…
pingevt Sep 19, 2022
23f4149
i dunno!
pingevt Sep 19, 2022
d8c2f06
more rsync
pingevt Sep 19, 2022
25a0f65
Test Rsync
pingevt Sep 19, 2022
eda9d30
and another test
pingevt Sep 19, 2022
c8902c2
andone more time!
pingevt Sep 19, 2022
fcee524
clean up a bit
pingevt Sep 19, 2022
5acd979
Try out Connect BC API!
pingevt Sep 19, 2022
18c866a
oh variable names…
pingevt Sep 19, 2022
fa491ae
Lets try jq
pingevt Sep 19, 2022
a9f3471
KEY!
pingevt Sep 19, 2022
69671b6
Variablize node version
pingevt Sep 20, 2022
912962d
clean up and use .nvmrc file
pingevt Sep 20, 2022
ce61539
Check PR messaging
pingevt Sep 20, 2022
175f04b
add explicit PR number
pingevt Sep 20, 2022
f801214
a little more work on the PR Messages
pingevt Sep 20, 2022
2ad4e4b
Working on message variables
pingevt Sep 20, 2022
49823db
Testing…
pingevt Sep 20, 2022
0f53bb4
try more message stuffs
pingevt Sep 20, 2022
3ad8051
try this
pingevt Sep 20, 2022
a1881c1
Try another option
pingevt Sep 20, 2022
2f0c6bb
Well that doesn’t Work
pingevt Sep 20, 2022
5591c4f
try this maybe
pingevt Sep 20, 2022
c8ce080
Try using a markdown file
pingevt Sep 20, 2022
6102f9e
Re-arrange
pingevt Sep 20, 2022
8781fd3
Have to change back dirs
pingevt Sep 20, 2022
4764e5e
WHAT!?
pingevt Sep 20, 2022
9d899e4
lets see what happens
pingevt Sep 20, 2022
3e10493
should have figured that var was taken…
pingevt Sep 20, 2022
6e841bb
Add in one more line.
pingevt Sep 20, 2022
1ae935a
Update process
pingevt Sep 21, 2022
bba7cba
gulp not bldr
pingevt Sep 21, 2022
7a6a593
Keep both npm commands in template
pingevt Sep 21, 2022
472e626
Update artifcats dir and rwemove latest message variable
pingevt Sep 22, 2022
cd54301
Update backups so it is using variables
pingevt Sep 22, 2022
1fce567
Add in if statements for `gitignore-panth` file
pingevt Sep 22, 2022
f88b2f4
Move npm commands to build
pingevt Sep 28, 2022
fddb237
Move customized vars to .projectconfig.js file
pingevt Sep 28, 2022
e3ced82
exit 0 so i don’t kill CI
pingevt Sep 28, 2022
0cec76b
Checking variables in .projectconfig.json
pingevt Sep 29, 2022
207a723
Remove testing
pingevt Sep 29, 2022
3474dbb
updates
pingevt Nov 27, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions .ci/scripts/env/copy-to-connect-bc.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
#!/bin/bash

set -eo pipefail

PWD_VAR=$(pwd)
UUID=4a1a251a-53ba-4793-a41f-862eb890934c
ENV=live

echo $PWD_VAR

curl -H "api-key: $CONNECT_BC_API" -d "project=$TERMINUS_SITE&branch=$GITHUB_REF_NAME" -X POST https://live-connect-bluecadet.pantheonsite.io/api/vis-reg-result >> connect-bc.js

TIMESTAMP=$(cat connect-bc.js | jq -r '.data.timestamp')

mkdir ../to-be-copied
mkdir ../to-be-copied/$TIMESTAMP
cp -R ../artifacts ../to-be-copied/$TIMESTAMP

cd ../to-be-copied
rsync -raRLvz --relative --size-only --checksum --ipv4 --progress -e 'ssh -p 2222' . --temp-dir=~/tmp/ $ENV.$UUID@appserver.$ENV.$UUID.drush.in:files/vis-reg-reports


echo $PWD_VAR

cd "$PWD_VAR"

VR_PR_LINK="[VR Report](https://live-connect-bluecadet.pantheonsite.io/sites/default/files/vis-reg-reports/$TIMESTAMP/artifacts/backstop_data/html_report/index.html)"

echo $VR_PR_LINK

echo "[VR Report](https://live-connect-bluecadet.pantheonsite.io/sites/default/files/vis-reg-reports/$TIMESTAMP/artifacts/backstop_data/html_report/index.html)" >> message.md
32 changes: 32 additions & 0 deletions .ci/scripts/env/deploy-to-pantheon.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#!/bin/bash

set -eo pipefail

# Create a new multidev site to dev on
terminus -n env:wake "$TERMINUS_SITE.dev"

echo ${CI_BRANCH}
echo ${PR_NUMBER}

if [[ "$CLONE_CONTENT" == true ]]; then
echo -e "Copying site from dev to $TERMINUS_ENV. Cloning content"
terminus -n build:env:create "$TERMINUS_SITE.dev" "$TERMINUS_ENV" --yes --clone-content
else
echo -e "Copying site from dev to $TERMINUS_ENV. NOT cloning content"
terminus -n build:env:create "$TERMINUS_SITE.dev" "$TERMINUS_ENV" --yes
fi

# Run Drush Commands if not WordPress
if [ "$CMS_PLATFORM" != "WP" ]; then
# Run updatedb to ensure that the cloned database is updated for the new code.
terminus -n drush "$TERMINUS_SITE.$TERMINUS_ENV" -- updatedb -y

# If any modules, or theme files have been moved around or reorganized, in order to avoid
# "The website encountered an unexpected error. Please try again later." error on First Visit
terminus -n drush "$TERMINUS_SITE.$TERMINUS_ENV" cr

# If exported configuration is available, then import it.
if [ -f "config/system.site.yml" ] ; then
terminus -n drush "$TERMINUS_SITE.$TERMINUS_ENV" -- config-import --yes
fi
fi
31 changes: 31 additions & 0 deletions .ci/scripts/env/init-env-vars.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
#!/usr/bin/env node

var fs = require('fs');
const CONFIG = require('../../../.projectconfig.js');

// Check for required variables.

let errs = [];
if (!CONFIG.TZ) {
errs.push("The 'TZ' variable needs to be set in .projectconfig.js");
}
if (!CONFIG.TEMP_DIR) {
errs.push("The 'TEMP_DIR' variable needs to be set in .projectconfig.js");
}
if (!CONFIG.CMS_PLATFORM) {
errs.push("The 'CMS_PLATFORM' variable needs to be set in .projectconfig.js");
}
if (!CONFIG.DEFAULT_SITE) {
errs.push("The 'DEFAULT_SITE' variable needs to be set in .projectconfig.js");
}
if (!CONFIG.testingPaths) {
errs.push("The 'testingPaths' variable needs to be set in .projectconfig.js");
}

if (errs.length > 0) {
console.log(errs.join("\n"));
process.exit(1);
}

// Save Config as settings.
fs.writeFileSync('.projectconfig.json', JSON.stringify(CONFIG, null, 2));
Loading