How to authenticate through basic auth?

Viewed 1976

When I try to build a docker image which pulls a base-trusty package from internal server I get:

ERROR: Service 'yldrdashboardservice' failed to build: Get https://repo.domain.com/v2/base-trusty-python27/manifests/latest: no basic auth credentials

This is how I build the image in docker-compose.yml:

yldrdashboardservice:
    container_name: yldrdashboardservice
    build:
        context: ./yldrdashboardservice
        dockerfile: Dockerfile
    environment:
        APP_ENV: local
    ports:
        - "5000:6003"
    restart: always
    links:
        - mysql
        - mongodb

How do I make it prompt for authentication here? Obviously I don't want to store my credentials as raw text in docker-compose.yml.

0 Answers
Related