This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
rx='^v([0-9]+\.){0,2}(\*|[0-9]+)$' | |
if [[ ${bamboo.planRepository.1.revision} =~ $rx ]]; then | |
TAG=${bamboo.planRepository.1.revision} | |
else | |
TAG=latest | |
fi | |
echo TAG=$TAG > properties.txt | |
cat properties.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package br.com.esign.selenium.utils; | |
import org.openqa.selenium.JavascriptExecutor; | |
import org.openqa.selenium.WebDriver; | |
import org.openqa.selenium.WebElement; | |
import org.openqa.selenium.support.ui.ExpectedConditions; | |
import org.openqa.selenium.support.ui.WebDriverWait; | |
/** | |
* Selenium utilitary class |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
language: java | |
sudo: required | |
install: true | |
services: | |
- docker | |
addons: | |
sonarcloud: | |
organization: "gustavomcarmo-github" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- hosts: moodle | |
gather_facts: no | |
become: yes | |
tasks: | |
- name: Install required packages | |
apt: | |
name: "{{item}}" | |
update_cache: yes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ $# -ne 1 ]; then | |
echo "One parameter expected:" | |
echo "- the new size limit (in Mb)" | |
exit 1 | |
fi | |
SIZE_IN_MB=$1 | |
if [[ ! $SIZE_IN_MB =~ ^[0-9]+$ || $SIZE_IN_MB -eq 0 ]]; then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
- hosts: localhost | |
gather_facts: no | |
vars: | |
aws_region: "eu-west-2" | |
tasks: | |
- name: Find Ubuntu Server 18.04 LTS AMIs | |
ec2_ami_facts: | |
region: '{{ aws_region }}' | |
owners: 099720109477 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '3' | |
services: | |
mysql: | |
image: mariadb:10.3.12 | |
container_name: mysql | |
restart: always | |
volumes: | |
- mysql_data:/var/lib/mysql | |
environment: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
docker run --name openldap -d -p 389:389 osixia/openldap:1.2.1 | |
if [ $? -ne 0 ]; then | |
echo "Error on running the OpenLDAP Docker image." | |
exit 1 | |
fi | |
until ldapsearch -x -b dc=example,dc=org -D cn=admin,dc=example,dc=org -w admin | grep "dn: dc=example,dc=org" | |
do |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM jenkins/jenkins:lts | |
LABEL maintainer "Gustavo Muniz do Carmo <gustavo@esign.com.br>" | |
ENV JAVA_OPTS="-Djenkins.install.runSetupWizard=false" | |
COPY config-maven.groovy /usr/share/jenkins/ref/init.groovy.d/ | |
COPY config-sonarqube.groovy /usr/share/jenkins/ref/init.groovy.d/ | |
COPY harden-jenkins.groovy /usr/share/jenkins/ref/init.groovy.d/ | |
COPY default-user.groovy /usr/share/jenkins/ref/init.groovy.d/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
from datetime import datetime | |
import logging | |
import os | |
import requests | |
def get_params(): | |
if 'JENKINS_URL' not in os.environ or 'JENKINS_ADMIN_USERNAME' not in os.environ or 'JENKINS_ADMIN_PASSWORD' not in os.environ: |
OlderNewer