-
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d4f4fb8
commit 3a2e4dc
Showing
6 changed files
with
87 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
github: kishikawakatsumi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{ | ||
"extends": ["config:base"], | ||
"packageRules": [ | ||
{ | ||
"matchUpdateTypes": ["minor", "patch", "pin", "digest"], | ||
"automerge": true | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
name: Test | ||
on: | ||
pull_request: | ||
branches: [main] | ||
|
||
jobs: | ||
test: | ||
runs-on: macos-13 | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Test | ||
run: | | ||
set -ex | ||
brew install docker docker-compose | ||
brew install colima | ||
colima start --mount-type 9p | ||
mkdir -p shares/alice | ||
chmod 777 shares/alice | ||
docker compose up --detach | ||
swift test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Security Policy | ||
|
||
For security related problems, please don't use the public issue tracker, but email [@kishikawakatsumi](https://github.com/kishikawakatsumi). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import XCTest | ||
@testable import SMBClient | ||
|
||
final class ClientTests: XCTestCase { | ||
func testLoginSucceeded() async throws { | ||
let client = SMBClient(host: "localhost", port: 4445) | ||
try await client.login(username: "alice", password: "alipass") | ||
try await client.logoff() | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
version: "3" | ||
|
||
services: | ||
samba: | ||
build: . | ||
image: ghcr.io/servercontainers/samba | ||
ports: | ||
- "139:139" | ||
- "4445:445" | ||
environment: | ||
SAMBA_CONF_LOG_LEVEL: 3 | ||
AVAHI_DISABLE: 1 | ||
|
||
GROUP_family: 1500 | ||
|
||
ACCOUNT_alice: alipass | ||
UID_alice: 1000 | ||
GROUPS_alice: family | ||
|
||
ACCOUNT_bob: bobpass | ||
UID_bob: 1001 | ||
GROUPS_bob: family | ||
|
||
SAMBA_VOLUME_CONFIG_shared_home: "[Home]; path=/shares/homes/%U; valid users = alice, bob; guest ok = no; read only = no; browseable = yes" | ||
|
||
SAMBA_VOLUME_CONFIG_aliceonly: "[Alice Share]; path=/shares/alice; valid users = alice; guest ok = no; read only = no; browseable = yes" | ||
SAMBA_VOLUME_CONFIG_alicehidden: "[Alice Hidden Share]; path=/shares/alice-hidden; valid users = alice; guest ok = no; read only = no; browseable = no" | ||
|
||
SAMBA_VOLUME_CONFIG_bobonly: "[Bob Share]; path=/shares/bob; valid users = bob; guest ok = no; read only = no; browseable = yes" | ||
|
||
SAMBA_VOLUME_CONFIG_public: "[Public]; path=/shares/public; valid users = alice, bob, foo; guest ok = no; read only = no; browseable = yes; force group = family" | ||
SAMBA_VOLUME_CONFIG_public_ro: "[Public ReadOnly]; path=/shares/public; guest ok = yes; read only = yes; browseable = yes; force group = family" | ||
|
||
SAMBA_VOLUME_CONFIG_guestmultilineexample: | | ||
[Guest Share] | ||
path = /shares/guest | ||
guest ok = yes | ||
browseable = yes | ||
volumes: | ||
- ./shares/alice:/shares/alice |