Skip to main content
7 votes

Deploy incremental changes using Github and Jenkins

There are a bunch of third party solutions offering native CI for Salesforce. Full disclosure that I lead one of the companies building one but I'll provide you with all options so you can investigate....
Kevin Boyle's user avatar
  • 1,311
7 votes
Accepted

Any way to get consistent test counts when parallel testing is used?

I just completed a parallel test run. Note that all these tests currently pass when run individually or in the synchronous test mode. After the parallel run I then ran the same SOQL query you are: ...
Daniel Ballinger's user avatar
6 votes
Accepted

Can't get sfdx force:package:install to block in a Jenkinsfile

Some installations prompt you for permissions/confirmations. Check the build failure log and see if there's some pending prompting during your Add other packages stage. If that's the case, add the --...
Francesco Pitzalis's user avatar
6 votes

ERROR running force:source:deploy: InvalidPackageDirectory

I just got the same error and was puzzled myself as to why it stopped working all of a sudden when I haven't changed the sfdx-project.json at all. It turned out that I deleted one of the folders ...
smukov's user avatar
  • 5,613
5 votes

Installing Jenkins on Heroku

I have tried installing Jenkins and mostly because of free account restrictions I was not getting enough RAM to install jenkins on Heroku. Free account can give only 512MB ram which is not sufficient ...
Kiran Machhewar's user avatar
5 votes
Accepted

How to clone a Jenkins job in a different folder?

You can do this, but you have to start with typing the folder name: /Folder Name/Deploy to Preprod
Koen Wesselman's user avatar
4 votes
Accepted

Jenkins Salesforce CI server setup

You have number of options here 1.Using EC2 EC2 is from amazon and have seen number of enterprises using EC2 2.Using Google Cloud Containers https://cloud.google.com/container-engine/ 3....
Mohith Shrivastava's user avatar
4 votes

Jenkins CI with Salesforce: how to generate package.xml which only contains changed metadata files

After learning some simple shell commands, I wrote some shell scripts to generate package.xml dynamically based on git commit and it works well! Now we can deploy codes only when they are changed! #!/...
Allen Li's user avatar
  • 880
4 votes

Any way to get consistent test counts when parallel testing is used?

The underlying bug that appears to be the culprit in this issue has been published as Known Issue W-7834236. Some Apex unit tests fail in a way that only shows in specific test UIs. The ...
David Reed's user avatar
  • 93.4k
4 votes
Accepted

Error on secret-tool for sfdx force:auth:jwt:grant

You have to export keychain before executing session using secret tool for CI/headless server. Change export SFDX_USE_GENERIC_KEYCHAIN=true To export SFDX_USE_GENERIC_UNIX_KEYCHAIN=true devolpers ...
Vishal Deshmukh's user avatar
3 votes
Accepted

EAI_AGAIN errors when pushing or running unit tests in a newly created scratch org from Jenkins CI using SFDX

Tried adding 3 minute, 6 minute, 9 minute etc delay for each parallel build so that the builds are not at the same phase at the same time. Resulted in one clean build but looks like that was just ...
Keith C's user avatar
  • 137k
3 votes
Accepted

Unable to authorise dev hub on jenkins with it hanging on the force:auth:jwt:grant step

Are you by any chance using MacOS? It could be due to an issue that the DX tooling cannot connect to the keychain as it's attempting to display a dialog window to indicate this and results in it ...
Adam's user avatar
  • 361
3 votes

Deploy incremental changes using Github and Jenkins

Its very late to answer but here is my setup which works: Code Merged -> Create a deploy folder -> checkout the target branch in workspace - > Merge the current branch to target branch (no commit)-> ...
Nagendra K S's user avatar
3 votes
Accepted

Error: Cannot change which global value set this picklist uses

I don't know how and why but when I changed the global picklist API name to match the field name. It worked! <fields> **<fullName>CallStatus_MDE__c</fullName>** <...
Vibhu Dadhichi's user avatar
3 votes
Accepted

Create developer sandbox from Jenkins

You want SandboxInfo via the Tooling API against your production org. Represents a sandbox. SandboxInfo enqueues a sandbox for creation or refresh. A create operation on SandboxInfo represents ...
Daniel Ballinger's user avatar
3 votes

Advantage of incremental delivery

