Logic in Code,
Freedom in Travel.

인생 뭐 있나 사람 사는거 다 똑같지

Programming

Programming/$_머니 (PHP)

[Homestead] - Laravel vagrant php7.4-fpm.service not working

현황 PHP 버전을 잘못잡고 있음 ip: 192.168.56.56 memory: 2048 cpus: 1 provider: virtualbox authorize: ~/.ssh/id_rsa.pub keys: - ~/.ssh/id_rsa folders: - map: /home/kyungseo-park/code/project to: /home/vagrant/code sites: - map: project.test to: /home/vagrant/code/public # php: "7.4" 가 아니라 php: "8.1" # 으로 해야했다. Laravel 버전 올리면서 발생한 이슈.... wildcard: "yes" databases: - project features: - mysql: true - mariadb:..

2024. 2. 21. 01:59
Programming/$_머니 (PHP)

[Laravel] 라라벨 Slug 한글 이슈

Helper 함수 Slug Str::slug('대한 독립 만세', '-') 아래와 같이 코드를 작성할 경우 한글이 출력되지 않는다. 그 이유는 문자열을 ASCII로 변환하기 때문이다. 한글은 유니코드 이기 때문에 ASCII 로 변환된 Slug 에서는 해당 이슈를 처리하지 못한다. Route::get('/', function (){ return \Illuminate\Support\Str::slug("대한 독립 만세", '-'); }); Str::slug('대한 독립 만세', '-', 'ko') Slug 에는 3개의 인자를 작성해야한다. Str::slug('문자', '바꿀거', '언어'); 하지만 문자를 ASCII 로 변환하기 때문이 한글은 출력되지 않는다. 하지만 PHP ext-intl 익스텐션을 통해 한..

2024. 2. 21. 01:57
Programming/스프링 부트(Spring Boot)

[Spring Boot] - jasypt 을 사용하여 암/복호화 하기

jasypt란 양방향 암호화를 사용할 수 있는 Java 라이브러리이다. 시스템 환경변수와 마찬가지로 소스코드가 외부에 반출되더라도 중요한 Access/Secret key 등 중요한 정보가 평문으로 노출되는 것을 방지하고자 하는 목적으로 사용된다. Dependency 추가 방법 Maven com.github.ulisesbocchio jasypt-spring-boot-starter 3.0.4 Gradle implementation 'com.github.ulisesbocchio:jasypt-spring-boot-starter:3.0.4' Jasypt 설정 및 Bean 등록 System.getenv("ENCRYPTOR_PASSWORD"); 라고 작성되어 있는 부분이 암호화된 ENC 을 디코딩하기 위한 Key 이..

2024. 2. 20. 13:09
Programming/스프링 부트(Spring Boot)

[Spring Boot] - QueryDSL Error Attempt to recreate a file for type

Attempt to recreate a file for type ~~.global.entity.QBaseTimeEntity 이런 에러가 발생했다. 내가 사용중인 build.gradle 은 이렇다. // Querydsl 추가 implementation 'com.querydsl:querydsl-jpa:5.0.0:jakarta' annotationProcessor 'com.querydsl:querydsl-apt:5.0.0:jakarta' annotationProcessor "jakarta.annotation:jakarta.annotation-api" annotationProcessor "jakarta.persistence:jakarta.persistence-api" querydsl { jpa = true } ..

2024. 2. 19. 00:58
Programming/$_머니 (PHP)

[PHP - Laravel] 라라벨 원하는 버전 설치하기 (버전별 관리)

더보기 2022 년도에 작성된 글 입니다. Composer 설치 라라벨을 설치하는 것을 보면 Composer 로 설치하는 것을 볼 수 있다. 프로젝트 이름 : 생성할 프로젝트 이름이다. 버전 : https://packagist.org/packages/laravel/laravel 등록된 version 이다. composer create-project --prefer-dist laravel/laravel [프로젝트 이름] [버전] composer create-project --prefer-dist laravel/laravel laravel-8-crud-app v8.6.11 GIT 설치 https://github.com/laravel/laravel 레포를 Clone 받는다. https://github.com/..

2024. 2. 9. 22:50