Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CIF-2161: align venia with wknd #174

Merged
merged 27 commits into from
Aug 27, 2021
Merged
Show file tree
Hide file tree
Changes from 25 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
e4e95c5
CIF-2222: Add storefront context config
laurentiumagureanu Jul 19, 2021
e27cb1c
Merge branch 'dev' into issues/CIF-2222
buuhuu Jul 22, 2021
ac35019
ignore node_modules when linting
buuhuu Jul 22, 2021
2a102d5
ignore dependencies when linting
buuhuu Jul 22, 2021
01f800a
refactor venia to align wknd (WIP)
buuhuu Jul 23, 2021
55eaf4a
Merge branch 'dev' into issue/CIF-2162
buuhuu Jul 23, 2021
876ae4c
refactor venia to align wknd
buuhuu Jul 23, 2021
2e7ee1c
refactor venia to align wknd
buuhuu Jul 23, 2021
e00f02c
fix venia.all name
buuhuu Jul 23, 2021
9485cae
Merge remote-tracking branch 'origin/dev' into issue/CIF-2162
buuhuu Jul 27, 2021
4e7b256
minor fixes to comments etc., bind scm goals of prepare-release to in…
buuhuu Jul 27, 2021
8393117
Merge remote-tracking branch 'origin/dev' into issue/CIF-2162
buuhuu Aug 3, 2021
8666406
Merge branch 'dev' into issue/CIF-2162
buuhuu Aug 11, 2021
0791ba1
Merge remote-tracking branch 'origin/dev' into issue/CIF-2162
buuhuu Aug 11, 2021
be7ad53
adapt to tech grooming discussion
buuhuu Aug 12, 2021
444eed8
Merge branch 'issue/CIF-2162' into issue/CIF-2161
buuhuu Aug 12, 2021
74b7f61
fix classic module includes
buuhuu Aug 12, 2021
8ea284d
fix its
buuhuu Aug 12, 2021
4378ab3
revert change on test data
buuhuu Aug 12, 2021
1233733
fix all package dependencies
buuhuu Aug 12, 2021
01b1c54
Merge branch 'dev' into issue/CIF-2161
LSantha Aug 19, 2021
8f8a6e2
Merge branch 'dev' into issue/CIF-2161
buuhuu Aug 23, 2021
60a8e0c
add missing wcm cc dependnecy
buuhuu Aug 23, 2021
308db14
add missing dependency to magento-graphql bundle for cloud
buuhuu Aug 23, 2021
8d06689
Merge branch 'dev' into issue/CIF-2161
LSantha Aug 25, 2021
982bd67
Merge branch 'dev' into issue/CIF-2161
LSantha Aug 27, 2021
33b402c
rename withClassic to classic and update README.md
buuhuu Aug 27, 2021
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
10 changes: 4 additions & 6 deletions .circleci/ci/deploy-venia.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,10 @@ ci.sh("chmod +x ghr");

ci.sh("mkdir -p artifacts"); // target folder for all the build artifacts

let profiles = ['cloud', 'classic'];
profiles.forEach(profile => {
ci.stage(`Build and install Venia '${profile}'`);
ci.sh(`mvn clean install -P${profile}`);
ci.sh(`cp all/target/${releaseArtifact}.all-${releaseVersion}-${profile}.zip artifacts`);
})
ci.stage(`Build and install Venia`);
ci.sh(`mvn -B clean install -PwithClassic`);
ci.sh(`cp all/target/${releaseArtifact}.all-${releaseVersion}.zip artifacts/${releaseArtifact}.all-${releaseVersion}.zip`);
ci.sh(`cp classic/all/target/${releaseArtifact}.all-classic-${releaseVersion}.zip artifacts/${releaseArtifact}.all-${releaseVersion}-classic.zip`);

ci.stage("Deploy Venia Sample Project to GitHub");
ci.sh(`./ghr -t ${ci.env("GITHUB_TOKEN")} \
Expand Down
5 changes: 3 additions & 2 deletions .circleci/ci/it-tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,13 @@ try {

// The core components are already installed in the Cloud SDK
extras += ` --bundle com.adobe.cq:core.wcm.components.all:${wcmVersion}:zip`;
extras += ` --install-file ${buildPath}/classic/all/target/aem-cif-guides-venia.all-classic-${veniaVersion}.zip`

} else if (classifier == 'cloud') {
// Download latest add-on release from artifactory
ci.sh(`mvn -s ${buildPath}/.circleci/settings.xml com.googlecode.maven-download-plugin:download-maven-plugin:1.6.3:artifact -Partifactory-cloud -DgroupId=com.adobe.cq.cif -DartifactId=cif-cloud-ready-feature-pkg -Dversion=LATEST -Dtype=far -Dclassifier=cq-commerce-addon-authorfar -DoutputDirectory=${buildPath}/dependencies -DoutputFileName=addon.far`);
extras = ` --install-file ${buildPath}/dependencies/addon.far`;
extras += ` --install-file ${buildPath}/all/target/aem-cif-guides-venia.all-${veniaVersion}.zip`
}

// Install SNAPSHOT or current version of CIF examples bundle
Expand All @@ -58,14 +60,13 @@ try {
ci.sh(`./qp.sh -v start --id author --runmode author --port 4502 --qs-jar /home/circleci/cq/author/cq-quickstart.jar \
--bundle org.apache.sling:org.apache.sling.junit.core:1.0.23:jar \
${extras} \
--install-file ${buildPath}/all/target/venia.all-${veniaVersion}-${classifier}.zip \
--vm-options \\\"-Xmx1536m -XX:MaxPermSize=256m -Djava.awt.headless=true -javaagent:${process.env.JACOCO_AGENT}=destfile=crx-quickstart/jacoco-it.exec\\\"`);
});

