gitlab-ci

Prevent infinite loop with Gitlab pipeline and git pushing

时光总嘲笑我的痴心妄想 提交于 2020-08-08 05:43:10
问题 I have a project where I have 4 environments (dev, test, staging and prod) and we have branches for each (develop, test, staging master respectively). We use npm version to bump version in package.json but also add a git tag. After that we run the build and on success of that, we push the commit and tag created by the npm version command. So in my pipeline job, I have this (simplified): dev build: stage: build only: - develop@username/reponame script: - npm version patch -m "[ci skip] %s" -

Can't generate signed APK in GitLab CI

廉价感情. 提交于 2020-08-05 09:47:04
问题 I'm testing gitlab ci/cd and I'm trying to build a signed APK but my script failed. What should I change or add? I add variables KEYSTORE_FILE, KEYSTORE_PASSWORD, KEY_ALIAS, KEY_PASSWORD with values. assembleRelease: stage: release script: - echo $KEYSTORE_FILE | base64 -d > my.keystore - ./gradlew assembleRelease -Pandroid.injected.signing.store.file=$(pwd)/my.keystore -Pandroid.injected.signing.store.password=$KEYSTORE_PASSWORD -Pandroid.injected.signing.key.alias=$KEY_ALIAS -Pandroid

VirtualBox executer fails with “prepare environment: Process exited with status 1”

那年仲夏 提交于 2020-08-05 09:37:41
问题 I registered the VirtualBox CI runner using gitlab-runner register and by choosing virtualbox as an executor. However, if I start the runner pipeline in Gitlab, it fails with the following error: What would be causing this error and how to fix it? Here's a link mentioned in the error message: https://docs.gitlab.com/runner/shells/index.html#shell-profile-loading P.S: I'm using macOS 10.15.5 and the VirtualBox runs Ubuntu 20.04 LTS. 回答1: The documentation mentions: For certain executors, the

VirtualBox executer fails with “prepare environment: Process exited with status 1”

耗尽温柔 提交于 2020-08-05 09:37:17
问题 I registered the VirtualBox CI runner using gitlab-runner register and by choosing virtualbox as an executor. However, if I start the runner pipeline in Gitlab, it fails with the following error: What would be causing this error and how to fix it? Here's a link mentioned in the error message: https://docs.gitlab.com/runner/shells/index.html#shell-profile-loading P.S: I'm using macOS 10.15.5 and the VirtualBox runs Ubuntu 20.04 LTS. 回答1: The documentation mentions: For certain executors, the

Cannot connect to the Docker daemon at tcp://localhost:2375/. Is the docker daemon running. On GitLab

▼魔方 西西 提交于 2020-07-23 08:09:21
问题 I'm trying to build the CI pipeline in GitLab. I'd like to ask about the docker for work in GitLab CI. from this issue : https://gitlab.com/gitlab-org/gitlab-runner/issues/4501#note_195033385 I'm follow the instruction for both ways. With TLS and not used TLS. But It's still stuck. Which in same error Cannot connect to the Docker daemon at tcp://localhost:2375/. Is the docker daemon running I've try to troubleshooting this problem. follow by below, 1) enable TLS Which used .gitlab-ci.yml and

GITLAB CI Error loading key “/dev/fd/63”: invalid format ERROR: Job failed: exit code 1

断了今生、忘了曾经 提交于 2020-07-18 10:38:17
问题 Here is my code giltlab-ci.yml : before_script: ## ## Install ssh-agent if not already installed, it is required by Docker. ## (change apt-get to yum if you use an RPM-based image) ## - 'which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )' ## ## Run ssh-agent (inside the build environment) ## - eval $(ssh-agent -s) ## ## Add the SSH key stored in SSH_PRIVATE_KEY variable to the agent store ## We're using tr to fix line endings which makes ed25519 keys work ## without

How to specify in gitlab-ci.yml the memory for a job?

风流意气都作罢 提交于 2020-07-08 00:26:43
问题 I have a job that requires more memory than the default configuration to compile a large project. I use hosted shared runners. Is there a way to specify in gitlab-ci.yml the required memory per job ? 回答1: This feature is not currently available, and the development is being tracker in https://gitlab.com/gitlab-org/gitlab-runner/issues/2902 来源: https://stackoverflow.com/questions/60114468/how-to-specify-in-gitlab-ci-yml-the-memory-for-a-job

How to specify in gitlab-ci.yml the memory for a job?

谁说我不能喝 提交于 2020-07-08 00:24:12
问题 I have a job that requires more memory than the default configuration to compile a large project. I use hosted shared runners. Is there a way to specify in gitlab-ci.yml the required memory per job ? 回答1: This feature is not currently available, and the development is being tracker in https://gitlab.com/gitlab-org/gitlab-runner/issues/2902 来源: https://stackoverflow.com/questions/60114468/how-to-specify-in-gitlab-ci-yml-the-memory-for-a-job

Gitlab CI use ed25519 private key

故事扮演 提交于 2020-07-07 11:24:48
问题 I'm trying to do some stuff within Gitlab CI on a remote server. When using RSA keys everything works fine, but when I try using ED25519 keys, I'm stuck: Running with gitlab-ci-multi-runner 9.3.0 (3df822b) on Internal Runner (079281fd) Using Docker executor with image 1drop/docker:git ... Using docker image sha256:b9cf0ca386341048f8696d950123e20b5d6583c190f266aacb25b6d3d4736028 for predefined container... Pulling docker image 1drop/docker:git ... Using docker image 1drop/docker:git ID=sha256

Gitlab CI use ed25519 private key

自古美人都是妖i 提交于 2020-07-07 11:24:47
问题 I'm trying to do some stuff within Gitlab CI on a remote server. When using RSA keys everything works fine, but when I try using ED25519 keys, I'm stuck: Running with gitlab-ci-multi-runner 9.3.0 (3df822b) on Internal Runner (079281fd) Using Docker executor with image 1drop/docker:git ... Using docker image sha256:b9cf0ca386341048f8696d950123e20b5d6583c190f266aacb25b6d3d4736028 for predefined container... Pulling docker image 1drop/docker:git ... Using docker image 1drop/docker:git ID=sha256