본문 바로가기
퍼블리싱

[ATOM]아톰에서 Remote FTP로 FTP 연결하기

by 친절한 당근 2020. 3. 12.
반응형

[ATOM]아톰에서 Remote FTP로 FTP 연결하기

안녕하세요. 오늘은 아톰에서 FTP로 바로 접근할 수 있는 패키지 Remote-FTP를 설치해보고 연결해보겠습니다.

참고로 아톰은 https://atom.io/에서 다운받으실 수 있어요.

썸네일

 

아톰 초기화면

오랜만에 아톰을 새로 깔았습니다. 여기서 Install a Package를 눌러서 들어가세요. Open Intaller를 클릭하시면

패키지를 검색할 수 있는 창이 나옵니다. 

remote-ftp 인스톨

remote ftp를 검색하세요. 여러가지 패키지가 나오지만 저는 icetee라는 사람이 만든 remote-ftp를 설치할거예요.

다운로드수도 제일 많네요. 인스톨 버튼을 눌러줍니다.

상단 패키지(packages) 메뉴에 들어가보면 가장 하단에 Remote FTP가 있죠? 잘 설치된겁니다.

Toggle을 눌러보니까 왼쪽에 뭔가 메뉴들이 생기네요. 커넥트를 눌러보면...?

버그

오류가 뜨면서 아무일도 일어나지 않습니다.


초기에는 FTP 접속용 config파일을 만들어줘야해요. Edit Configuration을 눌러서 config파일을 만들어줍시다.

그럼 새 파일 창이 하나 뜨는데요. 여기에 뭘 입력해야할까요?

remote-ftp 인스톨 때 settings를 누르면 나오는 화면입니다. 여기에서 FTP Configuration Options라고 나와있는 이 부분을 복사해서 자신의 호스트(도메인주소), 포트(21), 유저(아이디), 패스(FTP비밀번호) 등을 입력하면 되는 것입니다.

아래에 코드를 붙여놓을게요.

{
    "protocol": "ftp",
    "host": "도메인 주소", // string - The hostname or IP address of the FTP server. Default: 'localhost'
    "port": 21, // integer - The port of the FTP server. Default: 21
    "user": "아이디", // string - Username for authentication. Default: 'anonymous'
    "pass": "비밀번호", // string - Password for authentication. Default: 'anonymous@'
    "promptForPass": false, // boolean - Set to true for enable password dialog. This will prevent from using cleartext password in this config. Default: false
    "remote": "/",
    "secure": false, // mixed - Set to true for both control and data connection encryption, 'control' for control connection encryption only, or 'implicit' for implicitly encrypted control connection (this mode is deprecated in modern times, but usually uses port 990) Default: false
    "secureOptions": null, // object - Additional options to be passed to tls.connect(). Default: (null) see https://nodejs.org/api/tls.html#tls_tls_connect_options_callback
    "connTimeout": 10000, // integer - How long (in milliseconds) to wait for the control connection to be established. Default: 10000
    "pasvTimeout": 10000, // integer - How long (in milliseconds) to wait for a PASV data connection to be established. Default: 10000
    "keepalive": 10000, // integer - How often (in milliseconds) to send a 'dummy' (NOOP) command to keep the connection alive. Default: 10000\. If set to 0, keepalive is disabled.
    "watch":[ // array - Paths to files, directories, or glob patterns that are watched and when edited outside of the atom editor are uploaded. Default : []
        "dist/stylesheets/main.css", // reference from the root of the project.
        "dist/stylesheets/",
        "dist/stylesheets/*.css"
    ],
    "watchTimeout":500 // integer - The duration ( in milliseconds ) from when the file was last changed for the upload to begin.
}

그리고 저장하세요. 

.ftpconfig

저장하실때 파일 이름을 .ftpconfig로 하셔야합니다.

커넥트 완료

그러면 자동으로 연결이 되면서 커넥트가 완료됩니다. 

완료

왼쪽 Remote 탭에 ftp 폴더와 목록이 생기는 것을 보실 수 있죠.

이제 여기서 코드를 수정하고 반영하면 끝입니다.

 

어떠셨나요? 오늘은 아톰에서 리모트 FTP를 이용해 코드 수정 후 별도로 파일질라와 같은 업로드를 하지 않아도 바로 반영이 되도록 하는 패키지를 설치해봤어요. 엄청 간단한 내용이지만 활용도가 높은 패키지인 것 같아요. 저도 처음 알게되었을 때 얼마나 좋던지...

혹시 필요하신 분이 있다면 잘 설치하셔서 사용하시기를 바래요. 감사합니다.

반응형

댓글