Skip to content

Commit

Permalink
go update and github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
KenWilliamson committed May 6, 2024
1 parent 35a9af9 commit 48e1baa
Show file tree
Hide file tree
Showing 11 changed files with 99 additions and 88 deletions.
82 changes: 0 additions & 82 deletions .circleci/config.yml

This file was deleted.

51 changes: 51 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# This workflow will build a golang project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-go

name: Build

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]

jobs:

build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: 1.20.1

- name: Install dependencies
run: go get .

- name: Build
run: go build -v ./...

- name: Test
run: go test -v ./...

# - name: Build the Docker image
# run: docker build . --file Dockerfile --tag my-image-name:$(date +%s)

sonarcloud:
name: SonarCloud
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
- name: SonarCloud Scan
uses: SonarSource/sonarcloud-github-action@master
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}




42 changes: 42 additions & 0 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.

# GitHub recommends pinning actions to a commit SHA.
# To get a newer version, you will need to update the SHA.
# You can also reference a tag or branch, but the action may change without warning.

name: Publish Docker image

on:
release:
types: [published]

jobs:
push_to_registry:
name: Push Docker image to Docker Hub
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v3

- name: Log in to Docker Hub
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
with:
images: ulboralabs/ulboracms

- name: Build and push Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
2 changes: 1 addition & 1 deletion data/contentStore/about.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"about","title":"About Ulbora CMS","subject":"Ulbora CMS, a very fast CMS","author":"Ken Williamson","createDate":"2020-04-08T13:03:53.550131465-04:00","modifiedDate":"2023-03-24T14:38:39.929196149-04:00","hits":134,"metaAuthorName":"","metaDesc":"Blogging platform","metaKeyWords":"ulbora cms, blog, blogger","metaRobotKeyWords":"","text":"PHA+VWxib3JhIENNUyBpcyBtb3JlIHRoYW4ganVzdCBhIGJsb2dnaW5nIHBsYXRmb3JtLCB5b3UgY2FuIGFsc28gYnVpbGQgd2ViIHNpdGVzIHdpdGggaXQuPC9wPg0KPHA+QXMgZm9yIGJsb2dnaW5nLCBVbGJvcmEgQ01TIGlzIHBlcmZlY3QgZm9yIGJsb2dnaW5nIGFuZCBhbGxvd3MgeW91ciBzaXRlIHRvIHNlcnZlIHVwIHBhZ2VzIGZhc3QuPC9wPg0KPHA+VWxib3JhIENNUyBpcyBhbHNvIHBlcmZlY3QgZm9yIHdlYiBzaXRlcyBmb3IgYm90aCBjb21wYW5pZXMgYW5kIGluZGl2aWR1YWxzLjwvcD4NCjxwPlVsYm9yYSBDTVMgcnVucyBpbiA8ZW0+PHN0cm9uZz5tZW1vcnk8L3N0cm9uZz48L2VtPiBhbmQgcmVxdWlyZXMgPHNwYW4gc3R5bGU9InRleHQtZGVjb3JhdGlvbjogdW5kZXJsaW5lOyI+bm8gZGF0YWJhc2UgYmFja2VuZDwvc3Bhbj4uPC9wPg==","TextHTML":"","archived":false,"visible":true,"UseModifiedDate":false,"blogPost":false}
{"name":"about","title":"About Ulbora CMS","subject":"Ulbora CMS, a very fast CMS","author":"Ken Williamson","createDate":"2020-04-08T13:03:53.550131465-04:00","modifiedDate":"2024-05-06T15:41:07.817402173-04:00","hits":140,"metaAuthorName":"","metaDesc":"Blogging platform","metaKeyWords":"ulbora cms, blog, blogger","metaRobotKeyWords":"","text":"PHA+VWxib3JhIENNUyBpcyBtb3JlIHRoYW4ganVzdCBhIGJsb2dnaW5nIHBsYXRmb3JtLCB5b3UgY2FuIGFsc28gYnVpbGQgd2ViIHNpdGVzIHdpdGggaXQuPC9wPg0KPHA+QXMgZm9yIGJsb2dnaW5nLCBVbGJvcmEgQ01TIGlzIHBlcmZlY3QgZm9yIGJsb2dnaW5nIGFuZCBhbGxvd3MgeW91ciBzaXRlIHRvIHNlcnZlIHVwIHBhZ2VzIGZhc3QuPC9wPg0KPHA+VWxib3JhIENNUyBpcyBhbHNvIHBlcmZlY3QgZm9yIHdlYiBzaXRlcyBmb3IgYm90aCBjb21wYW5pZXMgYW5kIGluZGl2aWR1YWxzLjwvcD4NCjxwPlVsYm9yYSBDTVMgcnVucyBpbiA8ZW0+PHN0cm9uZz5tZW1vcnk8L3N0cm9uZz48L2VtPiBhbmQgcmVxdWlyZXMgPHNwYW4gc3R5bGU9InRleHQtZGVjb3JhdGlvbjogdW5kZXJsaW5lOyI+bm8gZGF0YWJhc2UgYmFja2VuZDwvc3Bhbj4uPC9wPg==","TextHTML":"","archived":false,"visible":true,"UseModifiedDate":false,"blogPost":false}
2 changes: 1 addition & 1 deletion data/contentStore/home.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"home","title":"Home Page","subject":"Ulbora CMS","author":"Ken Williamson","createDate":"2020-04-09T12:32:39.806769116-04:00","modifiedDate":"2023-03-27T19:45:46.755449572-04:00","hits":235,"metaAuthorName":"","metaDesc":"","metaKeyWords":"UlboraCMS, CMS, Ulbora, templates, screens","metaRobotKeyWords":"","text":"PHA+QSBUaGVtZSBmb3IgVWxib3JhIENNUyBhbmQgdGhlcmUgYXJlIG90aGVycy48L3A+","TextHTML":"","archived":false,"visible":true,"UseModifiedDate":false,"blogPost":false}
{"name":"home","title":"Home Page","subject":"Ulbora CMS","author":"Ken Williamson","createDate":"2020-04-09T12:32:39.806769116-04:00","modifiedDate":"2024-05-06T15:41:07.817101117-04:00","hits":241,"metaAuthorName":"","metaDesc":"","metaKeyWords":"UlboraCMS, CMS, Ulbora, templates, screens","metaRobotKeyWords":"","text":"PHA+QSBUaGVtZSBmb3IgVWxib3JhIENNUyBhbmQgdGhlcmUgYXJlIG90aGVycy48L3A+","TextHTML":"","archived":false,"visible":true,"UseModifiedDate":false,"blogPost":false}
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/Ulbora/ulboracms

