Sublime FTP/SFTP - ftp

I am trying to connect to my cpanel server using sublime text 3.
Server is added successfully. And remote path is also validated successfully.
But when try to Sync Remote->Local it is just not happening.
{
// The tab key will cycle through the settings when first created
// Visit http://wbond.net/sublime_packages/sftp/settings for help
// sftp, ftp or ftps
"type": "ftp",
"save_before_upload": true,
"upload_on_save": true,
"sync_down_on_open": false,
"sync_skip_deletes": false,
"sync_same_age": true,
"confirm_downloads": false,
"confirm_sync": true,
"confirm_overwrite_newer": false,
"host": "XXXXXX",
"user": "XXXXX",
"password": "XXXXXXX",
"port": "21",
"remote_path": "XXXXXX",
"ignore_regexes": [
"\\.sublime-(project|workspace)", "sftp-config(-alt\\d?)?\\.json",
"sftp-settings\\.json", "/venv/", "\\.svn/", "\\.hg/", "\\.git/",
"\\.bzr", "_darcs", "CVS", "\\.DS_Store", "Thumbs\\.db", "desktop\\.ini"
],
//"file_permissions": "664",
//"dir_permissions": "775",
//"extra_list_connections": 0,
"connect_timeout": 30,
//"keepalive": 120,
//"ftp_passive_mode": true,
//"ftp_obey_passive_host": false,
//"ssh_key_file": "~/.ssh/id_rsa",
//"sftp_flags": ["-F", "/path/to/ssh_config"],
//"preserve_modification_times": false,
//"remote_time_offset_in_hours": 0,
//"remote_encoding": "utf-8",
//"remote_locale": "C",
//"allow_config_upload": false,
}
And in the console I finally got this:
"Select via quick panel? No".
And the process got terminated by itself.

SFTP has some options for that to put on your sftp-config.json file at the root of your folder :
Set those values like this:
"confirm_downloads":false,
"confirm_sync":false,
"confirm_overwrite_newer":true

Related

Ansible-semaphore not running tasks in the order that they were added to queue

I'm using ansible-semaphore API to handle playbook execution, when i call the start task endpoint:
start task endpoint
I need the tasks to run in the order they're added to the queue via API.
But apparently they are running in a random order:
tasks queue
In my settings I have set to only run one task at a time, which stopped it from running multiple tasks also in random order.
UI settings
In Semaphore's config.json I noticed the "concurrency_mode" setting:
{
"bolt": {
"host": "/home/ubuntu/semaphore.bolt",
},
"mysql": {
"host": "localhost",
"user": "root",
"pass": "*****",
"name": "semaphore",
"options": {}
},
"postgres": {
"host": "localhost",
"user": "postgres",
"pass": "*****",
"name": "semaphore",
"options": {}
},
"dialect": "postgres",
"port": "",
"interface": "",
"tmp_path": "/tmp/semaphore",
"cookie_hash": "*****",
"cookie_encryption": "*****",
"access_key_encryption": "*****",
"email_sender": "",
"email_host": "",
"email_port": "",
"web_host": "",
"ldap_binddn": "",
"ldap_bindpassword": "",
"ldap_server": "",
"ldap_searchdn": "",
"ldap_searchfilter": "",
"ldap_mappings": {
"dn": "",
"mail": "",
"uid": "",
"cn": ""
},
"telegram_chat": "",
"telegram_token": "",
"concurrency_mode": "",
"max_parallel_tasks": 0,
"email_alert": false,
"telegram_alert": false,
"slack_alert": false,
"ldap_enable": false,
"ldap_needtls": false
}
But the docs don't mention the options for this field:
Is it possible to run the queue in chronological order? What setting do I have to change?
I tried changing the "concurrency_mode" in the config.json to "false" with no results.
I also tried adding a few seconds delay between the tasks addition to queue, no results either.

Setup consul https with a previous certificate from tomcat

How can we do to set up the consul use a previous certificate created for the tomcat?
We only have server.jks file used in tomcat, and we need to use the same tomcat certification.
How can we do to extract this information below?
"ca_file": "cert/ca.pem",
"cert_file": "cert/server.pem",
"key_file": /cert/serverkey.pem",
The server.conf
{
"bootstrap": true,
"server": true,
"datacenter": "dc1",
"data_dir": "data",
"verify_incoming": true,
"verify_outgoing": true,
"verify_server_hostname": true,
"auto_encrypt": {
"allow_tls": true
},
"log_level": "INFO",
"enable_agent_tls_for_checks": true,
"enable_syslog": false,
"ui_config": {
"enabled": true
},
"ports": {
"http": -1,
"https": 8500
}
}

Retrieving web view link of a Google shared drive folder

