mirror of
https://github.com/Shadowfita/docmost.git
synced 2025-11-26 06:31:07 +10:00
Compare commits
1 Commits
15eb997c92
...
SMTP-Ignor
| Author | SHA1 | Date | |
|---|---|---|---|
| 0bfd3b6771 |
@ -32,6 +32,7 @@ SMTP_PORT=587
|
||||
SMTP_USERNAME=
|
||||
SMTP_PASSWORD=
|
||||
SMTP_SECURE=false
|
||||
SMTP_IGNORETLS=false
|
||||
|
||||
# Postmark driver config
|
||||
POSTMARK_TOKEN=
|
||||
|
||||
47
.github/workflows/main.yml
vendored
47
.github/workflows/main.yml
vendored
@ -1,47 +0,0 @@
|
||||
name: Sync Merged-Downstream with Docmost Upstream Main
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '0 0 * * *' # Run daily at midnight UTC
|
||||
|
||||
jobs:
|
||||
sync:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0 # Fetch all history to detect changes properly
|
||||
|
||||
- name: Set up git
|
||||
run: |
|
||||
git config --global user.name "Shadowfita"
|
||||
git config --global user.email "www.ryan.palmer@hotmail.com"
|
||||
|
||||
- name: Fetch upstream
|
||||
run: |
|
||||
git remote add upstream https://github.com/docmost/docmost.git
|
||||
git fetch upstream
|
||||
|
||||
- name: Check if upstream has changes
|
||||
id: check_changes
|
||||
run: |
|
||||
UPSTREAM_DIFF=$(git diff --name-only upstream/main)
|
||||
if [ -z "$UPSTREAM_DIFF" ]; then
|
||||
echo "No changes in upstream main branch."
|
||||
echo "::set-output name=changes::false"
|
||||
else
|
||||
echo "Changes detected in upstream main branch."
|
||||
echo "::set-output name=changes::true"
|
||||
fi
|
||||
|
||||
- name: Merge upstream/main into Merged-Downstream
|
||||
if: steps.check_changes.outputs.changes == 'true'
|
||||
run: |
|
||||
git checkout Merged-Downstream
|
||||
git merge upstream/main
|
||||
|
||||
- name: Push changes to Merged-Downstream
|
||||
if: steps.check_changes.outputs.changes == 'true'
|
||||
run: |
|
||||
git push origin Merged-Downstream
|
||||
@ -98,6 +98,13 @@ export class EnvironmentService {
|
||||
return secure === 'true';
|
||||
}
|
||||
|
||||
getSmtpIgnoreTLS(): boolean {
|
||||
const ignoretls = this.configService
|
||||
.get<string>('SMTP_IGNORETLS', 'false')
|
||||
.toLowerCase();
|
||||
return ignoretls === 'true';
|
||||
}
|
||||
|
||||
getSmtpUsername(): string {
|
||||
return this.configService.get<string>('SMTP_USERNAME');
|
||||
}
|
||||
|
||||
@ -41,6 +41,7 @@ export const mailDriverConfigProvider = {
|
||||
connectionTimeout: 30 * 1000, // 30 seconds
|
||||
auth,
|
||||
secure: environmentService.getSmtpSecure(),
|
||||
ignoreTLS: environmentService.getSmtpIgnoreTLS()
|
||||
} as SMTPTransport.Options,
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user