go 1.20
go 1.22

require (
github.com/Ulbora/Level_Logger v1.0.2
Expand Down
Binary file modified main
Binary file not shown.
2 changes: 1 addition & 1 deletion services/testBackup/contentStore/books1.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"books1","title":"the best book ever ever","subject":"","author":"","createDate":"2020-03-23T12:58:49.01992684-04:00","modifiedDate":"2023-03-27T19:41:00.783162844-04:00","hits":104,"metaAuthorName":"ken test stuff","metaDesc":"a booktest stuff","metaKeyWords":"","metaRobotKeyWords":"","text":"c29tZSBib29rIHRleHQgdGVzdCBzdHVmZg==","TextHTML":"","archived":false,"visible":true,"UseModifiedDate":false,"blogPost":false}
{"name":"books1","title":"the best book ever ever","subject":"","author":"","createDate":"2020-03-23T12:58:49.01992684-04:00","modifiedDate":"2024-05-06T15:43:54.023185316-04:00","hits":106,"metaAuthorName":"ken test stuff","metaDesc":"a booktest stuff","metaKeyWords":"","metaRobotKeyWords":"","text":"c29tZSBib29rIHRleHQgdGVzdCBzdHVmZg==","TextHTML":"","archived":false,"visible":true,"UseModifiedDate":false,"blogPost":false}
2 changes: 1 addition & 1 deletion services/testBackupRestore/contentStore/books1.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"books1","title":"the best book ever ever","subject":"","author":"","createDate":"2020-03-23T12:58:49.01992684-04:00","modifiedDate":"2023-03-24T14:23:07.103300416-04:00","hits":103,"metaAuthorName":"ken test stuff","metaDesc":"a booktest stuff","metaKeyWords":"","metaRobotKeyWords":"","text":"c29tZSBib29rIHRleHQgdGVzdCBzdHVmZg==","TextHTML":"","archived":false,"visible":true,"UseModifiedDate":false,"blogPost":false}
{"name":"books1","title":"the best book ever ever","subject":"","author":"","createDate":"2020-03-23T12:58:49.01992684-04:00","modifiedDate":"2024-05-06T15:41:53.884064921-04:00","hits":105,"metaAuthorName":"ken test stuff","metaDesc":"a booktest stuff","metaKeyWords":"","metaRobotKeyWords":"","text":"c29tZSBib29rIHRleHQgdGVzdCBzdHVmZg==","TextHTML":"","archived":false,"visible":true,"UseModifiedDate":false,"blogPost":false}
Binary file modified services/testBackupZips/compress.dat
Binary file not shown.
2 changes: 1 addition & 1 deletion services/testBackupZips/uncompress.json

Large diffs are not rendered by default.

0 comments on commit 48e1baa

Please sign in to comment.