Skip to content

Add Env Var for cookie max age: #1221

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,11 @@ public static class Workspace {
@Data
public static class Cookie {
//Set cookie max age to 1 day
private long maxAgeInSeconds = Duration.ofDays(1).toSeconds();
private long maxAgeInHours = 24;

public long getMaxAgeInSeconds() {
return Duration.ofHours(maxAgeInHours).toSeconds();
}
}

@Data
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ common:
private-mode: ${LOWCODER_MARKETPLACE_PRIVATE_MODE:true}
lowcoder-public-url: ${LOWCODER_PUBLIC_URL:http://localhost:3000}
notifications-email-sender: ${LOWCODER_EMAIL_NOTIFICATIONS_SENDER:info@localhost}
cookie:
max-age-in-hours: ${LOWCODER_COOKIE_MAX_AGE:24}

debug: true

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,8 @@ common:
private-mode: ${LOWCODER_MARKETPLACE_PRIVATE_MODE:true}
lowcoder-public-url: ${LOWCODER_PUBLIC_URL:http://localhost:3000}
notifications-email-sender: ${LOWCODER_EMAIL_NOTIFICATIONS_SENDER:info@localhost}
cookie:
max-age-in-hours: ${LOWCODER_COOKIE_MAX_AGE:24}

material:
mongodb-grid-fs:
Expand Down
Loading