我正在尝试为示例反应项目构建一个简单的管道。这是我的 .gitlab-ci.yml 文件
image: node:12
stages:
- build
- test
build_react:
stage: build
script:
- echo "Building deploy package"
- yarn install
- yarn build
- echo "Build successful"
artifacts:
expire_in: 1 hour
paths:
- build
test_react:
stage: test
needs: [build_react]
script:
- echo "Testing project"
- yarn test --watchAll=false
- echo "Test successful"
Run Code Online (Sandbox Code Playgroud)
构建通过了,但在测试阶段它失败了,抱怨
$ react-scripts test --watchAll=false
/bin/sh: 1: react-scripts: not found
Run Code Online (Sandbox Code Playgroud)
我收到此错误:无法加载源https://pkgs.dev.azure.com/xxxxx/_packaging/xxxxx/nuget/v3/index.json的服务索引。响应状态码并不表示成功:401(未经授权)。)
我正在尝试从其他组织的天蓝色工件恢复包。在此输入图像描述
错误日志:38 个包到packages.config 项目
Unable to find version '1.0.976930' of package 'xxxx.Security.Eso.Web.DevSignOn'.
https://api.nuget.org/v3/index.json: Package 'xxxx.Security.Eso.Web.DevSignOn.1.0.976930' is not found on source 'https://api.nuget.org/v3/index.json'.
https://pkgs.dev.azure.com/xxxx/_packaging/yyyy/nuget/v3/index.json: Unable to load the service index for source https://pkgs.dev.azure.com/xxxx/_packaging/yyyy/nuget/v3/index.json.
Response status code does not indicate success: 401 (Unauthorized).)
Run Code Online (Sandbox Code Playgroud)
我尝试了这些解决方案,但没有运气: 1. https://mallibone.com/post/private-nuget-feed-azure-devops 2. https://learn.microsoft.com/en-us/azure/devops/pipelines /packages/nuget-restore?view=azure-devops
我们在一个非常大的组织中工作,有许多数据库(多种类型)、许多模式、许多用户。
LB 是否必须使用某些源代码管理(当组织中存在许多用户并使用相同的数据库、相同的架构等时锁定文件)?
在一个非常大的组织、许多并发用户中使用 LB 的最佳实践是什么?
SQLCL可以通用sql格式类型还是只是xml格式类型?
是否有与 SQL Developer 的集成?我的意思是,假设用户通过 sql Developer 更改对象,那么会发生什么?
continuous-integration liquibase continuous-deployment devops
考虑一个带有prebuild和build阶段的虚拟 gitlab 作业。
stages:
- prebuild
- build
Run Code Online (Sandbox Code Playgroud)
该阶段的唯一工作prebuild是为后续阶段创建和缓存依赖项。prebuild仅当 python 文件发生更改时才会触发该阶段requirements.txt。该build阶段有一个cache:policyof pull,这意味着它遵循prebuild缓存。例如,假设缓存由共享的单个文件组成sharedfile:
prebuild_job:
cache:
policy: pull-push
rules:
- changes:
- requirements.txt
paths:
- sharedfile
script:
- echo "FOOBAR" > sharedfile
build_job:
cache:
policy: pull
paths:
- sharedfile
script:
- cat sharedfile
Run Code Online (Sandbox Code Playgroud)
这就是我想要的——仅在更改并使用其输出prebuild时触发(在本例中但实际上是一个完整的 python 虚拟环境)。这非常有效,直到通过Clear Runner Caches按钮在 gitlab 上手动清除缓存,然后我们必须手动重新运行预构建步骤,否则构建将继续失败,因为预构建在缓存清除后从未重新触发。requirements.txtbuildsharedfile
我们如何设置规则或解决方法,以便prebuild_job …
当我了解天蓝色管道时,我几乎到处都会
遇到术语“编译时”和“运行时”。
但是,我仍然没有找到关于它们的明确解释。
我在微软的文档中找到了这个页面,但它并没有非常清楚地解释这些术语。
如果有人可以在Azure Pipelines 的整个运行顺序的上下文中解释这些术语,我会很高兴。
谢谢!
我有一个包含通常阶段的发布管道
开发 -> 测试 -> 预生产 -> 生产
我想知道是否有一种方法可以确保只有主分支可以一直升级到生产,以避免从功能发布和开发分支在生产环境中结束。
我需要在 Dockerfile 中传递一个环境变量作为 LABEL,我的 Dockerfile 如下所示:
FROM nginx
LABEL maintainer="blabla"
ENV GROUP="default"
#Checking if Label values can be set from ENV Variables
LABEL group="${GROUP}"
Run Code Online (Sandbox Code Playgroud)
下面的命令传递构建并运行 docker 文件环境变量:
docker build -t nginx:test_label .
Run Code Online (Sandbox Code Playgroud)
docker run -d -e GROUP="mygroup" nginx:test_label
Run Code Online (Sandbox Code Playgroud)
但是在检查容器时,它给了我标签值而default不是 mygroup。
我究竟做错了什么?
我正在查看天蓝色触发器文档,但仍然无法找到合适的解决方案。在管道 1 执行过程中,如何触发管道 2,等待其成功完成或失败,并根据管道 2 的结果继续执行管道 1 或失败?
azure devops azure-devops azure-pipelines azure-pipelines-release-pipeline
我们已经使用 docker-compose 一年了,没有遇到任何问题。在过去的一周里,我们每个人都开始遇到与权限相关的奇怪错误
at internal/main/run_main_module.js:17:47 : Error: EPERM: operation not permitted, open <PATH TO FILE>
仅当我切换分支时才会发生
组成结构:
version: "2.4"
# template:
x-base: &base-service-template
env_file:
- ./.env
working_dir: /app/
volumes:
- ./src:/app/src:cached
services:
service1:
image: service1
<<: *base-service-template
service2:
image: service2
<<: *base-service-template
Run Code Online (Sandbox Code Playgroud)
我们都在 OSX 上工作。我们尝试授予 docker 对文件系统的权限,但仍然不起作用。
但有一些东西是有效的。重新启动守护进程。但我不想每次切换分支时都重新启动守护进程
附加信息:
每个服务的 docker 文件库如下所示
FROM node:12-alpine as builder
ENV TZ=Europe/London
RUN npm i npm@latest -g
RUN mkdir /app && chown node:node /app
WORKDIR /app
RUN apk add --no-cache python3 make g++ …Run Code Online (Sandbox Code Playgroud) 我有以下管道:
我在将源 (GitHub) 阶段的输出工件链接到 StepFunctions 阶段的输入工件时遇到问题。
我的目标是让 StepFunctions 阶段能够访问源阶段输出到的最后一个 zip 文件名(在 S3 存储桶上)。
我已经尝试过:
在 Source 阶段定义命名空间以在 StepFunctions 阶段使用它。链接到文档:https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-variables.html
阅读此文档:https://docs.aws.amazon.com/codepipeline/latest/userguide/tutorials-step-functions.html
新案例:使用 Lambda 代替 StepFunctions 进行阶段,它从源阶段接收到 S3 文件夹和其他元数据的链接,而 StepFunctions 则不会。
github amazon-web-services devops aws-codepipeline aws-step-functions
devops ×10
azure ×3
azure-devops ×3
docker ×2
gitlab ×2
azure-pipelines-release-pipeline ×1
dockerfile ×1
github ×1
gitlab-ci ×1
liquibase ×1
node.js ×1
nuget ×1