Comments (4)
Usually you get that if you are using a custom connected app with an invalid callback URL. I'm assuming you are also using a custom connected app in the sfdxurl:store as well?
More specifically, the callback url on the connected app should be http://localhost:1717/OauthRedirect
from sfdx-travisci.
To save anyone some potential hair-pulling, the OAuth callback URL for your custom connected app is case-sensitive, at least for the purposes of the force:org:create
command :-|
So even though you will be able to authenticate through a custom connected app with a callback URL such as http://localhost:1717/OAuthRedirect
-- using both force:auth:web:login
and force:auth:jwt:grant
-- you will get that invalid Callback URL error when next trying to spin up a scratch org.
http://localhost:1717/OauthRedirect
it must be. That little a
was a big pain in the A
.
from sfdx-travisci.
Out of curiousity, I decided to try as well with the JWT token and this is what I get after a successful login in Travis CI.
Not too sure where I am suppose to set up a callback URL. Any clue?
And here is my .travis.yml
file:
sudo: true
dist: trusty
cache: false
before_install:
- openssl aes-256-cbc -K $encrypted_55cd0711f34c_key -iv $encrypted_55cd0711f34c_iv -in config/server.key.enc -out config/server.key -d
- wget -qO- https://developer.salesforce.com/media/salesforce-cli/sfdx-linux-amd64.tar.xz
| tar -xvJf -
- ./sfdx/install
- export SFDX_AUTOUPDATE_DISABLE=true
- export SFDX_USE_GENERIC_UNIX_KEYCHAIN=true
- export SFDX_DOMAIN_RETRY=300
- export PATH=./sfdx/$(pwd):$PATH
- sfdx force:auth:jwt:grant --clientid $CLIENT_ID --jwtkeyfile config/server.key --username $USERNAME --setdefaultdevhubusername -a HubOrg || travis_terminate 1
script:
- sfdx force:org:create -v HubOrg -s -f scratchdef.json -a Qci || travis_terminate 1
- sfdx force:source:push -u Qci
- sfdx force:apex:test:run -u Qci -c -r human
- sfdx force:org:delete -u Qci -p
from sfdx-travisci.
@amphro Was successful with this. Thanks so much!
from sfdx-travisci.
Related Issues (19)
- TravisCI build Error HOT 2
- Deleting Scrach Org failed with
- Build Error - YAML Line 16 HOT 4
- Travis build fails due to use of --wait flags
- Travis build fails due to depreciated settings in the project-scratch-de.json
- ERROR running force:auth:jwt:grant: We encountered a JSON web token error, which is likely not an issue with Salesforce CLI. Hereβs the error: error:0906D06C:PEM routines:PEM_read_bio:no start line HOT 4
- travis login error from command line gitbash HOT 1
- Scratch org definition is missing a closing } for the settings property
- travisci build error HOT 1
- Error in Travis CI build, bad decrypt, digital envelope routines:EVP_DecryptFinal_ex:wrong final block length:evp_enc.c:518: HOT 1
- NoMethodError: undefined method `each_pair'
- Org creation and/or run test commands timeout or take much longer HOT 4
- Cannot get the build to fail with force:apex:test-run HOT 9
- Need valid link to trailhead module HOT 1
- Tar ball file issue travis
- Need link to the final Dev Guide for JWT-Auth setup HOT 1
- Travis CI builds failing on scratch org creation script HOT 1
- Error when generating an RSA private key HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sfdx-travisci.