Fix deploy cookie domain

This commit is contained in:
august kline 2024-11-14 17:47:45 -05:00
parent 6286352b5e
commit cc5af850ce
3 changed files with 7 additions and 3 deletions

View File

@ -2,9 +2,11 @@
# this only works on macos for now, cross compilation toolchain from https://github.com/messense/homebrew-macos-cross-toolchains # this only works on macos for now, cross compilation toolchain from https://github.com/messense/homebrew-macos-cross-toolchains
set -e;
cargo update; cargo update;
CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=x86_64-linux-gnu-gcc cargo build --release --target x86_64-unknown-linux-gnu; DOMAIN=evieippolito.com CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=x86_64-linux-gnu-gcc cargo build --release --target x86_64-unknown-linux-gnu;
scp target/x86_64-unknown-linux-gnu/release/evie kline@augustkline.com:/home/kline/; scp target/x86_64-unknown-linux-gnu/release/evie kline@augustkline.com:/home/kline/;

View File

@ -114,7 +114,7 @@ impl BlogStateInner {
async fn new() -> anyhow::Result<Self> { async fn new() -> anyhow::Result<Self> {
let username = env!("INIT_USER_NAME").to_string(); let username = env!("INIT_USER_NAME").to_string();
let password = env!("INIT_USER_PASSWORD").to_string(); let password = env!("INIT_USER_PASSWORD").to_string();
let domain = env!("DOMAIN").to_string(); let domain = option_env!("DOMAIN").unwrap_or("localhost").to_string();
let db = BlogDb::new(&username, password.clone()).await?; let db = BlogDb::new(&username, password.clone()).await?;
Self::add_initial_assets(&db).await?; Self::add_initial_assets(&db).await?;
Self::add_initial_pages(&db).await?; Self::add_initial_pages(&db).await?;

View File

@ -2,9 +2,11 @@
# this only works on macos for now, cross compilation toolchain from https://github.com/messense/homebrew-macos-cross-toolchains # this only works on macos for now, cross compilation toolchain from https://github.com/messense/homebrew-macos-cross-toolchains
set -e
cargo update; cargo update;
CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=x86_64-linux-gnu-gcc cargo build --release --target x86_64-unknown-linux-gnu; DOMAIN=evieippolito.com CARGO_TARGET_X86_64_UNKNOWN_LINUX_GNU_LINKER=x86_64-linux-gnu-gcc cargo build --release --target x86_64-unknown-linux-gnu;
scp target/x86_64-unknown-linux-gnu/release/evie kline@augustkline.com:/home/kline/; scp target/x86_64-unknown-linux-gnu/release/evie kline@augustkline.com:/home/kline/;