Docker braindump

These are currently random notes and are not much help to anybody yet. They will get tidied as I add to the page.

Docker Swarm

Docker swarm secrets

From inside a docker swarm manager node, there are two ways of creating a secret.

Using a string value:

printf <your_secret_value> | docker secret create your_secret_key -

Using a file path:

docker secret create your_secret_key ./your_secret_value.json

Docker swarm secrets are saved, encrypted, and are accessible to containers via a filepath:

/run/secrets/your_secret_key.

Posts to digest

https://www.bretfisher.com/docker-swarm-firewall-ports/

https://www.bretfisher.com/docker/

https://www.digitalocean.com/community/tutorials/how-to-set-up-laravel-nginx-and-mysql-with-docker-compose

Setting up samba share on my home network

Secure shell into file server.

Install samba if not already present:

sudo apt-get install samba

Create samba password with :

sudo smbpasswd -a YOUR_USERNAME

Configuring the share:

sudo nano /etc/samba/smb.conf
# /etc/samba/smb.conf

[media] 
path = /home/YOUR_USERNAME/Share 
available = yes 
valid users = YOUR_USERNAME 
read only = no 
browsable = yes 
public = yes 
writable = yes

Restart samba:

sudo restart smbd