13

I tried to change docker image and added couple steps for git tag. Below is the answer worked for me, image: maven stages: - build - deploy - tag maven_build: stage: build script: - mvn clean package artifacts: paths: - target/*.jar after_script: - ls -a - cd target && ls -a - git --version - git remote remove origin ...


8

I might have skipped the optional installation of docker in my Ubuntu instance, so if the gitlab runner is going to use Docker, remember to install it: curl -sSL https://get.docker.com/ | sh I got back to this issue and seem to have partially fixed it by checking it the gitlab runner is running gitlab-runner status systemctl is-enabled gitlab-runner ...


8

No, you can't have multiple gitlab-ci files per repository. You can see more information in the following links : https://gitlab.com/gitlab-org/gitlab-foss/issues/18157 https://gitlab.com/gitlab-org/gitlab-foss/issues/28592 Now, there are some work in progress about this, but it's not available yet. For example, you can see here ( https://gitlab.com/...


6

This is a glibc dependency issue on Alpine. This azcopy binary is compatible with Linux distributions that use glibc, GNU's C standard library. Alpine Linux uses a different libc implementation, musl-libc, which is generally not compatible to glibc. When trying to run non-Alpine-built binaries on Alpine, they'll usually fail to link since the glibc shared ...


3

It might not be obvious now, but usually as projects advance full regression costs (resources/time) grow much faster than static analysis ones. You'll also find that static analysis alone isn't a sufficiently solid bug gate, it must be complemented with regression testing as well. So I'd place the full regression after the static analysis in the CI/CD ...


3

Surprisingly indeed GitLab works weirdly with the env vars. It evaluates them internally, though it shouldn't in my view. Value set as (in project Settings > CI/CD > Variables): 'aaa$bbb*%' becomes 'aaa*%' (with single quotes left!) Couple of of proof links: https://gitlab.com/gitlab-org/gitlab-ce/issues/45173#note_101659865 https://gitlab.com/gitlab-org/...


3

You're missing the --non-interactive tag to your registration command. Full command should be: gitlab-runner register --non-interactive --locked false --run-untagged true --tag-list java --name foo --registration-token %token% --url https://myurl --executor shell Relevant documentation for non-interactive registration.


3

I dealt with the same issue. Some people recommended using the Gitlab group "secrets" and using before_script. Since I knew I was also going to deploy and would need other tools on my runner like "helm", I made my own docker container. I still keep my config for my clusters in a base64 encoded group secret but I set it like this in the dockerfile. ENV ...


3

Caching of layers with buildkit in an external registry requires an extra step or two depending on how you want to cache your layers. The easy option is to include a build arg that enables the inline cache: docker build --build-arg BUILDKIT_INLINE_CACHE=1 --cache-from ${LATEST} -t ${LATEST} -t ${IMAGE_COMMIT_TAG} . Note that the inline cache only caches ...


3

Are you sure that your registry is publicly available? Checklist: Check if the domain is reachable and responding the right IP address -- nslookup myregistry Check if your port is open or not blocked any kind of software (let's say via firewalls or AWS security group) -- telnet myregistry 5050 Check if your registry is not restricted for a particular CIDR ...


3

I didn't get what's wrong with webhooks You just create a webhook on Gitlab CI side and provide this URL to your Jira account. https://gitlab.com/api/v4/projects/PROJECT_ID/ref/REF_NAME/trigger/pipeline?token=TOKEN PROJECT_ID - unique project id on Gitlab REF_NAME - your qa / stage / beta branches within repository TOKEN - uniquely generated access token (...


2

For a specific GitLab runner tied to a project, the token can be found in Step 3; in Project -> Settings -> CI/CD -> Runners in the Setup a specific Runner manually section. You will also be able to find the URL which you need to use to register the runner in Step 2.


2

The answer is that all Auto Dev-Ops deployments at present use Helm to package and deploy your application. In order to make changes to the deployment, such as adding a persistent volume claim, you should download and modify the Helm chart that GitLab uses. The files in this repo should go into a new directory chart/, or you can link to another location by ...


2

Combining the answer of https://devops.stackexchange.com/a/3854/10932 and the comment of Overbryd along with a slight modification worked for me. Here, instead of using using git remote set-url command, I used git remote add. The code will look like this: image: maven stages: - build - deploy - tag maven_build: stage: build script: - mvn clean ...


2

There currently isn't a solution for building on a specific runner in GitLab, but there is an issue open for Sticky Runners, which hopefully will be out in the next 3-6 months according to the Milestones! The work around I've done so far to build a project on a specific runner is to use the GitLab Runner API, in a rather hacky way, along the lines of: Get ...


2

git push origin 1.0.15 should work and a new tag should be added to the tags in gitlab https://docs.gitlab.com/ee/university/training/topics/tags.html git checkout master # Lightweight tag git tag my_lightweight_tag # Annotated tag git tag -a v1.0 -m ‘Version 1.0’ git tag git push origin --tags


2

No, jobs (which rust-latest and rust-nightly are examples of) will run in parallel if they are in the same stage (of which you only have one, build).


2

Yes, full cloning of LFS files can be restricted! By default, GitLab will clone your repo into the CI/CD build directory. To limit the clone from downloading the LFS files, tell it not to do it. You do this by setting a variable in .gitlab-ci.yml like this. # Other declarations etc above the specific job jobname: variables: GIT_LFS_SKIP_SMUDGE: 1 # ...


2

https://hub.docker.com/_/docker/ Seems it's just a reference to the above... Which uses APK as the package manager


2

GitLab and GitLab CI are not two servers: they are softwares installed on a server. Now, while both can be installed on the same server, they can be split for scaling reason. Now your question: it all depends on what type of services your are running. Bear in mind that CI can take CPU/memory and disk bandwidth while running your CI (docker image build, ...


2

Going from this, your ClusterRole isn't configured to allow access to deployments, and the ClusterRole you've listed isn't properly bound to your service account. You could configure it with something like I did below as a troubleshooting measure/to make sure you're able to properly configure permissions and rule out an issue with the serviceaccount's role ...


2

Just unregister offline runners: As per GitLab Runner commands manual: To delete the old and removed from GitLab runners, execute the following command. gitlab-runner verify --delete You are not alone P.S. The problem is common: there are many issues with questions like yours. Moreover, there are several custom recipes to unregister "offline"...


2

CI token used for code checkout is not allowed to do writes to the git repository (unlike GitHub Actions). You need to generate a new personal token and add it to secrets. See our integration project here as a sample: https://gitlab.com/taleodor/sample-helm-cd Note, if you search through StackOverflow, you may find several other ways to achieve this but in ...


2

What you need is not to checkout both projects side by side, but to add the library as a Git submodule in your application repository. Then set up GitLab CI to checkout submodules before build. This will not only make your CI work, but as an added benefit each commit from application repository will reference a specific commit from library repository, so ...


2

Runners are machines (typically containers) where your jobs run. Gitlab offers shared runners, and you can also bring in your own runners (machines that you register against Gitlab to run your jobs). The main difference between Gitlab shared runners and the ones you bring is that the shared runners are, well, shared, so sometimes you have to wait for a bit ...


2

When you use public IP the traffic exits your VPC and comes back in, at which point it is no longer identified as coming from that security group. So you can adjust your ssh connection and use private IP


2

This is likely because your requests were dropped before they landed on the GitLab host. Check your firewalls and other security rules after assured that the 1234 port is open


1

I am using AzureDevOps and the trick we use when naming containers is to add build number to the label namespace/application:branch-name-bulidNumber So in your case, you could try gitlab variable CI_CONCURRENT_PROJECT_ID After comment for images clean-up you can use: docker image prune --all --filter until=48h As docker system prune and docker image ...


1

Do you have a volume mounted with gitlab-runner-prebuilt.tar.xz? Your error log makes it seem like it can't find the file when it executes.


1

have anyone tried this scenario (gitlab runner + docker on Windows) before, and have some feedback if it works or not? I installed and registered a GitLab Runner on my Windows 10 laptop following the instructions from GitLab Install GitLab Runner on Windows At first, I had trouble pulling the Windows container image: PS C:\GitLab-Runner> docker pull ...


Only top voted, non community-wiki answers of a minimum length are eligible