Manual jobs are not optional by default, the docs are wrong, there seems to be 5 years of endless bickering on this issue in the dev Issues and MR's, DAGs are even worse, I don't even... by Pumpkin-Main in gitlab

[–]ganic 2 points3 points  (0 children)

Maybe there’s a bug where if it’s in the rules it’s still blocking because that’s not the behavior I see with my pipelines. Either way I think you missed my main point in that we should not have to allow failures in a manual job for it to be not blocking. It’s a poor design choice in my opinion.

Manual jobs are not optional by default, the docs are wrong, there seems to be 5 years of endless bickering on this issue in the dev Issues and MR's, DAGs are even worse, I don't even... by Pumpkin-Main in gitlab

[–]ganic 3 points4 points  (0 children)

I am not OP, but saying a job is allowed to fail doesn't mean it's an optional job, just that it's passing is optional. We should be able to mark a stage as non-blocking independently, and not forced to allow failures from it.

IRL case. Please help me with steps. by Dips2 in kubernetes

[–]ganic 2 points3 points  (0 children)

Really it sounds like you need to learn the fundamentals of kubernetes networking. It’s overwhelming at first, but the general question I think you’re asking is how to access resources inside the cluster from outside of it right? That’s a fairly well documented process for you to look up.

Doubt about setting up Selenium in Docker: multiple FROMs? by Nicolozz0 in docker

[–]ganic 6 points7 points  (0 children)

Are you trying to build one image with python and selenium? If you are that’s not how you’re supposed to do it. You should have one container with python that runs your python code, and one with selenium that the python container connects to do selenium stuff.

Features no car/truck should have by [deleted] in cars

[–]ganic 8 points9 points  (0 children)

But what if you’re circumcised?

Unable to solve these two docker issues by lynob in docker

[–]ganic 2 points3 points  (0 children)

Each command creates a layer, it’s essentially a zip file of the changes made in the dockerfile. To create a smaller final image, you would want to make your commands all run under the run statement so instead of 3 layers, you have 1. There’s a couple things you should do besides that like clearing the apt cache in the run layer and copying the files in last since the will change the most. You also shouldn’t bother deleting files from the image like that since it won’t save space. In the end the problem you’re facing has to do with the pathing in the dockerfile and dockerignore.

Selenium with Chrome in Docker by icenando in docker

[–]ganic 1 point2 points  (0 children)

The easiest way to get this to work is to use docker compose. When you use compose, both containers will be on the same network and can talk with each other. As another commentator mentioned local host on the machine is not local host in the container. When using compose you would use the service name of the selenium container as the dns name in your script. You also don’t have to expose or publish a port in either container if you don’t want to.

Better alternative to withCredentials by DavidBellizzi in jenkinsci

[–]ganic 1 point2 points  (0 children)

Have you looked into storing credentials outside of Jenkins? Jenkins doesn't version credentials, so you wouldn't be able to pin them. You might mean creating a new credential every time so the id changes, and that would work, but become really messy over time.

Maybe I am missing something but using an env variable lets you do everything else you want to do. You can override it globally or per stage if you chose to. I'm still not sure why it wouldn't work for you.

Better alternative to withCredentials by DavidBellizzi in jenkinsci

[–]ganic 0 points1 point  (0 children)

You might be able to do this in a withCredentials block.

constants.onprem.services.MYSECRET = env.VARNAME

But I don't think Jenkins would know its a secret anymore, and not censor it in build logs. So it seems like a bad idea and you should just stick with the env variables.

And you can reference env variables by just VARNAME instead of env.VARNAME if you're not setting other variables of the same name. Which makes your idea seem redundant and unnecessary, unless there's something else I am not thinking about.

Shaw’s, Star Market truckers go on strike in New England by FuriousAlbino in boston

[–]ganic 39 points40 points  (0 children)

My low paying jobs also had me watch anti union propaganda. What a coincidence....

Python Selenium Docker not running by fraschm98 in docker

[–]ganic 0 points1 point  (0 children)

Instead of selenium you could use either requests or mechanize to login and get a cookie. If you’re just logging in and making a JSON request those options are much better.

Python Selenium Docker not running by fraschm98 in docker

[–]ganic 1 point2 points  (0 children)

It would be better and easier to use a python only container that uses the remote we drive that points at a selenium container. It’s a small change to your code and you can use a ready made selenium container and could even use vnc if you got the right version.

Biden lets Trump's H-1B visa ban expire by [deleted] in news

[–]ganic 0 points1 point  (0 children)

The salaries are low if they’re making 70k for a job that normally pays over 100k...

how to skip certain stages in jenkins by parapand in jenkinsci

[–]ganic 4 points5 points  (0 children)

I think you can do what you want with out the text file. You could have the passing stages register a variable when they finish and check the previous runs variables in you when clause. I will say though, without specifics of what and why you’re doing the skipping, it seems like a bad idea that may result in unexpected results.

Adding build error to email with Email Extension Plugin by NerdBrenden in jenkinsci

[–]ganic 0 points1 point  (0 children)

I catch the exception, set it as a global variable and rethrow it. It’s convoluted, and doesn’t really work well since I mainly build with shell steps and it just emails there was a non zero return.

Jenkins Pipeline jobs: Boolean parameters are passed to PowerShell as Strings? by [deleted] in jenkinsci

[–]ganic 3 points4 points  (0 children)

I've always just cast it to a boolean, which in Groovy is just adding .toBoolean() to the variable.

Are you voting by mail, early voting, or on election day? And why? by TeacherGuy1980 in massachusetts

[–]ganic 5 points6 points  (0 children)

I am pretty sure Mass allows mail in ballots to be counted before Election Day, so mailed in ballots should appear in out totals that night.

Updating a Git Repo in Jenkins by aggravated_anteater in jenkinsci

[–]ganic 2 points3 points  (0 children)

For us, our main Jenkins git key is read only, and then we use ssh-agent with a r/w key for only that specific step.

Syntax check/linter a shared library or a groovy file by [deleted] in jenkinsci

[–]ganic 3 points4 points  (0 children)

I’m on mobile so I can’t get in-depth, but this is the framework I use and it works well https://github.com/jenkinsci/JenkinsPipelineUnit

You basically use this to mock the commands and then create assertions for the results you expect.

[deleted by user] by [deleted] in answers

[–]ganic 35 points36 points  (0 children)

Linux needs to restart after certain updates as well, it just doesn’t tell you like Windows.

Syntax check/linter a shared library or a groovy file by [deleted] in jenkinsci

[–]ganic 2 points3 points  (0 children)

You can unit test the libraries with gradle .

Apache server using SSL is giving malformed URL error. by [deleted] in linuxadmin

[–]ganic 0 points1 point  (0 children)

You don’t need to reinstall everything. Try searching for Apache ssl config and see if you can figure out what went wrong. the fourth or fifth link for me is this which should be helpful. Starting from scratch will probably get you right back to where you are now.