Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Error in pipeline: authorization denied by plugin pipelines

Carlos Gomez
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
September 6, 2018

Hi!, I created a simple pipeline to run "docker-compose up" and then "docker-compose down", everything is correct, the images get build correctly, but it throws an error when is going to create the container. the error is:

ERROR: for build_db_1 Cannot create container for service db: authorization denied by plugin pipelines: -v only supports $BITBUCKET_CLONE_DIR and its subdirectories

 

I have no clue of what this means. The pipeline is the following:

image: docker:stable
options:
docker: true
pipelines:
default:
-
step:
script:
-
chmod 777 ci/dependencies.sh
-
ci/dependencies.sh
-
docker-compose up -d --build
-
docker-compose down

dependencies.sh

#!/usr/bin/env sh

set -eu

# Add python pip and bash
apk add --no-cache py-pip bash

# Install docker-compose via pip
pip install --no-cache-dir docker-compose
docker-compose -v
 

 What is this error telling me? Thank you!

2 answers

2 votes
Steven Vaccarella
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
September 18, 2018

Hi Carlos,

There are some restrictions on which docker options you're allowed to use in Pipelines (necessary to maintain security in the shared Pipelines environment). Your docker compose configuration is attempting to map a volume with a source that's outside your build directory (see Running Docker Commands on this page for a full list of restrictions: https://confluence.atlassian.com/bitbucket/run-docker-commands-in-bitbucket-pipelines-879254331.html).

What does your docker-compose.yml file look like?

Cheers,
Steven

palamunder
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 29, 2019 edited

I have the same problem

 

Here is how my docker-compose looks like

 

version: '3'
services:
mosquitto:
build: .
volumes:
-
mosquitto_data:/mosquitto/data
-
mosquitto_log:/mosquitto/log
expose:
- 1883
-
9001
ports:
- 9001:9001
- 1883:1883

 

 

I have even set my repository variables
`BITBUCKET_CLONE_DIR` to be ` / `

Like 2 people like this

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, compass, developer experience, devex, platform engineering, internal developer platform, component catalog, atlassian learning, productivity tools, developer productivity, software architecture, compass webinar, engineering teams

Discover how Compass drives DevEx and productivity at Atlassian 🏃🏻‍♂️

Learn why Compass was built to tackle dev experience at scale. See how Atlassian uses it to boost visibility, reduce cognitive load, and drive consistency—plus tips to get started and customize your IDP for stronger team engagement.

Join the webinar ✨
AUG Leaders

Atlassian Community Events