I am trying to get the webviewlink of google shared
API: https://www.googleapis.com/drive/v3/files
am unable to get webviewlink of particular shared drive folder.
my input will be the folder id:
{
"id": "1Vat7pdwnpg8i2xMzhic4dOVbadZNv0OJ"
}
how can i achieve this?
Without seeing the exact request you are making its hard to help but i can say this apears to work fine. I can get the the record for a google drive directory shared with me and that directory contains a web view link which has the same file id as the one i sent.
Request
curl \
'https://www.googleapis.com/drive/v3/files/1nhladm_nRRee6rVER9ZA5QqnyKwfG7l?fields=*&key=[YOUR_API_KEY]' \
--header 'Authorization: Bearer [YOUR_ACCESS_TOKEN]' \
--header 'Accept: application/json' \
--compressed
response
{
"kind": "drive#file",
"id": "1nhladm_nRRee6rVER9ZA5QqnyKwfG7l",
"name": "ML GDE Model Deployment Project",
"mimeType": "application/vnd.google-apps.folder",
"starred": false,
"trashed": false,
"explicitlyTrashed": false,
"parents": [
"1OYYiVmqFp9ZvuRSuVgC_ihkdYirLnu"
],
"spaces": [
"drive"
],
"version": "461",
"webViewLink": "https://drive.google.com/drive/folders/1nhladm_nRRee6rVER9ZA5QqnyKwfG7li",
"iconLink": "https://drive-thirdparty.googleusercontent.com/16/type/application/vnd.google-apps.folder+shared",
"hasThumbnail": false,
"thumbnailVersion": "0",
"viewedByMe": false,
"createdTime": "2020-04-02T04:21:47.275Z",
"modifiedTime": "2020-11-02T13:58:51.042Z",
"modifiedByMe": false,
"owners": [
{
.....
}
],
"lastModifyingUser": {
"kind": "drive#user",
},
"shared": true,
"ownedByMe": false,
"capabilities": {
"canAddChildren": false,
"canAddMyDriveParent": false,
"canChangeCopyRequiresWriterPermission": false,
"canChangeViewersCanCopyContent": false,
"canComment": false,
"canCopy": false,
"canDelete": false,
"canDownload": true,
"canEdit": false,
"canListChildren": true,
"canModifyContent": false,
"canMoveChildrenWithinDrive": false,
"canMoveItemIntoTeamDrive": false,
"canMoveItemOutOfDrive": false,
"canMoveItemWithinDrive": false,
"canReadRevisions": false,
"canRemoveChildren": false,
"canRemoveMyDriveParent": true,
"canRename": false,
"canShare": false,
"canTrash": false,
"canUntrash": false
},
"viewersCanCopyContent": true,
"copyRequiresWriterPermission": false,
"writersCanShare": true,
"folderColorRgb": "#8f8f8f",
"quotaBytesUsed": "0",
"isAppAuthorized": false
}
The web view link for this request is https://drive.google.com/drive/folders/1nhladm_nRRee6rVER9ZA5QqnyKwfG7l which is the same as the file id that i sent it.
File Ids change as do the web view links and its possible that they are out of sync.

Sublime text 3 FTP not working with localhost

I am a beginner with sublime text 3. Previous I worked with dream viewer. When I was working with dream viewer, Generally I do keep my project folder in D drive and add new local server in htdoc folder using dream viewer add site option.
Now I need to use sublime text 3 as same I did with dream viewer. I setup a new server using FTP plugin as below
// sftp, ftp or ftps
"type": "ftp",
"sync_down_on_open": true,
"sync_same_age": true,
"host": "127.0.0.1",
"user": "root",
"password": "ashan",
//"port": "22",
"remote_path": "/xampp/htdocs/sanka_d/",
My remote connection as below (sftp-config.jason)
"type": "ftp",
"save_before_upload": true,
"upload_on_save": true,
"sync_down_on_open": false,
"sync_skip_deletes": false,
"sync_same_age": true,
"confirm_downloads": false,
"confirm_sync": true,
"confirm_overwrite_newer": false,
"host": "127.0.0.1",
"user": "root",
"password": "ashan",
//"port": "22",
"remote_path": "/",
When I try to connect with remote server it says below error message.
Connecting to FTP server "127.0.0.1" as "root" ........ failure (Disconnected)
Please help me solve this, Thanks!

Sublime is uploading files into root instead of sub directories

Probably a simple solution, just never encountered the problem before.
I try to upload lets say welcome.blade.php which is located in
resources/views/welcome.blade.php
but sublime is just uploading to the root instead.
I'm using the SFTP package for this and have not encountered this issue before.
The stftp-config file remote path is correct..so I cant figure out what this could be.
Here is the sftp-config file
{
// The tab key will cycle through the settings when first created
// Visit http://wbond.net/sublime_packages/sftp/settings for help
// sftp, ftp or ftps
"type": "ftp",
"save_before_upload": true,
"upload_on_save": false,
"sync_down_on_open": false,
"sync_skip_deletes": false,
"sync_same_age": true,
"confirm_downloads": false,
"confirm_sync": true,
"confirm_overwrite_newer": false,
"host": "their_host",
"user": "their_user",
"password": "",
//"port": "22",
"remote_path": "/domains/theirsitename.com/html/",
"ignore_regexes": [
"\\.sublime-(project|workspace)", "sftp-config(-alt\\d?)?\\.json",
"sftp-settings\\.json", "/venv/", "\\.svn/", "\\.hg/", "\\.git/",
"\\.bzr", "_darcs", "CVS", "\\.DS_Store", "Thumbs\\.db", "desktop\\.ini"
],
//"file_permissions": "664",
//"dir_permissions": "775",
//"extra_list_connections": 0,
"connect_timeout": 30,
//"keepalive": 120,
//"ftp_passive_mode": true,
//"ftp_obey_passive_host": false,
//"ssh_key_file": "~/.ssh/id_rsa",
//"sftp_flags": ["-F", "/path/to/ssh_config"],
//"preserve_modification_times": false,
//"remote_time_offset_in_hours": 0,
//"remote_encoding": "utf-8",
//"remote_locale": "C",
"allow_config_upload": true,
}

Resources