읽지 않은 메일에 있길래 호기심에 눌러보았거늘 크롬이 차단해버리네 ㅠㅠ



Posted by 구차니

설치

postgresql 은 client

postgresql-server 는 server

# yum install postgresql  postgresql-server 


db 초기화

# service postgresql initdb

(그냥 centos7 에서 이렇게 하니 Encoding이 SQL_ASCII로 Collate가 C로 된다.. 아놔..)

+

$ su -l postgres -c "initdb -E UTF8 --locale=ko_KR.UTF-8 --locale=en_US.utf8"



설정 확인

# chkconfig postgresql on 


서비스 시작

# systemctl start postgresql 

[링크 : https://wiki.postgresql.org/wiki/YUM_Installation]

[링크 : https://www.lesstif.com/pages/viewpage.action?pageId=31850584]


사용자 생성 (암호 없이)

# sudo -i -u postgres

# psql

postgres=# create user [계정아이디] with password '';

postgres=# create database [데이터베이스 이름];

postgres=# \q

# exit

[링크 : https://www.lesstif.com/pages/viewpage.action?pageId=61899197]

[링크 : http://database.sarang.net/database/postgres/tutorial/lecture/x58.htm]


+

2019.06.18

sudo -u postgres psql postgres

# \password postgres

Enter new password:  

[링크 : https://serverfault.com/questions/110154/...]


암호 바꾸기

postgres=# ALTER USER postgres WITH PASSWORD ''; 


[링크 : https://stackoverflow.com/questions/5421807/set-blank-password-for-postgresql-user]


접속되지 않을 경우

connect to PostgreSQL server: FATAL: no pg_hba.conf entry for host

# vim /var/lib/pgsql/data/pg_hba.conf

host all all      ::1/128      trust

host all postgres 127.0.0.1/32 trust 


# vim /var/lib/pgsql/data/pg_hba.conf 

listen_addresses = '*'

[링크 : https://dba.stackexchange.com/.../connect-to-postgresql-server-fatal-no-pg-hba-conf-entry-for-host]

[링크 : https://sysops.tistory.com/8]


+

2019.06.18

서비스 재시작만으로는 포트가 안바뀌는 듯..(ubuntu 18.04) 그래서 완전히 재기동을 해야 하는 문제가 있었음


[링크 : https://blog.bigbinary.com/2016/01/23/configure-postgresql-to-allow-remote-connection.html]


+

2020.01.16

psql 상에서 현재 db의 locale을 확인할 수 있다.

# show LC_COLLATE;

[링크 : https://linux.systemv.pe.kr/postgresql-과-문자셋/]

'프로그램 사용 > postgreSQL' 카테고리의 다른 글

postgresql WAL?  (0) 2019.03.14
postgresql encoding / collate  (0) 2019.03.08
postgreSQL centos 패키지  (0) 2019.02.01
postgreSQL 명령어 정리  (0) 2019.02.01
psql - postgreSQL CLI client  (0) 2019.02.01
Posted by 구차니

으으 얼마전에 검색하고 잊고 있던 단어인가...

망할(?) 10GbE NIC이 하나만 더 있었어도 고민을 안했을텐데..

4개 짜리 GbE만 서버에 꽂혀있어서 고민을 하는 중..


대개는 관리허브가 필요해서(L3) 못하는데 balance-alb 요건 허브없이 가능하지만

NIC에서 MAC을 변경할수있는 드라이버가 필요하다고..(이게 더 까다로워 보이는데..)

[링크 : http://www.mikrotik.co.kr/wiki/index.php/메뉴얼:Bonding#balance-alb]

[링크 : https://onecellboy.tistory.com/279]

[링크 : https://www.lesstif.com/pages/viewpage.action?pageId=6979680]


된다는겨 안된다는겨..

[링크 : https://access.redhat.com/.../deployment_guide/sec-configuring_a_vlan_over_a_bond]

Posted by 구차니
Programming/Java(Spring)2019. 3. 8. 15:54

별건 없고

아래처럼 dependencies에 jar을 넣어주면 된다.

dependencies {

    compile files('libs/lombok-1.16.8.jar')

[링크 : https://jsonobject.tistory.com/222]

'Programming > Java(Spring)' 카테고리의 다른 글

Transaction was marked for rollback only; cannot commit  (0) 2019.03.25
spring boot cassandra  (0) 2019.03.08
maven 빌드하기  (0) 2019.03.08
spring 변수 생명주기  (0) 2019.01.08
gradle buildship  (0) 2019.01.02
Posted by 구차니
Programming/Java(Spring)2019. 3. 8. 14:37

pom.xml이 있으면 maven으로 빌드가 가능한건데


maven 설치하기

(패키지 설치가 아니라 maven을 다운로드 받아서 해당 경로 패스 정해주면 끝)

[링크 : https://blog.hanumoka.net/2018/05/23/centOs-20180523-centos-install-maven/]


maven 프로젝트 빌드하기

$ mvn pakage

[링크 : https://brocess.tistory.com/164]

'Programming > Java(Spring)' 카테고리의 다른 글

spring boot cassandra  (0) 2019.03.08
gradle 에 jar 추가하여 빌드하기  (0) 2019.03.08
spring 변수 생명주기  (0) 2019.01.08
gradle buildship  (0) 2019.01.02
spring for android  (0) 2018.12.28
Posted by 구차니

3월 31일 만료인게 몇개 있다고 해서 모은김에 또 기부!



Posted by 구차니
Programming/node.js2019. 3. 8. 10:56

node.js랑 그래도 작동하는건 확인했는데..

임시 파일이 어디로 갔는지 모르겠네?


아래 링크는 파일 / 이미지 / 동영상 세파트로 나누어져 있으니 참고

(index.html 파일 내용도 조금씩 다르니 주의)

[링크 : https://www.froala.com/wysiwyg-editor/docs/server/nodejs/file-upload]


+

일단은 이녀석.. localhost를 제외하면 라이센스 경고를 띄운다.

쓰는건 보류!

'Programming > node.js' 카테고리의 다른 글

node.js 사용자 모듈 만들기  (0) 2019.03.13
ckeditor 와 php, node.js 연동  (0) 2019.03.11
wysiwyg editor / node.js  (0) 2019.02.26
node.js 파비콘 설정하기  (0) 2019.02.22
node.js apache 스타일 로그  (0) 2019.02.22
Posted by 구차니

클래식

상단에 툴바 항상 나오고 그 바로 아래에 수정할 영역이 나옴


인라인

그냥 일반 문장 같은데


클릭하면 편집 가능하도록 변경됨


벌룬

인라인과 유사한데 드래그로 선택해야 툴바가 풍선으로 뜸


벌룬블록

선택영역에 따라 문단과 블록에 따라 서로 다른 툴바가 뜸


디커플러

툴바와 편집창을 분리해서 쓸 수 있다.

(문단별로 편집창을 띄우되 가장 위에 고정하는 식으로 운영 가능, 스크롤 할때 상단에 툴바 고정용으로 쓸 듯)


[링크 : https://ckeditor.com/docs/ckeditor5/latest/builds/guides/quick-start.html]

Posted by 구차니

첫애가 생일이라서 마트 키즈카페 놀러갔다가 맞은편에 있는 VR 코너를 

아내와 첫애가 해봤는데 아내 평으로는 생각외로 화질이 안 좋다고

애는 어지러워 하고이래저래 아주 만족스럽지는 않았던 듯.

걍 한번 해본걸로 됐다 정도?


가격은 개당 30만원 정도인데

5.5인치에 2560*1440P(PPI 534)

어떻게 보면 갤럭시 노트 시리즈 급의 해상도는 되는 듯?

그럼 Stream VR 통해서 재생하는 설정이 문제거나.. 컨텐츠가 문제거나


게다가 시야도 연동 안되고 고정 시야라고..

근데 스펙상으로는 6 DOF 인데? 머야 -ㅁ-



가격은 산게 26만원. 디스플레이 스펙을 보면 그리 비싼것도 아닌 듯?

[링크 : http://item.gmarket.co.kr/Item?goodsCode=1512970342]

[링크 : https://eleparts.co.kr/goods/view?no=6949223]

[링크 : http://prod.danawa.com/info/?pcode=6226272]


[링크 : http://en.3dinlife.com/prod_view8.aspx?FId=t3:72:3&Id=191&TypeId=72&IsActiveTarget=True]

Posted by 구차니

-

[링크 : https://gist.github.com/RedactedProfile/ac48c270d2bbe739f9f3]

[링크 : https://ckeditor.com/docs/ckeditor4/latest/examples/fileupload.html]

[링크 : https://hashcode.co.kr/questions/3187/nodejs-ckeditor로-이미지를-올리기]

[링크 : https://www.npmjs.com/package/ckeditor]


+

2019.03.08

cke4_node.zip


ckeditor 4.11 을 기준으로 만든거고, 5.x 대에도 가능한지는 아직 테스트 하지 못함

express -e

를 이용하여 ejs로 express-generator로 생성후 아래의 파일을 수정함


index.js

var express = require('express');
var path = require('path');
var uuid = require('uuidv4');
var router = express.Router();

var multipart = require('connect-multiparty');
var multipartMiddleware = multipart();

/* GET home page. */
router.get('/', function (req, res, next) {
res.render('index', { title: 'Express' });
});

router.post('/uploader', multipartMiddleware, function (req, res) {
var fs = require('fs');

var orifilepath = req.files.upload.path;
var orifilename = req.files.upload.name;
var srvfilename = uuid() + path.extname(orifilename);
fs.readFile(orifilepath, function (err, data) {
var newPath = __dirname + '/../public/uploads/' + srvfilename;
fs.writeFile(newPath, data, function (err) {
if (err) console.log({ err: err });
else {
html = "{\"filename\" : \"" + orifilename + "\", \"uploaded\" : 1, \"url\": \"/uploads/" + srvfilename + "\"}"
console.log(html)
res.send(html);
}
});
});
});

module.exports = router;


index.ejs

4.11과 4.9 둘 다 작동되는 것 확인

<!DOCTYPE html>
<html>

<head>
<title><%= title %></title>
<link rel='stylesheet' href='/stylesheets/style.css' />
<!-- <script src="https://cdn.ckeditor.com/4.11.3/standard/ckeditor.js"></script> -->
<script src="https://cdn.ckeditor.com/4.9.0/standard/ckeditor.js"></script>
</head>

<body>
<h1><%= title %></h1>
<p>Welcome to <%= title %></p>

<form>
<textarea id="ckeditor" name="content"></textarea>
</form>

<script>
CKEDITOR.replace('ckeditor', {
uploadUrl: '/uploader'
});
</script>
</body>

</html>


+

ckeditor 5 기준. 4랑 비교해서 에디터 생성하는 방법을 제외하면 동일하게 작동한다.

index.ejs

<!DOCTYPE html>
<html>

<head>
<title><%= title %></title>
<link rel='stylesheet' href='/stylesheets/style.css' />
<script src="https://cdn.ckeditor.com/ckeditor5/12.0.0/classic/ckeditor.js"></script>
</head>

<body>
<h1><%= title %></h1>
<p>Welcome to <%= title %></p>

<form>
<textarea id="ckeditor" name="content"></textarea>
</form>

<script>
ClassicEditor
.create(document.querySelector('#ckeditor'), {
language: 'ko',
ckfinder: {
uploadUrl: '/uploader'
}
})
.catch(error => {
console.error(error);
});
</script>
</body>

</html>


[링크 : https://okky.kr/article/461219]

[링크 : https://www.cikorea.net/bbs/view/qna?idx=19725&view_category=&lists_style=]

[링크 : https://ckeditor.com/docs/ckeditor4/latest/guide/dev_file_upload.html]


[링크 : https://stackoverflow.com/questions/17699763/ckeditor-using-and-integration-in-node-js-web-page]

[링크 : https://stackoverflow.com/questions/21378630/node-js-sails-js-wysiwyg-editor-images]

[링크 : https://github.com/sca-/sails-ckeditor-sample]



'프로그램 사용 > ckeditor(웹에디터)' 카테고리의 다른 글

ckeditor full과 standard 그리고 옵션 설정  (0) 2019.04.03
ckeditor 모드별 모양  (0) 2019.03.08
ckeditor / fckeditor?  (0) 2014.07.16
ckeditor 사용하기  (0) 2013.02.22
fckeditor plugin for squirrelMail  (0) 2011.06.14
Posted by 구차니