diff --git a/.seeks.ccatc b/.seeks.ccatc new file mode 100644 index 0000000..31f53df --- /dev/null +++ b/.seeks.ccatc @@ -0,0 +1,15 @@ +[dep] +upgrade: ask +user_email: petr.nyc@oracle.com + +[bitbucket] +username: pnyc + +[templates] +project: CCATC +repo: ccatc-seeks +branch: main +vcs: SCM +scmrepo: ocid1.devopsrepository.oc1.phx.amaaaaaaw4vcxbyahrz7vgu4tdwdcfwd26e5fvmcoidmxrtmdvwyowqhi6rq +filepath: seeks_templates.conf + diff --git a/.seeks.odaas b/.seeks.odaas new file mode 100644 index 0000000..9066b3c --- /dev/null +++ b/.seeks.odaas @@ -0,0 +1,12 @@ +[dep] +upgrade: ask +user_email: petr.nyc@oracle.com + +[bitbucket] +username: pnyc + +[templates] +project: ODAAS +repo: cm_automation +branch: main +filepath: change_templates/seeks_templates.conf diff --git a/.ssh/config.oci b/.ssh/config.oci index e9b27fd..41f4136 100644 --- a/.ssh/config.oci +++ b/.ssh/config.oci @@ -1,3 +1,4 @@ +Include config-scm Include ssh_configs/config Include osd_configs/config Include user diff --git a/.ssh/config.solaris b/.ssh/config.solaris index 39769f1..09e2723 100644 --- a/.ssh/config.solaris +++ b/.ssh/config.solaris @@ -15,6 +15,10 @@ Host * Host 192.168.2.* IdentitiesOnly yes +Host solaris-reviews.us.oracle.com + User hg + IdentityFile ~/.ssh/id_phabricator + Host hetzner HostName u444067.your-storagebox.de User u444067 diff --git a/.zshrc b/.zshrc index 1914dc2..8bc086f 100644 --- a/.zshrc +++ b/.zshrc @@ -113,7 +113,7 @@ COMPLETION_WAITING_DOTS="true" # Custom plugins may be added to $ZSH_CUSTOM/plugins/ # Example format: plugins=(rails git textmate ruby lighthouse) # Add wisely, as too many plugins slow down shell startup. -plugins=(git rsync colorize colored-man-pages vi-mode common-aliases macos themes dircycle iterm2 docker docker-compose zsh-navigation-tools urltools history mercurial tmux zsh-syntax-highlighting zsh-autosuggestions kubectl helm terraform asdf brew web-search kubectl helm) +plugins=(git rsync colorize colored-man-pages vi-mode common-aliases macos themes dircycle iterm2 docker docker-compose zsh-navigation-tools urltools history mercurial tmux zsh-syntax-highlighting zsh-autosuggestions kubectl helm terraform asdf brew web-search kubectl helm aliases emacs) # consider plugin fzf - only available for Mac/Linux @@ -241,3 +241,7 @@ export PATH=$GEM_HOME/bin:$HOME/.gem/ruby/3.3.0/bin:$PATH # Generated for envman. Do not edit. # [ -s "$HOME/.config/envman/load.sh" ] && source "$HOME/.config/envman/load.sh" + + +# alias scm-ssh='/Users/jetpac/.ssh/scm-script.sh' +# scm-ssh start_agent diff --git a/bin/lib/logging.sh b/bin/lib/logging.sh index 811a064..b47a454 100644 --- a/bin/lib/logging.sh +++ b/bin/lib/logging.sh @@ -5,7 +5,7 @@ trap 'exit 1' HUP INT QUIT TERM -trap 'on_error' EXIT +# trap 'on_error' EXIT log::prefix() { date=$(/opt/homebrew/bin/gdate '+%Y-%m-%d %H:%M:%S,%3N') diff --git a/bin/ul11u4_build.sh b/bin/ul11u4_build.sh index 25524cc..1b1a6c5 100755 --- a/bin/ul11u4_build.sh +++ b/bin/ul11u4_build.sh @@ -1,16 +1,35 @@ #!/usr/bin/env bash -source lib/logging.sh +[[ "$0" == /* ]] && typeset -r PRG=$0 || typeset -r PRG=$PWD/$0 -TARGET=$1 +BINDIR=$(dirname "$PRG") +typeset -r BINDIR +source "${BINDIR}/lib/logging.sh" -if [ -z "$TARGET" ]; +W3M=/opt/homebrew/bin/w3m +AWK=/usr/bin/awk +CURL=/usr/bin/curl + +source "${BINDIR}/lib/logging.sh" +TARGET="${1-11.4.81.0.1.195.1}" +log::info "TARGET:${TARGET}" + +URL="http://grt.us.oracle.com/grt/webservice/grtList/?gate=240&show=All&gateName=S11.4-SRU&status=4&target=${TARGET}" +log::debug $URL + +output=$(/opt/homebrew/bin/w3m "$URL" -M -cols 400 -graph -dump 2>&1) + +out=$(echo "$output" | $AWK '/^Details/ {found=1; next} found && NF') + +if [[ -z "$out" ]]; then - log::fatal "No target specified on command line" + log::info "There are no queued RTIs for \"${TARGET}\". Nothing to do..." + exit 0 fi -log::info"Starting build for for Ul11u4SRU" + +log::info "Starting build for for Ul11u4SRU" log::info "Target: \"${TARGET}\"" JENKINS_TOKEN='1154eb0158729a7d326c1db13e7dca0cea' diff --git a/bin/ul11u4_gate_open.sh b/bin/ul11u4_gate_open.sh index e1b512f..25f1997 100755 --- a/bin/ul11u4_gate_open.sh +++ b/bin/ul11u4_gate_open.sh @@ -1,5 +1,7 @@ #!/usr/bin/env bash +# set -x + [[ "$0" == /* ]] && typeset -r PRG=$0 || typeset -r PRG=$PWD/$0 BINDIR=$(dirname "$PRG") @@ -13,13 +15,20 @@ source "${BINDIR}/lib/logging.sh" TARGET="${1-11.4.81.0.1.195.1}" -URL="http://grt.us.oracle.com/grt/webservice/grtList/?gate=20&show=All&gateName=S11.4-SRU&status=1&target=${TARGET}" +# log::info "TARGET:${TARGET}" + +URL="http://grt.us.oracle.com/grt/webservice/grtList/?gate=240&show=All&gateName=S11.4-SRU&status=1&target=${TARGET}" + +# log::debug $URL + +output=$(/opt/homebrew/bin/w3m "$URL" -M -cols 400 -graph -dump 2>&1) -out=$($W3M "$URL" -M -cols 400 -graph -dump | $AWK '/^Details/ {found=1; next} found && NF') +out=$(echo "$output" | awk '/^Details.*Consolidation/ {found=1; next} found') if [[ -z "$out" ]]; then - log::info "There are no queued RTIs for \"${TARGET}\". Nothing to do..." + # log::debug "output: ### $out ###" + # log::info "There are no queued RTIs for \"${TARGET}\". Nothing to do..." exit 0 fi