Incremental packages reduce bandwidth usage and the amount of time needed to validate the package. Also, if your update only covers non-unit-test features, you can skip running unit tests, which may ...
sfdcfox's user avatar
  • 500k
3 votes

CI/CD with package.xml: how to deploy incrementally?

Script Level There's essentially a couple of steps involved to this process of doing a delta deployment. The first is to identify the changed components. If you're working with Git and GitLab ...
David Reed's user avatar
  • 93.4k
3 votes

Setting up Jenkins Pipeline with SFDX

On item 1), based on How to get just one file from another branch add this after your clone: git checkout ${someBranch} -- package.xml On Item 2), I don't really follow what you are doing so can't ...
Keith C's user avatar
  • 137k
3 votes
Accepted

CI Continuous Integration with AWS & Jenkins

Jenkins is the CI software that runs on some form of compute platform (PC, server, whatever - something with an OS, storage and a CPU with memory); AWS is being used to provide a virtual server on ...
Phil W's user avatar
  • 37.5k
3 votes
Accepted

Deploying to Scratch Org in Jenkins pipeline with ant

I recommend you to use sfdx commands instead of the old ant. sfdx still will be able to deploy your classic metadata package using a sfdx:mdapi:deploy command. Use the mdapi commands to retrieve and ...
Oleksandr Berehovskyi's user avatar
3 votes

Incremental deployment using SFDX CLI, Jenkins and GitHub

sfdx force:mdapi:deploy is not incremental. Whatever is in the deploy directory (and the package.xml, which is required and must specify everything in the deploy directory) is deployed. It is ...
Derek F's user avatar
  • 63.2k
2 votes
Accepted

Deploy incremental changes using Github and Jenkins

Process that we finally implemented in Jenkins Source Code Management Connect to your git repository Execute shell Script will get the previous commit (last one that is deployed) from a file and ...
Nielsm's user avatar
  • 2,094
2 votes

ANT Migration to add namespace to packaging org?

This happens automatically. There's typically no need to do anything special in your build.properties or build.xml files, or any special configuration you need to do, unless you are also managing the ...
sfdcfox's user avatar
  • 500k
2 votes
Accepted

Jenkins Build Failure

Usually this means that your build.xml file can't find the salesforce ant jar file. Check out https://developer.salesforce.com/docs/atlas.en-us.daas.meta/daas/forcemigrationtool_install.htm
ArtieBrosius's user avatar
2 votes
Accepted

Is it possible to exclude files in package.xml in ANT deployment?

The Ant Migration Tool itself does not have the capability to do that. It basically just zips the directory, calls the metadata deploy() call, waits for the results, and parses the response. It doesn'...
sfdcfox's user avatar
  • 500k
2 votes
Accepted

How can I simplify Jenkinsfile-based SFDX builds by using a Jenkins Shared Library?

My colleague has built this open source Jenkins Shared Library sfdx-jenkins-shared-library to solve this problem specifically for SFDX builds. See his blog post Streamlining SFDX on Jenkins that ...
Keith C's user avatar
  • 137k
2 votes
Accepted

Jenkins, Docker and SFDX: Share SFDX "cache" between docker containers

I found the solution: mount a volume for container folder /root/.sfdx With this volume, SFDX keep in memory the scratch orgs created and used between Docker containers. Example: -v /tmp/myvol_sfdx:/...
Nicolas Vuillamy's user avatar
2 votes
Accepted

Any way to deploy extra components on top of a sfdx force:source:push?

Thanks sfdcfox! This command allows extra files to be deployed on top of a sfdx force:source:push with the files located in an arbitrary folder: sfdx force:source:deploy --sourcepath config-...
Keith C's user avatar
  • 137k
2 votes
Accepted

SFDX DSL for Jenkins pipelines?

Keith Clarke: Now there is, what you started: https://github.com/claimvantage/sfdx-jenkins-shared-library. I'm glad to contribute to that. Spreading the word at https://medium.com/@jefersonchaves/...
Jeferson Chaves's user avatar
2 votes

SFDX DSL for Jenkins pipelines?

I have the sample pipeline that I used to test Jenkins on localhost, hope it can be useful for you. You will need to change environment variables that are hardcoded to the System environments on the ...
m_konyk's user avatar
  • 556

Only top scored, non community-wiki answers of a minimum length are eligible