11 votes
Accepted

Is running docker-compose not supported in BitBucket?

Here is my solution: (bitbucket-pipelines.yml) pipelines: default: - step: script: - export DOCKER_COMPOSE_VERSION=1.18.0 - export DOCKER_COMPOSE_URL=https://github....
user avatar
10 votes
Accepted

What are best practices for using Ansible Vault on public CI's and Source Control Repositories like BitBucket?

--vault-password-file can instead point to an executable script that writes to stdout. This little-known feature should solve your problem. First, write a simple, executable script that prints a ...
user avatar
6 votes

how to automatically create a subdomain for every pull request

We do this at work. We have a small server, let's call it the receiver, it's the target of the GitHub webhook events. It runs a small application that parses the payload and incorporates logic around ...
user avatar
6 votes

How to close a branch by default after a pull request has been merged in Bitbucket?

What I really want is to add a comment to the accepted answer, but I don't have enough reputation to do so. So I'll note it here. I've closed BSERV-10344 because it's in the wrong tracker. This ...
user avatar
6 votes
Accepted

Git & Jenkins: get latest green commit on branch

You don't make any mention of the scripting language you want to use, so I will talk specifically about the HTTP requests to the BitBucket API: Assumptions If you have a BitBucket Repository that ...
user avatar
6 votes

Is running docker-compose not supported in BitBucket?

We are less likely to see support of native docker-compose integration because pipelines API is a custom implementation of similar functionality, and also because possible security issues, but looks ...
user avatar
  • 657
5 votes
Accepted

Bitbucket Webhook plugin for Jenkins - differentiate between branches

I believe it is now possible to configure the webhook on per-repo basis: https://mohamicorp.atlassian.net/wiki/spaces/DOC/pages/381419546/Configuring+Webhook+To+Jenkins+for+Bitbucket+Bitbucket+Branch+...
user avatar
4 votes
Accepted

Why does `docker-login` fail in BitBucket pipelines?

At the moment the docker login and docker push commands are only available to Pipelines Alpha members. You can read about the features available to Alpha at "Pipelines Alpha". In order to ...
user avatar
4 votes

What approach should I follow for adopting continuous integration?

I am in a similar pair of shoes as you - I am currently, slowly, getting into the DevOps topics after having many, many years of conventional development (and close connections to conventional ops) ...
user avatar
  • 4,716
4 votes

How to close a branch by default after a pull request has been merged in Bitbucket?

For Bitbucket Server you can set this up on a project or repo-level under Settings > Branches (under the Workflow section), scroll to the bottom and tick this setting on and press save: So all in ...
user avatar
  • 141
4 votes
Accepted

How to close a branch by default after a pull request has been merged in Bitbucket?

Apparently selecting the Close branch option in the very dialogue illustrated in your question will actually delete the branch as well. From Why only "Close" a branch instead of "Delete" it?: Ben ...
user avatar
4 votes
Accepted

How to bind ports for docker container in bitbucket pipelines?

Try running with -d detached flag docker run -td -p 3000:3000 -p 6379:6379 -p 8983:8983 my_dockerhub/image # here ^ Containers started in detached mode exit when the root process used to run ...
user avatar
  • 156
4 votes

Trigger jenkins pipeline job with Bitbucket hook

If you just need generic post-receive hooks, you can just do a regular web hook and hit the build API endpoint. For instance, if the name of your Jenkins server is jenkins.example.com and the name of ...
user avatar
  • 2,743
3 votes
Accepted

Is it possible to create a robot account in bitbucket without creating a new email account?

After doing some research and comparing various documents it seems that a bot account is basically a real user account and needs a separate email account in order to create such an account as using an ...
user avatar
  • 12.6k
3 votes

What approach should I follow for adopting continuous integration?

As you are already using Bitbucket, Bitbucket pipelines could be useful. What languages are supported? Node, Ruby, Python, PHP, and more. Anything you can run in a Docker container is ...
user avatar
  • 12.6k
3 votes

Jenkins Pipeline and stash Pull Request Builder not working on PR create/update

To expand on the answer above - try using: branch: "origin/pr/${pullRequestId}/from" Because in groovy, string interpolation is not done for simple strings - i.e. strings within single quotes. See ...
user avatar
3 votes

Jenkins Pipeline and stash Pull Request Builder not working on PR create/update

In groovy script, you need to reference environment variables in a different way than in bash. So probably this line is causing trouble: branch: ('origin/pr/${pullRequestId}/from') Try using: ...
user avatar
  • 31
3 votes

Is running docker-compose not supported in BitBucket?

I managed to use docker-compose to push images to a remote host by using the following image. tmaier/docker-compose:latest This is the basic docker image with docker-compose installed. My bitbucket-...
user avatar
3 votes

How can I automatically post Codefresh build results to pull requests in Bitbucket?

One could update the build status in bitbucket as follows: Adding a build result to a commit To associate a build result with a particular commit, you need to POST a JSON object to the build ...
user avatar
  • 12.6k
3 votes

Git & Jenkins: get latest green commit on branch

In a typical Continuous Delivery/Deployment pipeline you would have the following happen: Developer pushes one or more commits, or, a pull request is merged. Jenkins automatically builds and executes ...
user avatar
3 votes

Jenkins & Bitbucket; cancel previous build if new commit made to same branch?

Note: this answer comes from my background of building custom solutions, it's not a config-only one, which, if available, would obviously be preferable. But it's maybe something to consider otherwise. ...
user avatar
3 votes

Jenkins shows "No changes in any of the builds."

Temporary workaround Instead of calculating changes between builds compare changes against specific branch. Open job configuration Go to Source Code Management -> Git -> Additional Behaviours Add ...
user avatar
3 votes

Deploying and testing features on a server by more than one developer

Since you have a single released version product one thing to consider would be keeping the Develop branch or not: keeping it would have the advantage that at any moment you can bring in a hotfix in ...
user avatar
2 votes

Is running docker-compose not supported in BitBucket?

bitbucket-pipelines.yml image: python:3.8.1 pipelines: branches: "**": - step: name: Build services: - docker caches: - docker ...
user avatar
  • 121
2 votes
Accepted

Jenkins Testing PR's - allowing broken builds

On GitHub - you can't. Basically, their PRs are temporary branches, and there's no check if base commit is HEAD of branch to merge in. This problem is solved with gating systems like Zuul, which puts ...
user avatar
2 votes

Bitbucket Webhook plugin for Jenkins - differentiate between branches

You could: prune your branches. (guessing you'd have done this by now if feasible.) implement Jenkinsfile, a code-driven pipeline, and simply remove the jenkinsfile from the branches you don't want ...
user avatar
2 votes
Accepted

how to automatically create a subdomain for every pull request

this setup worked perfectly for me using aws code deploy:
user avatar
  • 453
2 votes

What approach should I follow for adopting continuous integration?

You've chosen a fairly difficult stack to support. WAMP is largely used in dev environments, and the windows builds of mysql, php, and apache typically lag their Linux counterparts by a significant ...
user avatar
2 votes
Accepted

What are best practices of deploying docker-compose using Ansible?

Instead of using a symlink that will be stored as is in BitBucket one could use: - name: Copy docker-compose.yml copy: src: ../../../../docker-compose.yml dest: /path/to/docker-compose.yml
user avatar
  • 12.6k
2 votes
Accepted

Is it possible to show a code coverage badge in bitbucket repositories?

You can certainly show a code coverage badge in a bitbucket repository, but it would have to be from an external source like jenkins, codeclimate, etc. According to your link, if you are using ...
user avatar
  • 650

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