skip to Main Content

Docker – Dokcer build image –secret in Jenkins Pipeline

Here is my dockerfile FROM node:20-alpine3.18 WORKDIR /app COPY package*.json .npmrc ./ RUN --mount=type=secret,id=npmrc NPM_TOKEN=$(cat /run/secrets/npmrc) npm ci --production COPY . . EXPOSE 8000 CMD ["npm", "run", "start"] Here is my Jenkinsfile and docker-compose jenkins: container_name: jenkins image: jenkins/jenkins:lts privileged:…

VIEW QUESTION

Docker – Secrets in Compose: Environment variable has file path as value instead of its content

I'm trying to use Secrets with Docker Compose Here is my Docker Compose (only the relevant parts): version: "3.8" services: My-Service: build: context: ./.. dockerfile: ./docker/Dockerfile image: my-app/api container_name: my-app-api environment: ASPNETCORE_ENVIRONMENT: Docker ASPNETCORE_URLS: http://+:8080 Swagger__Authentication__ClientSecret_FILE: /run/secrets/my_secret secrets: - my_secret…

VIEW QUESTION

Can't connect to mongodb for Unifi Network Application in Docker

I can't get the Unifi Network Application to work. I have two docker compose files: One file is to create the mongodb part, unifi_db.yml --- version: "3.1" services: unifi-db: image: docker.io/mongo:4.4.18 ports: - 27017:27017 environment: MONGO_INITDB_ROOT_USERNAME: admin MONGO_INITDB_ROOT_PASSWORD_FILE : /run/secrets/mongodb_admin_user_password…

VIEW QUESTION
Back To Top
Search