From 3a2e0c62a2a5fcafe3423eee07f56ed5bfbcdd3f Mon Sep 17 00:00:00 2001 From: Software Shinobi Date: Wed, 4 Jun 2025 10:58:11 -0400 Subject: [PATCH] automated terminal push --- .dockerignore | 11 ++++++++++ .gitignore | 0 Dockerfile | 5 +++++ Jenkinsfile | 56 +++++++++++++++++++++++++++++++++++++++++++++++++++ README.md | 2 -- compose.bash | 19 +++++++++++++++++ compose.yaml | 17 ++++++++++++++++ index.html | 13 ++++++++++++ readme.md | 2 ++ 9 files changed, 123 insertions(+), 2 deletions(-) create mode 100644 .dockerignore create mode 100644 .gitignore create mode 100644 Dockerfile create mode 100644 Jenkinsfile delete mode 100644 README.md create mode 100755 compose.bash create mode 100644 compose.yaml create mode 100644 index.html create mode 100644 readme.md diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 0000000..43cb65d --- /dev/null +++ b/.dockerignore @@ -0,0 +1,11 @@ +.git + +.pristine + +.trash + +.recycle + +.backup + +.template diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e69de29 diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..c7e06d6 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,5 @@ +FROM nginx:latest + +WORKDIR /usr/share/nginx/html + +COPY --chown=www-data:www-data --chmod=755 . . diff --git a/Jenkinsfile b/Jenkinsfile new file mode 100644 index 0000000..580599a --- /dev/null +++ b/Jenkinsfile @@ -0,0 +1,56 @@ +pipeline { + + agent none + + options { + + disableConcurrentBuilds(abortPrevious: true) + + buildDiscarder(logRotator(numToKeepStr: '10')) + } + + stages { + + stage('docker compose build') { + + agent { + + label "sian" + + } + + steps { + + dir('.') { + + sh 'docker compose build' + + } + + } + + } + + stage('docker compose push') { + + agent { + + label "sian" + + } + + steps { + + dir('.') { + + sh 'docker compose push' + + } + + } + + } + + } + +} diff --git a/README.md b/README.md deleted file mode 100644 index d35121d..0000000 --- a/README.md +++ /dev/null @@ -1,2 +0,0 @@ -# newsletter.softwareshinobi.com - diff --git a/compose.bash b/compose.bash new file mode 100755 index 0000000..b72ea5d --- /dev/null +++ b/compose.bash @@ -0,0 +1,19 @@ +#!/bin/bash + +## + +reset; + +clear; + +## + +set -e; + +set -x; + +## + +docker compose down --remove-orphans + +docker compose up --build -d diff --git a/compose.yaml b/compose.yaml new file mode 100644 index 0000000..c01c3f0 --- /dev/null +++ b/compose.yaml @@ -0,0 +1,17 @@ +services: + + newsletter.softwareshinobi.come: + + container_name: newsletter.softwareshinobi.com + + image: softwareshinobi/newsletter.softwareshinobi.com + + build: + + context: . + + dockerfile: Dockerfile + + ports: + + - 8000:80 diff --git a/index.html b/index.html new file mode 100644 index 0000000..4c3eebb --- /dev/null +++ b/index.html @@ -0,0 +1,13 @@ + + + + + + + + + diff --git a/readme.md b/readme.md new file mode 100644 index 0000000..95f52c4 --- /dev/null +++ b/readme.md @@ -0,0 +1,2 @@ +# www.softwareshinobi.com +