V1.3.1: mongo mit auth
optik etwas angepasst
This commit is contained in:
33
deploy.sh
Executable file
33
deploy.sh
Executable file
@@ -0,0 +1,33 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
# Deploy das übergeben docker-image (name) in das Registry
|
||||||
|
#
|
||||||
|
# V 1.0.0 2026-01-19 rxf
|
||||||
|
# - erste version
|
||||||
|
|
||||||
|
|
||||||
|
#set -x
|
||||||
|
|
||||||
|
registry=docker.citysensor.de
|
||||||
|
|
||||||
|
usage()
|
||||||
|
{
|
||||||
|
echo "Usage ./deploy.sh name"
|
||||||
|
echo " Build docker container 'name' and deploy to $registry"
|
||||||
|
echo "Params:"
|
||||||
|
echo " -h show this usage"
|
||||||
|
}
|
||||||
|
|
||||||
|
name=$1
|
||||||
|
|
||||||
|
while getopts h? o
|
||||||
|
do
|
||||||
|
case "$o" in
|
||||||
|
h) usage; exit 0;;
|
||||||
|
*) usage; exit 1;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
docker tag $name $registry/$name:latest
|
||||||
|
dat=`date +%Y%m%d%H%M`
|
||||||
|
docker tag $name $registry/$name:V_$dat
|
||||||
|
docker push $registry/$name
|
||||||
@@ -16,6 +16,7 @@ services:
|
|||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
|
||||||
spritzschema:
|
spritzschema:
|
||||||
|
image: spritzschema
|
||||||
build:
|
build:
|
||||||
context: .
|
context: .
|
||||||
dockerfile: Dockerfile_spritzschema
|
dockerfile: Dockerfile_spritzschema
|
||||||
|
|||||||
@@ -27,6 +27,8 @@ let COLLECTION = 'spritzschema'
|
|||||||
erg = await putAPIdataOne(client, options)
|
erg = await putAPIdataOne(client, options)
|
||||||
} else if (cmd === 'deldata') {
|
} else if (cmd === 'deldata') {
|
||||||
erg = await delAPIdataOne(client, options)
|
erg = await delAPIdataOne(client, options)
|
||||||
|
} else if (cmd === 'geturl') {
|
||||||
|
erg = MONGO_URL
|
||||||
} else {
|
} else {
|
||||||
erg.err = "Unknown Call"
|
erg.err = "Unknown Call"
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "spritzschema",
|
"name": "spritzschema",
|
||||||
"version": "1.3.0",
|
"version": "1.3.1",
|
||||||
"date": "2026-01-18",
|
"date": "2026-01-19",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
@@ -8,7 +8,10 @@ document.addEventListener('DOMContentLoaded', async function () {
|
|||||||
await initSchema('2023-05-01')
|
await initSchema('2023-05-01')
|
||||||
}
|
}
|
||||||
|
|
||||||
let ret = await getData()
|
let ret = await fetch('debug')
|
||||||
|
let url = await ret.json()
|
||||||
|
|
||||||
|
ret = await getData()
|
||||||
let schema = ret.data
|
let schema = ret.data
|
||||||
if(curEinheit === 0) {
|
if(curEinheit === 0) {
|
||||||
curEinheit = schema.einheit
|
curEinheit = schema.einheit
|
||||||
@@ -20,6 +23,9 @@ document.addEventListener('DOMContentLoaded', async function () {
|
|||||||
|
|
||||||
async function markField (e) {
|
async function markField (e) {
|
||||||
let field = e.target;
|
let field = e.target;
|
||||||
|
if (field.id === 'inner') {
|
||||||
|
field = e.target.parentElement
|
||||||
|
}
|
||||||
let d = schema.data[34].day
|
let d = schema.data[34].day
|
||||||
field.setAttribute('aria-label','x');
|
field.setAttribute('aria-label','x');
|
||||||
// field.setAttribute('disabled','disabled');
|
// field.setAttribute('disabled','disabled');
|
||||||
|
|||||||
@@ -76,14 +76,14 @@ footer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#lowline {
|
#lowline {
|
||||||
|
color: black;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
clear: float;
|
clear: float;
|
||||||
|
padding-top: 30px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#eh {
|
#eh {
|
||||||
color: black;
|
|
||||||
float: right;
|
float: right;
|
||||||
margin-right: -20px;
|
|
||||||
}
|
}
|
||||||
#wtg {
|
#wtg {
|
||||||
float: left;
|
float: left;
|
||||||
|
|||||||
@@ -24,6 +24,12 @@ router.get('/data', async function(req, res, next) {
|
|||||||
res.json(erg)
|
res.json(erg)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
router.get('/debug', async function(req, res, next) {
|
||||||
|
const options = {}
|
||||||
|
let erg = await doMongo('geturl', options)
|
||||||
|
res.json(erg)
|
||||||
|
})
|
||||||
|
|
||||||
router.post('/data', async function (req, res, next) {
|
router.post('/data', async function (req, res, next) {
|
||||||
const options = {}
|
const options = {}
|
||||||
options.data = req.body
|
options.data = req.body
|
||||||
|
|||||||
Reference in New Issue
Block a user