Skip to content

Commit a5bb0d6

Browse files
authored
Merge pull request #1379 from hackmdio/release/1.4.1
Release/1.4.1
2 parents a0cc195 + 5208533 commit a5bb0d6

File tree

15 files changed

+294
-36
lines changed

15 files changed

+294
-36
lines changed

.buildpacks

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
https://github.com/alex88/heroku-buildpack-vips
2+
https://github.com/Scalingo/nodejs-buildpack

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ If you want to contribute to the project, start with [manual deployment](https:/
5151
CodiMD is highly customizable, learn about all configuration options of networking, security, performance, resources, privilege, privacy, image storage, and authentication in [CodiMD Configuration](https://hackmd.io/c/codimd-documentation/%2Fs%2Fcodimd-configuration).
5252

5353
### Upgrading and Migration
54-
Upgrade CodiMD from previous version? See [this guide](https://hackmd.io/c/codimd-documentation/%2Fs%2Fcodimd-upgrade)
54+
Upgrade CodiMD from previous version? See [this guide](https://hackmd.io/c/codimd-documentation/%2Fs%2Fcodimd-upgrade)<br>
5555
Migrating from Etherpad? Follow [this guide](https://hackmd.io/c/codimd-documentation/%2Fs%2Fcodimd-migration-etherpad)
5656

5757
### Developer

bin/manage_users

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,9 @@ function getPass (argv, action) {
3737
async function createUser (argv) {
3838
const existingUser = await models.User.findOne({ where: { email: argv['add'] } })
3939
// Cannot create already-existing users
40-
if (existingUser !== undefined) {
40+
if (existingUser) {
4141
console.log(`User with e-mail ${existingUser.email} already exists! Aborting ...`)
42-
process.exit(1)
42+
process.exit(2)
4343
}
4444

4545
const pass = getPass(argv, 'add')
@@ -56,7 +56,7 @@ async function createUser (argv) {
5656
async function deleteUser (argv) {
5757
// Cannot delete non-existing users
5858
const existingUser = await models.User.findOne({ where: { email: argv['del'] } })
59-
if (existingUser === undefined) {
59+
if (!existingUser) {
6060
console.log(`User with e-mail ${argv['del']} does not exist, cannot delete`)
6161
process.exit(1)
6262
}
@@ -71,7 +71,7 @@ async function deleteUser (argv) {
7171
async function resetUser (argv) {
7272
const existingUser = await models.User.findOne({ where: { email: argv['reset'] } })
7373
// Cannot reset non-existing users
74-
if (existingUser === undefined) {
74+
if (!existingUser) {
7575
console.log(`User with e-mail ${argv['reset']} does not exist, cannot reset`)
7676
process.exit(1)
7777
}

deployments/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ RUN set -xe && \
1515
yarn.lock webpack.prod.js webpack.htmlexport.js webpack.dev.js webpack.common.js \
1616
config.json.example README.md CONTRIBUTING.md AUTHORS
1717

18-
FROM hackmdio/runtime:1.0.4
18+
FROM hackmdio/runtime:1.0.6
1919
USER hackmd
2020
WORKDIR /home/hackmd/app
2121
COPY --chown=1500:1500 --from=BUILD /home/hackmd/app .

deployments/docker-compose.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@ services:
1010
- "database-data:/var/lib/postgresql/data"
1111
restart: always
1212
codimd:
13+
# you can use image or custom build below
14+
# image: nabo.codimd.dev/hackmdio/hackmd:1.4.0
1315
build:
1416
context: ..
1517
dockerfile: ./deployments/Dockerfile

deployments/docker-entrypoint.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ if [[ "$#" -gt 0 ]]; then
88
fi
99

1010
# check database and redis is ready
11-
pcheck -constr "$CMD_DB_URL"
11+
pcheck -env CMD_DB_URL
1212

1313
# run DB migrate
1414
NEED_MIGRATE=${CMD_AUTO_MIGRATE:=true}

lib/web/imageRouter/minio.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ const Minio = require('minio')
1010
const minioClient = new Minio.Client({
1111
endPoint: config.minio.endPoint,
1212
port: config.minio.port,
13-
secure: config.minio.secure,
13+
useSSL: config.minio.secure,
1414
accessKey: config.minio.accessKey,
1515
secretKey: config.minio.secretKey
1616
})

lib/web/imageRouter/s3.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ exports.uploadImage = function (imagePath, callback) {
2929
const params = {
3030
Bucket: config.s3bucket,
3131
Key: path.join('uploads', path.basename(imagePath)),
32-
Body: buffer
32+
Body: buffer,
33+
ACL: 'public-read'
3334
}
3435

3536
const mimeType = getImageMimeType(imagePath)

package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "codimd",
3-
"version": "1.4.0",
3+
"version": "1.4.1",
44
"description": "Realtime collaborative markdown notes on all platforms.",
55
"keywords": [
66
"Collaborative",
@@ -101,10 +101,11 @@
101101
"mermaid": "~8.2.3",
102102
"method-override": "~3.0.0",
103103
"minimist": "~1.2.0",
104-
"minio": "~7.0.10",
104+
"minio": "^7.0.12",
105105
"moment": "~2.24.0",
106106
"morgan": "~1.9.1",
107107
"mysql": "~2.17.1",
108+
"mysql2": "^2.0.1",
108109
"passport": "~0.4.0",
109110
"passport-dropbox-oauth2": "~1.1.0",
110111
"passport-facebook": "~2.1.1",
@@ -129,7 +130,7 @@
129130
"reveal.js": "~3.7.0",
130131
"scrypt": "~6.0.3",
131132
"select2": "~3.5.2-browserify",
132-
"sequelize": "5.3.5",
133+
"sequelize": "5.15.1",
133134
"sequelize-cli": "~5.4.0",
134135
"shortid": "~2.2.14",
135136
"socket.io": "~2.2.0",

public/docs/release-notes.md

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,27 @@
11
Release Notes
22
===
33

4+
<i class="fa fa-tag"></i> 1.4.1 <i class="fa fa-clock-o"></i> 2019-12-13
5+
---
6+
7+
[CodiMD 1.4.1](https://github.com/hackmdio/codimd/releases/tag/1.4.1) is a minor release including bug fixes introduced in 1.4.0 and earlier versions. We encourage everyone to upgrade to 1.4.1 now. Also, we're preparing for the next major release, and you can see how things are going on [GitHub](https://github.com/hackmdio/codimd/pulls?q=is%3Apr+is%3Aopen+sort%3Aupdated-desc+milestone%3ANext). Stay tuned, and we hope you love it!
8+
9+
### Fixes
10+
11+
- Fix urlpath in webpack build
12+
- Fix mysql not bundled in package.json
13+
- Fix minio image uploading
14+
- Fix pcheck not parsed url correctly
15+
- Fix manage_users script
16+
17+
### Enhancement
18+
19+
- Added Scalingo compatible deployment
20+
21+
[Check out the complete release note][v1_4_1]. Thank you CodiMD community and all our contributors. ❤️
22+
23+
[v1_4_1]: https://hackmd.io/@codimd/release-notes/%2F%40codimd%2Fv1_4_1
24+
425
<i class="fa fa-tag"></i> 1.4.0 Syrmaticus mikado <i class="fa fa-clock-o"></i> 2019-11-11
526
---
627

@@ -20,7 +41,7 @@ It has been over 200+ commits since our last release. These are the highlights f
2041
- [New Emoji sets][new-emoji]
2142
- [Slide mode plugins][slide-mode-plugins]: Elapsed time bar and Spotlight
2243

23-
[Go read the complete release note here][v1_4_0]. Thank you CodiMD community and all our contributors. ❤️
44+
[Check out the complete release note][v1_4_0]. Thank you CodiMD community and all our contributors. ❤️
2445

2546
[table-tools]: https://hackmd.io/@codimd/v1_4_0#New-Table-Tools
2647
[markdownlint]: https://hackmd.io/@codimd/v1_4_0#Markdownlint-integration

0 commit comments

Comments
 (0)