// Run integration tests
if (TYPE === 'integration') {
ci.dir('it.tests', () => {
ci.sh(`mvn clean verify -U -B -Plocal,${classifier}`); // The -Plocal profile comes from the AEM archetype
ci.sh(`mvn clean verify -U -B -Plocal`); // The -Plocal profile comes from the AEM archetype
});
}
if (TYPE === 'selenium') {
Expand Down
63 changes: 9 additions & 54 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ common:
- checkout
- restore_cache:
keys:
- maven-repo-v2-<< parameters.classifier >>-its-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- maven-repo-v2-<< parameters.classifier >>-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- maven-repo-v2-its-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- maven-repo-v2-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- attach_workspace:
at: /home/circleci/build
- run:
Expand All @@ -19,7 +19,7 @@ common:
- save_cache:
paths:
- ~/.m2
key: maven-repo-v2-<< parameters.classifier >>-its-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
key: maven-repo-v2-its-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- store_test_results:
path: test-reports
# Save test results as artifacts
Expand Down Expand Up @@ -80,8 +80,6 @@ jobs:
- checkout
- restore_cache:
keys:
- maven-repo-v2-cloud-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- maven-repo-v2-cloud
- maven-repo-v2-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- maven-repo-v2-
- run:
Expand All @@ -94,18 +92,19 @@ jobs:
java -version
mvn -v
if [[ "$CIRCLE_BRANCH" != "" && "$CIRCLE_BRANCH" != "main" ]]; then
mvn -B clean install -Pcloud,fedDev
mvn -B clean install -PfedDev,withClassic
else
mvn -B clean install
mvn -B clean install -PwithClassic
fi
- save_cache:
paths:
- ~/.m2
key: maven-repo-v2-cloud-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
key: maven-repo-v2-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- persist_to_workspace:
root: /home/circleci/build
paths:
- all/target/*.zip
- classic/all/target/*.zip
- dependencies/aem-core-cif-components/examples/bundle/target/*.jar
- store_test_results:
path: core/target/surefire-reports
Expand All @@ -114,41 +113,6 @@ jobs:
- codecov/upload:
flags: unittests

build-classic:
executor: cif_executor
working_directory: /home/circleci/build
steps:
- checkout
- restore_cache:
keys:
- maven-repo-v2-classic-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- maven-repo-v2-classic-
- maven-repo-v2-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- maven-repo-v2-
- run:
name: Update permissions
command: sudo chown -R circleci /usr/local/lib/node_modules
- *install_components
- run:
name: Build
command: |
java -version
mvn -v
if [[ "$CIRCLE_BRANCH" != "" && "$CIRCLE_BRANCH" != "main" ]]; then
mvn -B clean install -Pclassic,fedDev
else
mvn -B clean install -Pclassic
fi
- save_cache:
paths:
- ~/.m2
key: maven-repo-v2-classic-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- persist_to_workspace:
root: /home/circleci/build
paths:
- all/target/*.zip
- dependencies/aem-core-cif-components/examples/bundle/target/*.jar

integration-test-655:
executor: test_executor_655
environment:
Expand Down Expand Up @@ -212,8 +176,6 @@ jobs:
- checkout
- restore_cache:
keys:
- maven-repo-v2-cloud-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- maven-repo-v2-cloud-
- maven-repo-v2-{{ arch }}-{{ .Branch }}-{{ checksum "pom.xml" }}
- maven-repo-v2-
- run:
Expand All @@ -230,20 +192,14 @@ workflows:
filters:
tags:
only: /.*/
- build-classic:
context:
- CIF Artifactory Cloud
filters:
tags:
only: /.*/
- integration-test-655:
context:
- CIF Artifactory Cloud
filters:
tags:
only: /.*/
requires:
- build-classic
- build
- integration-test-cloudready-with-addon:
context:
- CIF Artifactory Cloud
Expand All @@ -267,14 +223,13 @@ workflows:
tags:
only: /.*/
requires:
- build-classic
- build
- deploy-sample:
context:
- CIF Artifactory Cloud
- CIF GitHub
requires:
- build
- build-classic
filters:
branches:
ignore: /.*/
Expand Down
4 changes: 0 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -100,10 +100,6 @@ node/
# Tests
coverage/

# Generated files for the 'cloud' and 'classic' profiles
ui.content/src/main/content/jcr_root/conf/venia/settings/cloudconfigs/commerce/.content.xml
ui.content/src/main/content/META-INF/vault/filter.xml

# UI Tests
ui.tests/test-module/reports
test-reports
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ The project comes with the auto-public repository configured. To set up the repo

The Venia demo is only released on Github but not on Maven Central like other projects like the CIF components. To perform a release, we use a dedicated profile to make sure all modules versions are updated:

`mvn release:prepare release:clean -Prelease-prepare`
`mvn release:prepare release:clean`

Releases must be done on the `main` branch.

Expand Down
Loading