Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Linux presentation
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Wirker Dávid Zoltán
Linux presentation
Commits
39565abe
Verified
Commit
39565abe
authored
3 years ago
by
Tóth Miklós Tibor
Browse files
Options
Downloads
Patches
Plain Diff
eloadas beta 1
parent
6ed35c21
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
eloadas.md
+92
-0
92 additions, 0 deletions
eloadas.md
with
92 additions
and
0 deletions
eloadas.md
+
92
−
0
View file @
39565abe
...
...
@@ -65,3 +65,95 @@ curl https://git.sch.bme.hu/mikewashere.keys >> .ssh/authorized_keys
-
shell automatizálása
-
mintha soronként kiadnánk a parancsokat
```
shell-session
[mike@thinkyboi tmp]$
vi test.sh
[mike@thinkyboi tmp]$
cat
test.sh
echo "ez simán működik" | cowsay
curl "https://home.sch.bme.hu/~mikewashere/linux/eloadas.md" | grep "soronként" | cowsay
[mike@thinkyboi tmp]$
bash test.sh
_____________________
< ez simán működik >
---------------------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 1596 100 1596 0 0 69391 0 --:--:-- --:--:-- --:--:-- 69391
_________________________________
/ - mintha soronként kiadnánk a \
\ parancsokat /
---------------------------------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||
[mike@thinkyboi tmp]$
```
# shebang
-
file futtatásakor a kernel meglesi mi van az elején
-
el tudunk indítani scripteket programként
-
`#!<program>`
```
shell-session
[mike@thinkyboi tmp]$
vi test.sh
[mike@thinkyboi tmp]$
cat
test.sh
#
!
/bin/bash
echo "ez simán működik" | cowsay
curl "https://home.sch.bme.hu/~mikewashere/linux/eloadas.md" | grep "soronként" | cowsay
[mike@thinkyboi tmp]$
chmod
+x test.sh
[mike@thinkyboi tmp]$
./test.sh
_____________________
< ez simán működik >
---------------------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 1596 100 1596 0 0 11319 0 --:--:-- --:--:-- --:--:-- 11319
_________________________________
/ - mintha soronként kiadnánk a \
\ parancsokat /
---------------------------------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||
[mike@thinkyboi tmp]$
```
# tűzfal
-
a kernel belsejében -> gyors, de low-level
-
iptables
-
kényelmesebb egy tűzfal-kezelő
## UFW
-
uncomplicated firewall
-
egyszerű
```
shell-session
[mike@thinkyboi tmp]$
sudo
ufw allow 80
Rules updated
Rules updated (v6)
[mike@thinkyboi tmp]$
sudo
ufw allow https
Rules updated
Rules updated (v6)
[mike@thinkyboi tmp]$
sudo
ufw
enable
```
# SSH kulcsok
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment