Merge branch 'oscoDOTblog-master'

This commit is contained in:
Nicolas Meienberger 2023-10-07 12:11:04 +02:00
commit 09800278d4
10 changed files with 273 additions and 2 deletions

View File

@ -89,7 +89,9 @@ This is the official repository for the Tipi App Store. It contains all the apps
- [Monica](https://github.com/monicahq/monica) - A Personal Relationship Management tool to help you document your social life
- [Mixpost](https://github.com/inovector/mixpost) - Self-hosted social media management. Schedule and organize your social content.
- [Mixpost Pro](https://mixpost.app/pricing) - Self-hosted social media management. Schedule and organize your social content.
- [Movary](https://github.com/leepeuker/movary - ) Track and rate your watched movies
- [MongoDB](https://github.com/mongodb/mongo)- MongoDB is an open-source NoSQL database
- [Mongo Express](https://github.com/mongo-express/mongo-express) - A web-based MongoDB admin interface written with Node.js, Express, and Bootstrap3
- [Movary](https://github.com/leepeuker/movary ) - Track and rate your watched movies
- [mStream](https://github.com/IrosTheBeggar/mStream) - The easiest music streaming server available
- [Mylar3](https://github.com/mylar3/mylar3) - Mylar3 is an automated Comic Book downloader (cbr/cbz) for use with NZB and torrents written in python.
- [n8n](https://github.com/n8n-io/n8n) - Workflow Automation Tool

View File

@ -0,0 +1,49 @@
{
"$schema": "../schema.json",
"name": "Mongo Express",
"id": "mongo-express",
"available": true,
"short_desc": "Web-based MongoDB admin interface, written with Node.js and Express",
"author": "MongoDB",
"port": 8087,
"categories": ["development", "data"],
"description": "A web-based MongoDB admin interface written with Node.js, Express, and Bootstrap3",
"tipi_version": 1,
"version": "1.0.0",
"source": "https://github.com/mongo-express/mongo-express",
"website": "https://www.mongodb.com/",
"form_fields": [
{
"type": "text",
"label": "MongoDB Admin Username",
"max": 50,
"min": 3,
"required": true,
"env_variable": "ME_CONFIG_MONGODB_ADMINUSERNAME"
},
{
"type": "password",
"label": "MongoDB Admin Password",
"max": 50,
"min": 10,
"required": true,
"env_variable": "ME_CONFIG_MONGODB_ADMINPASSWORD"
},
{
"type": "text",
"label": "Mongo Express Web Username",
"max": 50,
"min": 3,
"required": true,
"env_variable": "ME_CONFIG_BASICAUTH_USERNAME"
},
{
"type": "password",
"label": "Mongo Express Web Password",
"max": 50,
"min": 10,
"required": true,
"env_variable": "ME_CONFIG_BASICAUTH_PASSWORD"
}
]
}

View File

@ -0,0 +1,42 @@
version: "3.8"
services:
mongo-express:
container_name: mongo-express
image: mongo-express:1.0.0
restart: unless-stopped
ports:
- ${APP_PORT}:8081
networks:
- tipi_main_network
environment:
- ME_CONFIG_MONGODB_SERVER=mongo
- ME_CONFIG_MONGODB_ENABLE_ADMIN=true
- ME_CONFIG_MONGODB_ADMINUSERNAME=${ME_CONFIG_MONGODB_ADMINUSERNAME}
- ME_CONFIG_MONGODB_ADMINPASSWORD=${ME_CONFIG_MONGODB_ADMINPASSWORD}
- ME_CONFIG_BASICAUTH_USERNAME=${ME_CONFIG_BASICAUTH_USERNAME}
- ME_CONFIG_BASICAUTH_PASSWORD=${ME_CONFIG_BASICAUTH_PASSWORD}
labels:
# Main
traefik.enable: true
traefik.http.middlewares.mongo-express-web-redirect.redirectscheme.scheme: https
traefik.http.services.mongo-express.loadbalancer.server.port: 8081
# Web
traefik.http.routers.mongo-express-insecure.rule: Host(`${APP_DOMAIN}`)
traefik.http.routers.mongo-express-insecure.entrypoints: web
traefik.http.routers.mongo-express-insecure.service: mongo-express
traefik.http.routers.mongo-express-insecure.middlewares: mongo-express-web-redirect
# Websecure
traefik.http.routers.mongo-express.rule: Host(`${APP_DOMAIN}`)
traefik.http.routers.mongo-express.entrypoints: websecure
traefik.http.routers.mongo-express.service: mongo-express
traefik.http.routers.mongo-express.tls.certresolver: myresolver
# Local domain
traefik.http.routers.mongo-express-local-insecure.rule: Host(`mongo-express.${LOCAL_DOMAIN}`)
traefik.http.routers.mongo-express-local-insecure.entrypoints: web
traefik.http.routers.mongo-express-local-insecure.service: mongo-express
traefik.http.routers.mongo-express-local-insecure.middlewares: mongo-express-web-redirect
# Local domain secure
traefik.http.routers.mongo-express-local.rule: Host(`mongo-express.${LOCAL_DOMAIN}`)
traefik.http.routers.mongo-express-local.entrypoints: websecure
traefik.http.routers.mongo-express-local.service: mongo-express
traefik.http.routers.mongo-express-local.tls: true

View File

@ -0,0 +1,28 @@
# mongo-express
A web-based MongoDB admin interface written with Node.js, Express, and Bootstrap3
## Features
- Connect to multiple databases
- View/add/delete databases
- View/add/rename/delete collections
- View/add/update/delete documents
- Preview audio/video/image assets inline in the collection view
- Nested and/or large objects are collapsible for easy overview
- Async on-demand loading of big document properties (>100KB default) to keep collection view fast
- GridFS support - add/get/delete incredibly large files
- Use BSON data types in documents
- Mobile / Responsive - Bootstrap 3 works passably on small screens when you're in a bind
- Connect and authenticate to individual databases
- Authenticate as admin to view all databases
- Database blacklist/whitelist
- Custom CA and CA validation disabling
- Supports replica sets
## Screenshots
|Home Page|Database View|Collection View|Editing A Document|
|---|---|---|---|
|[![](https://camo.githubusercontent.com/bf9f84dbe8904f11cf1feee1257c384fc370f74b91aec78a27109466938c5676/687474703a2f2f692e696d6775722e636f6d2f58695968626c412e706e67 "Home Page showing databases")](https://camo.githubusercontent.com/bf9f84dbe8904f11cf1feee1257c384fc370f74b91aec78a27109466938c5676/687474703a2f2f692e696d6775722e636f6d2f58695968626c412e706e67)|[![](https://camo.githubusercontent.com/6933157b5afc955b83ed44edb82c87f9ce88e358515adc23d133cf7034dff0a1/687474703a2f2f692e696d6775722e636f6d2f585763496759312e706e67 "Viewing collections & buckets in a database")](https://camo.githubusercontent.com/6933157b5afc955b83ed44edb82c87f9ce88e358515adc23d133cf7034dff0a1/687474703a2f2f692e696d6775722e636f6d2f585763496759312e706e67)|[![](https://camo.githubusercontent.com/0d117c0fefa49f0f9d72d68633876694f6cc887915b26375375c073cc3b559d4/68747470733a2f2f696d6775722e636f6d2f556d47537233782e706e67 "Viewing documents in a collection")](https://camo.githubusercontent.com/0d117c0fefa49f0f9d72d68633876694f6cc887915b26375375c073cc3b559d4/68747470733a2f2f696d6775722e636f6d2f556d47537233782e706e67)|[![](https://camo.githubusercontent.com/7e5c4cea092e84aedb38a5a39acc86e4d69040a0fe8389ed22d705fc25833985/68747470733a2f2f696d6775722e636f6d2f6c4c333861626e2e706e67 "Editing a document")](https://camo.githubusercontent.com/7e5c4cea092e84aedb38a5a39acc86e4d69040a0fe8389ed22d705fc25833985/68747470733a2f2f696d6775722e636f6d2f6c4c333861626e2e706e67)|
These screenshots are from version 0.30.40 View the album for more screenshots: (server status, database views, etc..) [https://imgur.com/a/9vHsF](https://imgur.com/a/9vHsF)

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

38
apps/mongo/config.json Normal file
View File

@ -0,0 +1,38 @@
{
"$schema": "../schema.json",
"name": "MongoDB",
"id": "mongo",
"available": true,
"short_desc": "MongoDB is an open-source NoSQL database",
"author": "MongoDB",
"port": 27017,
"categories": [
"development",
"data"
],
"description": "MongoDB is an open-source document-oriented database that is designed to store a large scale of data and also allows you to work with that data very efficiently. It is categorized under the NoSQL (Not only SQL) database because the storage and retrieval of data in the MongoDB are not in the form of tables.",
"tipi_version": 1,
"version": "7.0.2",
"source": "https://github.com/mongodb/mongo",
"website": "https://www.mongodb.com/",
"exposable": true,
"no_gui": true,
"form_fields": [
{
"type": "text",
"label": "Admin Username",
"max": 50,
"min": 3,
"required": true,
"env_variable": "MONGO_INITDB_ROOT_USERNAME"
},
{
"type": "password",
"label": "Admin Password",
"max": 50,
"min": 10,
"required": true,
"env_variable": "MONGO_INITDB_ROOT_PASSWORD"
}
]
}

View File

@ -0,0 +1,38 @@
version: "3.8"
services:
mongo:
container_name: mongo
image: mongo:7.0.2
restart: unless-stopped
ports:
- ${APP_PORT}:27017
networks:
- tipi_main_network
environment:
- MONGO_INITDB_ROOT_USERNAME=${MONGO_INITDB_ROOT_USERNAME}
- MONGO_INITDB_ROOT_PASSWORD=${MONGO_INITDB_ROOT_PASSWORD}
labels:
# Main
traefik.enable: true
traefik.http.middlewares.mongo-web-redirect.redirectscheme.scheme: https
traefik.http.services.mongo.loadbalancer.server.port: 27017
# Web
traefik.http.routers.mongo-insecure.rule: Host(`${APP_DOMAIN}`)
traefik.http.routers.mongo-insecure.entrypoints: web
traefik.http.routers.mongo-insecure.service: mongo
traefik.http.routers.mongo-insecure.middlewares: mongo-web-redirect
# Websecure
traefik.http.routers.mongo.rule: Host(`${APP_DOMAIN}`)
traefik.http.routers.mongo.entrypoints: websecure
traefik.http.routers.mongo.service: mongo
traefik.http.routers.mongo.tls.certresolver: myresolver
# Local domain
traefik.http.routers.mongo-local-insecure.rule: Host(`mongo.${LOCAL_DOMAIN}`)
traefik.http.routers.mongo-local-insecure.entrypoints: web
traefik.http.routers.mongo-local-insecure.service: mongo
traefik.http.routers.mongo-local-insecure.middlewares: mongo-web-redirect
# Local domain secure
traefik.http.routers.mongo-local.rule: Host(`mongo.${LOCAL_DOMAIN}`)
traefik.http.routers.mongo-local.entrypoints: websecure
traefik.http.routers.mongo-local.service: mongo
traefik.http.routers.mongo-local.tls: true

View File

@ -0,0 +1,74 @@
# MongoDB
MongoDB is an open-source document-oriented database that is designed to store a large scale of data and also allows you to work with that data very efficiently. It is categorized under the NoSQL (Not only SQL) database because the storage and retrieval of data in the MongoDB are not in the form of tables. 
The MongoDB database is developed and managed by MongoDB.Inc under SSPL(Server Side Public License) and initially released in February 2009. It also provides official driver support for all the popular languages like C, C++, C#, and .Net, Go, Java, Node.js, Perl, PHP, Python, Motor, Ruby, Scala, Swift, Mongoid. So, that you can create an application using any of these languages. Nowadays there are so many companies that used MongoDB like Facebook, Nokia, eBay, Adobe, Google, etc. to store their large amount of data. 
## How it works ?
Now, we will see how actually thing happens behind the scene. As we know that MongoDB is a database server and the data is stored in these databases. Or in other words, MongoDB environment gives you a server that you can start and then create multiple databases on it using MongoDB. 
Because of its NoSQL database, the data is stored in the collections and documents. Hence the database, collection, and documents are related to each other as shown below: 
 
![mongodb-nosql-working](https://media.geeksforgeeks.org/wp-content/uploads/20200127193216/mongodb-nosql-working.jpg)
- The MongoDB database contains collections just like the MYSQL database contains tables. You are allowed to create multiple databases and multiple collections.
- Now inside of the collection we have documents. These documents contain the data we want to store in the MongoDB database and a single collection can contain multiple documents and you are schema-less means it is not necessary that one document is similar to another.
- The documents are created using the fields. Fields are key-value pairs in the documents, it is just like columns in the relation database. The value of the fields can be of any BSON data types like double, string, boolean, etc.
- The data stored in the MongoDB is in the format of BSON documents. Here, BSON stands for Binary representation of JSON documents. Or in other words, in the backend, the MongoDB server converts the JSON data into a binary form that is known as BSON and this BSON is stored and queried more efficiently.
- In MongoDB documents, you are allowed to store nested data. This nesting of data allows you to create complex relations between data and store them in the same document which makes the working and fetching of data extremely efficient as compared to SQL. In SQL, you need to write complex joins to get the data from table 1 and table 2. The maximum size of the BSON document is 16MB.
**NOTE:** In MongoDB server, you are allowed to run multiple databases. 
For example, we have a database named GeeksforGeeks. Inside this database, we have two collections and in these collections we have two documents. And in these documents we store our data in the form of fields. As shown in the below image: 
 
![](https://media.geeksforgeeks.org/wp-content/uploads/20200123222337/Untitled-Diagram-57.jpg)
**How mongoDB is different from RDBMS ?** 
Some major differences in between MongoDB and the RDBMS are as follows: 
 
|MongoDB|RDBMS|
|---|---|
|It is a non-relational and document-oriented database.|It is a relational database.|
|It is suitable for hierarchical data storage.|It is not suitable for hierarchical data storage.|
|It has a dynamic schema.|It has a predefined schema.|
|It centers around the CAP theorem (Consistency, Availability, and Partition tolerance).|It centers around ACID properties (Atomicity, Consistency, Isolation, and Durability).|
|In terms of performance, it is much faster than RDBMS.|In terms of performance, it is slower than MongoDB.|
|||
## Features of MongoDB
- **Schema-less Database:** It is the great feature provided by the MongoDB. A Schema-less database means one collection can hold different types of documents in it. Or in other words, in the MongoDB database, a single collection can hold multiple documents and these documents may consist of the different numbers of fields, content, and size. It is not necessary that the one document is similar to another document like in the relational databases. Due to this cool feature, MongoDB provides great flexibility to databases.
- **Document Oriented:** In MongoDB, all the data stored in the documents instead of tables like in RDBMS. In these documents, the data is stored in fields(key-value pair) instead of rows and columns which make the data much more flexible in comparison to RDBMS. And each document contains its unique object id.
- **Indexing:** In MongoDB database, every field in the documents is indexed with primary and secondary indices this makes easier and takes less time to get or search data from the pool of the data. If the data is not indexed, then database search each document with the specified query which takes lots of time and not so efficient.
- **Scalability:** MongoDB provides horizontal scalability with the help of sharding. Sharding means to distribute data on multiple servers, here a large amount of data is partitioned into data chunks using the shard key, and these data chunks are evenly distributed across shards that reside across many physical servers. It will also add new machines to a running database.
- **Replication:** MongoDB provides high availability and redundancy with the help of replication, it creates multiple copies of the data and sends these copies to a different server so that if one server fails, then the data is retrieved from another server.
- **Aggregation:** It allows to perform operations on the grouped data and get a single result or computed result. It is similar to the SQL GROUPBY clause. It provides three different aggregations i.e, aggregation pipeline, map-reduce function, and single-purpose aggregation methods
- **High Performance:** The performance of MongoDB is very high and data persistence as compared to another database due to its features like scalability, indexing, replication, etc.
**Advantages of MongoDB :** 
 
- It is a schema-less NoSQL database. You need not to design the schema of the database when you are working with MongoDB.
- It does not support join operation.
- It provides great flexibility to the fields in the documents.
- It contains heterogeneous data.
- It provides high performance, availability, scalability.
- It supports Geospatial efficiently.
- It is a document oriented database and the data is stored in BSON documents.
- It also supports multiple document ACID transition(string from MongoDB 4.0).
- It does not require any SQL injection.
- It is easily integrated with Big Data Hadoop
**Disadvantages of MongoDB :** 
 
- It uses high memory for data storage.
- You are not allowed to store more than 16MB data in the documents.
- The nesting of data in BSON is also limited you are not allowed to nest data more than 100 levels.
## Learn MongoDB
- Documentation - [https://docs.mongodb.com/manual/](https://docs.mongodb.com/manual/)
- Developer Center - [https://www.mongodb.com/developer/](https://www.mongodb.com/developer/)
- MongoDB University - [https://learn.mongodb.com](https://learn.mongodb.com/)

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

View File

@ -4,7 +4,7 @@
### Setting Up an Exposed Instance with SSL Certs
As Owncast uses the RTMP protocol for ingesting incoming streams, the typical Cloudflare Zero Access configuration will not work as it does not have RTMP as an option for routing.
You can optionally follow [this guide](https://gist.github.com/HeyOsco/6e8102d7d82ffaeaae16f41bef98b739) for setting up an exposed Owncast server with your RunTipi instance.
You can optionally follow [this guide](https://gist.github.com/oscoDOTblog/6e8102d7d82ffaeaae16f41bef98b739) for setting up an exposed Owncast server with your RunTipi instance.
### Admin Dashboard Access