saltstack / saltstack/salt

Salt-cp locales trouble

Open
#65,917 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug needs-triage
Dominant language
Python
Stars
15.7k
Forks
5.6k
Avg merge
2d 44m
Merged PRs (30d)
80

Description

I need to copy some file from salt master on windows minion to path c:\users\homefolder via salt-cp. Problem is that on windows side in mentioned path are homefolders which include local-sk didactics:

image

which salt master/sat-cp does not translate correctly
Salt command which i try to use:

salt-cp {{ pillar['destination'] }} /root/{{ pillar['user'] }}.ovpn c:/Users/{{ pillar['user'] }}/OpenVPN/config

Is there some possibility of solving issue?

[root@tms2028 ~]# salt tml1160.minion test.versions_report
tml1160.minion:
    Salt Version:
              Salt: 3006.5
     
    Python Version:
            Python: 3.10.13 (heads/main:5600dd9, Nov 15 2023, 04:42:06) [MSC v.1937 64 bit (AMD64)]
     
    Dependency Versions:
              cffi: 1.14.6
          cherrypy: 18.6.1
          dateutil: 2.8.1
         docker-py: Not Installed
             gitdb: 4.0.7
         gitpython: Not Installed
            Jinja2: 3.1.2
           libgit2: Not Installed
      looseversion: 1.0.2
          M2Crypto: Not Installed
              Mako: Not Installed
           msgpack: 1.0.2
      msgpack-pure: Not Installed
      mysql-python: Not Installed
         packaging: 22.0
         pycparser: 2.21
          pycrypto: Not Installed
      pycryptodome: 3.10.1
            pygit2: Not Installed
      python-gnupg: 0.4.8
            PyYAML: 6.0.1
             PyZMQ: 25.0.2
            relenv: 0.14.2
             smmap: 4.0.0
           timelib: 0.2.4
           Tornado: 4.5.3
               ZMQ: 4.3.4
     
    System Versions:
              dist:   
            locale: cp1250
           machine: AMD64
           release: 10
            system: Windows
           version: 10 10.0.22621 SP0 Multiprocessor Free
[root@tms2028 ~]# salt-call test.versions_report
local:
    Salt Version:
              Salt: 3006.5
     
    Python Version:
            Python: 3.10.13 (main, Nov 15 2023, 04:34:27) [GCC 11.2.0]
     
    Dependency Versions:
              cffi: 1.14.6
          cherrypy: 18.6.1
          dateutil: 2.8.1
         docker-py: Not Installed
             gitdb: Not Installed
         gitpython: Not Installed
            Jinja2: 3.1.2
           libgit2: Not Installed
      looseversion: 1.0.2
          M2Crypto: Not Installed
              Mako: Not Installed
           msgpack: 1.0.2
      msgpack-pure: Not Installed
      mysql-python: Not Installed
         packaging: 22.0
         pycparser: 2.21
          pycrypto: Not Installed
      pycryptodome: 3.9.8
            pygit2: Not Installed
      python-gnupg: 0.4.8
            PyYAML: 6.0.1
             PyZMQ: 23.2.0
            relenv: 0.14.2
             smmap: Not Installed
           timelib: 0.2.4
           Tornado: 4.5.3
               ZMQ: 4.3.4
     
    System Versions:
              dist: oracle 7.9 
            locale: utf-8
           machine: x86_64
           release: 3.10.0-1160.105.1.0.1.el7.x86_64
            system: Linux
           version: Oracle Linux Server 7.9 

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the salt-cp command against a Windows minion using a cp1250 locale and a destination containing the shown diacritics. Done means the file is copied to the requested c:/Users/.../OpenVPN/config path without corrupting the localized path or folder name.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.